From 5df856f5af17bd0922b99fc21c1236f01f3d2f27 Mon Sep 17 00:00:00 2001 From: Cyril Hrubis Date: Tue, 12 Jun 2012 15:06:28 +0200 Subject: [PATCH] core: Remove GP_ContextDump(). --- include/core/GP_Context.h | 5 ----- libs/core/GP_Context.c | 19 ------------------- 2 files changed, 24 deletions(-) diff --git a/include/core/GP_Context.h b/include/core/GP_Context.h index 141fa76e..50574817 100644 --- a/include/core/GP_Context.h +++ b/include/core/GP_Context.h @@ -154,11 +154,6 @@ GP_Context *GP_ContextConvert(const GP_Context *src, void GP_ContextFree(GP_Context *context); /* - * Dump context into file - */ -GP_RetCode GP_ContextDump(GP_Context *context, const char *path); - -/* * Rotates context flags clock wise. */ void GP_ContextFlagsRotateCW(GP_Context *context); diff --git a/libs/core/GP_Context.c b/libs/core/GP_Context.c index 967edcb5..3226c1c6 100644 --- a/libs/core/GP_Context.c +++ b/libs/core/GP_Context.c @@ -222,25 +222,6 @@ GP_Context *GP_ContextSubContext(GP_Context *context, GP_Context *subcontext, return ret; } -GP_RetCode GP_ContextDump(GP_Context *context, const char *path) -{ - FILE *f = fopen(path, "w"); - uint32_t x, y; - - if (f == NULL) - return GP_EBADFILE; - - for (y = 0; y < context->h; y++) { - for (x = 0; x < context->bytes_per_row; x++) - fprintf(f, "0x%02x ", ((uint8_t *)context->pixels) - [y * context->bytes_per_row + x]); - fprintf(f, "\n"); - } - - fclose(f); - return GP_ESUCCESS; -} - /* * The context rotations consists of two cyclic permutation groups that are * mirrored. -- 2.11.4.GIT