X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;f=images%2Fimage.c;h=d0d16d8feab2b109ee70e02a854b5825557d3b2b;hb=0204a4ff10292047628c754b0d088a742b511bb3;hp=26445aa34835934fa73545f980fb4b6d28b92f0e;hpb=f784f9b6365d92dac7b10ab2e589d02c7445e987;p=libucw.git diff --git a/images/image.c b/images/image.c index 26445aa3..d0d16d8f 100644 --- a/images/image.c +++ b/images/image.c @@ -9,11 +9,11 @@ #undef LOCAL_DEBUG -#include "lib/lib.h" -#include "lib/mempool.h" -#include "images/images.h" -#include "images/error.h" -#include "images/color.h" +#include +#include +#include +#include +#include #include @@ -41,7 +41,7 @@ image_new(struct image_context *ctx, uns cols, uns rows, uns flags, struct mempo pixel_size = channels = flags_to_pixel_size(flags); if (!channels || channels > 4) { - IMAGE_ERROR(ctx, IMAGE_ERROR_INVALID_PIXEL_FORMAT, "Invalid number of color channels"); + IMAGE_ERROR(ctx, IMAGE_ERROR_INVALID_PIXEL_FORMAT, "Invalid number of color channels (%u)", channels); return NULL; } switch (channels) @@ -117,7 +117,7 @@ image_clone(struct image_context *ctx, struct image *src, uns flags, struct memp # define IMAGE_WALK_SEC_IMAGE src # define IMAGE_WALK_DOUBLE # define IMAGE_WALK_DO_STEP do{ walk_pos[0] = walk_sec_pos[0]; walk_pos[1] = walk_sec_pos[1]; walk_pos[2] = walk_sec_pos[2]; }while(0) -# include "images/image-walk.h" +# include } else if (src->row_size != img->row_size || ((img->flags | src->flags) & IMAGE_GAPS_PROTECTED)) {