diff options
Diffstat (limited to 'converter/other/rast.c')
-rw-r--r-- | converter/other/rast.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/converter/other/rast.c b/converter/other/rast.c index 1c787089..1a64f7e5 100644 --- a/converter/other/rast.c +++ b/converter/other/rast.c @@ -61,6 +61,8 @@ mem_create( w, h, depth ) return p; } + + void mem_free( p ) struct pixrect* p; @@ -70,6 +72,8 @@ mem_free( p ) free( p ); } + + int pr_dump( p, out, colormap, type, copy_flag ) struct pixrect* p; @@ -371,11 +375,11 @@ pr_load_colormap( in, hP, colormap ) free( colormap->map[1] ); return PIX_ERR; } - if ( fread( colormap->map[0], 1, colormap->length, in ) != + if ( fread( colormap->map[0], 1, colormap->length, in ) != colormap->length || - fread( colormap->map[1], 1, colormap->length, in ) != + fread( colormap->map[1], 1, colormap->length, in ) != colormap->length || - fread( colormap->map[2], 1, colormap->length, in ) != + fread( colormap->map[2], 1, colormap->length, in ) != colormap->length ) { free( colormap->map[0] ); @@ -409,6 +413,8 @@ pr_load_colormap( in, hP, colormap ) return 0; } + + struct pixrect* pr_load_image( in, hP, colormap ) FILE* in; @@ -502,3 +508,6 @@ pr_load_image( in, hP, colormap ) return p; } + + + |