diff --git a/src/modules/Image/image.c b/src/modules/Image/image.c index 805ebc6b1526cce387bf6c283dedbf096bb399fc..4e745bec42acc53aa672ce03920d6ebaf5c56c00 100644 --- a/src/modules/Image/image.c +++ b/src/modules/Image/image.c @@ -1,9 +1,9 @@ -/* $Id: image.c,v 1.137 1999/05/24 12:22:49 mirar Exp $ */ +/* $Id: image.c,v 1.138 1999/05/24 15:09:17 mirar Exp $ */ /* **! module Image **! note -**! $Id: image.c,v 1.137 1999/05/24 12:22:49 mirar Exp $ +**! $Id: image.c,v 1.138 1999/05/24 15:09:17 mirar Exp $ **! class Image **! **! The main object of the <ref>Image</ref> module, this object @@ -97,7 +97,7 @@ #include "stralloc.h" #include "global.h" -RCSID("$Id: image.c,v 1.137 1999/05/24 12:22:49 mirar Exp $"); +RCSID("$Id: image.c,v 1.138 1999/05/24 15:09:17 mirar Exp $"); #include "pike_macros.h" #include "object.h" #include "constants.h" @@ -3512,48 +3512,6 @@ void image_cast(INT32 args) /***************** global init etc *****************************/ -extern void init_font_programs(void); -extern void exit_font(void); -extern void init_colortable_programs(void); -extern void exit_colortable(void); -extern void init_image_colors(void); -extern void exit_image_colors(void); -extern void init_image_layers(void); -extern void exit_image_layers(void); - -/* encoders */ - -extern void init_image_gif(void); -extern void exit_image_gif(void); -extern void init_image_pnm(void); -extern void exit_image_pnm(void); -extern void init_image_bmp(void); -extern void exit_image_bmp(void); -extern void init_image_xwd(void); -extern void exit_image_xwd(void); -extern void init_image_x(void); -extern void exit_image_x(void); -extern void init_image_any(void); -extern void exit_image_any(void); -extern void init_image_tga(void); -extern void exit_image_tga(void); -extern void init_image_pcx(void); -extern void exit_image_pcx(void); -extern void init_image__xpm(void); -extern void exit_image__xpm(void); -extern void exit_image_xbm(void); -extern void init_image_xbm(void); -extern void exit_image_ilbm(void); -extern void init_image_ilbm(void); -extern void init_image_xcf(void); -extern void exit_image_xcf(void); -extern void init_image_psd(void); -extern void exit_image_psd(void); -extern void init_image_hrz(void); -extern void exit_image_hrz(void); -extern void init_image_avs(void); -extern void exit_image_avs(void); - #define tRGB tOr3(tColor,tVoid,tInt) tOr(tInt,tVoid) tOr(tInt,tVoid) void init_image_image(void) @@ -3568,6 +3526,8 @@ void init_image_image(void) tFunc(tInt tInt tRGB,tObj),0); ADD_FUNCTION("clear",image_clear, tFunc(tRGB,tObj),0); + +#if 0 ADD_FUNCTION("toppm",image_toppm,tFunc(,tStr),0); ADD_FUNCTION("frompnm",image_frompnm,tFunc(tStr,tOr(tObj,tStr)),0); ADD_FUNCTION("fromppm",image_frompnm,tFunc(tStr,tOr(tObj,tStr)),0); @@ -3595,6 +3555,7 @@ void init_image_image(void) tFunc(,tStr),0); ADD_FUNCTION("gif_netscape_loop",image_gif_netscape_loop, tFunc(,tStr),0); +#endif ADD_FUNCTION("cast",image_cast, tFunc(tStr,tStr),0); diff --git a/src/modules/Image/pnm_compat.c b/src/modules/Image/pnm_compat.c index ccc3cc297f12d93c2beb602d088e439965f8e41d..1bb3b19f5e29ba86a12aa625296db54c80cc39cf 100644 --- a/src/modules/Image/pnm_compat.c +++ b/src/modules/Image/pnm_compat.c @@ -1,10 +1,10 @@ -/* $Id: pnm_compat.c,v 1.2 1999/04/13 12:32:31 mirar Exp $ */ +/* $Id: pnm_compat.c,v 1.3 1999/05/24 15:09:20 mirar Exp $ */ /* -**! module Image -**! note -**! $Id: pnm_compat.c,v 1.2 1999/04/13 12:32:31 mirar Exp $ -**! class Image +**< module Image +**< note +**< $Id: pnm_compat.c,v 1.3 1999/05/24 15:09:20 mirar Exp $ +**< class Image */ #include "global.h" @@ -33,22 +33,22 @@ extern struct program *image_program; /* -**! method string toppm() -**! <b>compability method</b> - do not use in new programs. -**! -**! See <ref>Image.PNM.encode</ref>(). -**! -**! returns PPM data -**! -**! method object|string frompnm(string pnm) -**! method object|string fromppm(string pnm) -**! <b>compability method</b> - do not use in new programs. -**! -**! See <ref>Image.PNM.decode</ref>(). -**! -**! returns the called object or a hint of what wronged. -**! arg string pnm -**! pnm data, as a string +**< method string toppm() +**< <b>compability method</b> - do not use in new programs. +**< +**< See <ref>Image.PNM.encode</ref>(). +**< +**< returns PPM data +**< +**< method object|string frompnm(string pnm) +**< method object|string fromppm(string pnm) +**< <b>compability method</b> - do not use in new programs. +**< +**< See <ref>Image.PNM.decode</ref>(). +**< +**< returns the called object or a hint of what wronged. +**< arg string pnm +**< pnm data, as a string */ void img_pnm_encode_binary(INT32 args); diff --git a/src/modules/Image/togif.c b/src/modules/Image/togif.c index 0c79feeefbf04523e4039729414de995cc9b8470..b9ebd8d1bcd1ba8f105fb8bf8e7060b1ca23aea9 100644 --- a/src/modules/Image/togif.c +++ b/src/modules/Image/togif.c @@ -2,7 +2,7 @@ togif -$Id: togif.c,v 1.34 1999/05/20 17:34:38 mirar Exp $ +$Id: togif.c,v 1.35 1999/05/24 15:09:21 mirar Exp $ old GIF API compat stuff @@ -11,7 +11,7 @@ old GIF API compat stuff /* **! module Image **! note -**! $Id: togif.c,v 1.34 1999/05/20 17:34:38 mirar Exp $ +**! $Id: togif.c,v 1.35 1999/05/24 15:09:21 mirar Exp $ **! class Image */ @@ -46,49 +46,49 @@ old GIF API compat stuff extern struct program *image_colortable_program; /* -**! method string gif_begin() -**! method string gif_begin(int num_colors) -**! method string gif_begin(array(array(int)) colors) -**! method string gif_end() -**! method string gif_netscape_loop(int loops) -**! method string togif() -**! method string togif(int trans_r,int trans_g,int trans_b) -**! method string togif(int num_colors,int trans_r,int trans_g,int trans_b) -**! method string togif(array(array(int)) colors,int trans_r,int trans_g,int trans_b) -**! method string togif_fs() -**! method string togif_fs(int trans_r,int trans_g,int trans_b) -**! method string togif_fs(int num_colors,int trans_r,int trans_g,int trans_b) -**! method string togif_fs(array(array(int)) colors,int trans_r,int trans_g,int trans_b) -**! method string gif_add() -**! method string gif_add_fs() -**! method string gif_add_nomap() -**! method string gif_add_fs_nomap() -**! method string gif_add*(int x,int y) -**! method string gif_add*(int x,int y,int delay_cs) -**! method string gif_add*(int x,int y,int num_colors,int delay_cs) -**! method string gif_add*(int x,int y,array(array(int)) colors,int delay_cs) -**! old GIF API compatibility function. Don't use -**! in any new code. -**! -**! <table> -**! <tr><td></td><td>is replaced by</td></tr> -**! <tr><td>gif_begin</td><td><ref>Image.GIF.header_block</ref></td></tr> -**! <tr><td>gif_end</td><td><ref>Image.GIF.end_block</ref></td></tr> -**! <tr><td>gif_netscape_loop</td><td><ref>Image.GIF.netscape_loop_block</ref></td></tr> -**! <tr><td>togif</td><td><ref>Image.GIF.encode</ref></td></tr> -**! <tr><td>togif_fs</td><td><ref>Image.GIF.encode</ref>�</td></tr> -**! <tr><td>gif_add</td><td><ref>Image.GIF.render_block</ref>��</td></tr> -**! <tr><td>gif_add_fs</td><td><ref>Image.GIF.render_block</ref>�</td></tr> -**! <tr><td>gif_add_nomap</td><td><ref>Image.GIF.render_block</ref>�</td></tr> -**! <tr><td>gif_add_fs_nomap</td><td><ref>Image.GIF.render_block</ref>��</td></tr> -**! </table> -**! -**! � Use <ref>Image.Colortable</ref> to get whatever dithering -**! you want. -**! -**! � local map toggle is sent as an argument -**! -**! returns GIF data. +**< method string gif_begin() +**< method string gif_begin(int num_colors) +**< method string gif_begin(array(array(int)) colors) +**< method string gif_end() +**< method string gif_netscape_loop(int loops) +**< method string togif() +**< method string togif(int trans_r,int trans_g,int trans_b) +**< method string togif(int num_colors,int trans_r,int trans_g,int trans_b) +**< method string togif(array(array(int)) colors,int trans_r,int trans_g,int trans_b) +**< method string togif_fs() +**< method string togif_fs(int trans_r,int trans_g,int trans_b) +**< method string togif_fs(int num_colors,int trans_r,int trans_g,int trans_b) +**< method string togif_fs(array(array(int)) colors,int trans_r,int trans_g,int trans_b) +**< method string gif_add() +**< method string gif_add_fs() +**< method string gif_add_nomap() +**< method string gif_add_fs_nomap() +**< method string gif_add*(int x,int y) +**< method string gif_add*(int x,int y,int delay_cs) +**< method string gif_add*(int x,int y,int num_colors,int delay_cs) +**< method string gif_add*(int x,int y,array(array(int)) colors,int delay_cs) +**< old GIF API compatibility function. Don't use +**< in any new code. +**< +**< <table> +**< <tr><td></td><td>is replaced by</td></tr> +**< <tr><td>gif_begin</td><td><ref>Image.GIF.header_block</ref></td></tr> +**< <tr><td>gif_end</td><td><ref>Image.GIF.end_block</ref></td></tr> +**< <tr><td>gif_netscape_loop</td><td><ref>Image.GIF.netscape_loop_block</ref></td></tr> +**< <tr><td>togif</td><td><ref>Image.GIF.encode</ref></td></tr> +**< <tr><td>togif_fs</td><td><ref>Image.GIF.encode</ref>�</td></tr> +**< <tr><td>gif_add</td><td><ref>Image.GIF.render_block</ref>��</td></tr> +**< <tr><td>gif_add_fs</td><td><ref>Image.GIF.render_block</ref>�</td></tr> +**< <tr><td>gif_add_nomap</td><td><ref>Image.GIF.render_block</ref>�</td></tr> +**< <tr><td>gif_add_fs_nomap</td><td><ref>Image.GIF.render_block</ref>��</td></tr> +**< </table> +**< +**< � Use <ref>Image.Colortable</ref> to get whatever dithering +**< you want. +**< +**< � local map toggle is sent as an argument +**< +**< returns GIF data. */ extern void image_gif_header_block(INT32 args); @@ -241,27 +241,27 @@ void image_gif_add_fs_nomap(INT32 args) } /* -**! method string togif() -**! method string togif(int trans_r,int trans_g,int trans_b) -**! method string togif(int num_colors,int trans_r,int trans_g,int trans_b) -**! method string togif(array(array(int)) colors,int trans_r,int trans_g,int trans_b) -**! method string togif_fs() -**! method string togif_fs(int trans_r,int trans_g,int trans_b) -**! method string togif_fs(int num_colors,int trans_r,int trans_g,int trans_b) -**! method string togif_fs(array(array(int)) colors,int trans_r,int trans_g,int trans_b) -**! Makes GIF data. The togif_fs variant uses floyd-steinberg -**! dithereing. -**! returns the GIF data -**! -**! arg int num_colors -**! number of colors to quantize to (default is 256) -**! array array(array(int)) colors -**! colors to map to (default is to quantize to 256), format is ({({r,g,b}),({r,g,b}),...}). -**! arg int trans_r -**! arg int trans_g -**! arg int trans_b -**! one color, that is to be transparent. -**! see also: gif_begin, gif_add, gif_end, toppm, fromgif +**< method string togif() +**< method string togif(int trans_r,int trans_g,int trans_b) +**< method string togif(int num_colors,int trans_r,int trans_g,int trans_b) +**< method string togif(array(array(int)) colors,int trans_r,int trans_g,int trans_b) +**< method string togif_fs() +**< method string togif_fs(int trans_r,int trans_g,int trans_b) +**< method string togif_fs(int num_colors,int trans_r,int trans_g,int trans_b) +**< method string togif_fs(array(array(int)) colors,int trans_r,int trans_g,int trans_b) +**< Makes GIF data. The togif_fs variant uses floyd-steinberg +**< dithereing. +**< returns the GIF data +**< +**< arg int num_colors +**< number of colors to quantize to (default is 256) +**< array array(array(int)) colors +**< colors to map to (default is to quantize to 256), format is ({({r,g,b}),({r,g,b}),...}). +**< arg int trans_r +**< arg int trans_g +**< arg int trans_b +**< one color, that is to be transparent. +**< see also: gif_begin, gif_add, gif_end, toppm, fromgif */ extern void _image_gif_encode(INT32 args,int fs);