diff --git a/src/modules/Image/colors.c b/src/modules/Image/colors.c index c7d32bb568ea2111c8bf2a5dd53fc0722375fb83..d0a8106a9722ded857f34a7e1fdddfa3f7b2a6c9 100644 --- a/src/modules/Image/colors.c +++ b/src/modules/Image/colors.c @@ -1,7 +1,7 @@ /* **! module Image **! note -**! $Id: colors.c,v 1.52 2001/07/17 03:44:13 nilsson Exp $ +**! $Id: colors.c,v 1.53 2001/07/18 18:49:58 nilsson Exp $ **! submodule Color **! **! This module keeps names and easy handling @@ -179,7 +179,7 @@ #include "global.h" -RCSID("$Id: colors.c,v 1.52 2001/07/17 03:44:13 nilsson Exp $"); +RCSID("$Id: colors.c,v 1.53 2001/07/18 18:49:58 nilsson Exp $"); #include "image_machine.h" @@ -1010,32 +1010,32 @@ static void image_color___hash(INT32 args) **! <tr><th>method</th><th width=50%>effect</th> **! <th>h</th><th>s</th><th>v</th><th>as</th></tr> **! <tr><td>light </td><td>raise light level</td><td>�0</td><td> �0</td><td>+50</td> -**! <td><illustration>return Image(20,20,@(array)Color["#693e3e"])</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->light())</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->light()->light())</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->light()->light()->light())</illustration></td></tr> +**! <td><illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"])</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->light())</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->light()->light())</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->light()->light()->light())</illustration></td></tr> **! **! <tr><td>dark </td><td>lower light level</td><td>�0</td><td> �0</td><td>-50</td> -**! <td><illustration>return Image(20,20,@(array)Color["#693e3e"])</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->dark())</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->dark()->dark())</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->dark()->dark()->dark())</illustration></td></tr> +**! <td><illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"])</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->dark())</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->dark()->dark())</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->dark()->dark()->dark())</illustration></td></tr> **! **! <tr><td>bright</td><td>brighter color </td><td>�0</td><td>+50</td><td>+50</td> -**! <td><illustration>return Image(20,20,@(array)Color["#693e3e"])</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->bright())</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->bright()->bright())</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->bright()->bright()->bright())</illustration></td></tr> +**! <td><illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"])</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->bright())</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->bright()->bright())</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->bright()->bright()->bright())</illustration></td></tr> **! **! <tr><td>dull </td><td>greyer color </td><td>�0</td><td>-50</td><td>-50</td> -**! <td><illustration>return Image(20,20,@(array)Color.red)</illustration> -**! <illustration>return Image(20,20,@(array)Color.red->dull())</illustration> -**! <illustration>return Image(20,20,@(array)Color.red->dull()->dull())</illustration> -**! <illustration>return Image(20,20,@(array)Color.red->dull()->dull()->dull())</illustration></td></tr> +**! <td><illustration>return Image.Image(20,20,@(array)Image.Color.red)</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color.red->dull())</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color.red->dull()->dull())</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color.red->dull()->dull()->dull())</illustration></td></tr> **! **! <tr><td>neon </td><td>set to extreme </td><td>�0</td><td>max</td><td>max</td> -**! <td><illustration>return Image(20,20,@(array)Color["#693e3e"])</illustration> -**! <illustration>return Image(20,20,@(array)Color["#693e3e"]->neon())</illustration></td></tr> +**! <td><illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"])</illustration> +**! <illustration>return Image.Image(20,20,@(array)Image.Color["#693e3e"]->neon())</illustration></td></tr> **! **! </table> **! diff --git a/src/modules/Image/colortable.c b/src/modules/Image/colortable.c index 5ba578353ddc93f41982a642d589618ed6f40e02..3a962d682040689021bb7ad323df66b7dbeb7a46 100644 --- a/src/modules/Image/colortable.c +++ b/src/modules/Image/colortable.c @@ -1,11 +1,11 @@ #include "global.h" -/* $Id: colortable.c,v 1.103 2001/07/12 13:48:11 grubba Exp $ */ +/* $Id: colortable.c,v 1.104 2001/07/18 18:49:58 nilsson Exp $ */ /* **! module Image **! note -**! $Id: colortable.c,v 1.103 2001/07/12 13:48:11 grubba Exp $ +**! $Id: colortable.c,v 1.104 2001/07/18 18:49:58 nilsson Exp $ **! class Colortable **! **! This object keeps colortable information, @@ -21,7 +21,7 @@ /* #define COLORTABLE_REDUCE_DEBUG */ /* #define CUBICLE_DEBUG */ -RCSID("$Id: colortable.c,v 1.103 2001/07/12 13:48:11 grubba Exp $"); +RCSID("$Id: colortable.c,v 1.104 2001/07/18 18:49:58 nilsson Exp $"); #include <math.h> /* fabs() */ @@ -2855,8 +2855,8 @@ void image_colortable_rigid(INT32 args) **! **! <table><tr valign=center> **! <td><illustration> return lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),16); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),16)->cubicles(4,5,4,200); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),16); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),16)->cubicles(4,5,4,200); return c*lena(); </illustration></td> **! </tr><tr valign=center> **! <td>original</td> **! <td>default cubicles,<br>16 colors</td> @@ -3334,35 +3334,35 @@ void build_rigid(struct neo_colortable *nct) **! **! <table><tr valign=center> **! <td></td> -**! <td><illustration> object c=Colortable(lena(),2); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),4); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),8); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),16); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),32); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),2); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),4); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),8); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),16); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),32); return c*lena(); </illustration></td> **! <td>no dither</td> **! </tr><tr valign=center> **! <td></td> -**! <td><illustration> object c=Colortable(lena(),2)->floyd_steinberg(); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),4)->floyd_steinberg(); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),8)->floyd_steinberg(); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),16)->floyd_steinberg(); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),32)->floyd_steinberg(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),2)->floyd_steinberg(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),4)->floyd_steinberg(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),8)->floyd_steinberg(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),16)->floyd_steinberg(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),32)->floyd_steinberg(); return c*lena(); </illustration></td> **! <td><ref>floyd_steinberg</ref> dither</td> **! </tr><tr valign=center> **! <td></td> -**! <td><illustration> object c=Colortable(lena(),2)->ordered(60,60,60); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),4)->ordered(45,45,45); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),8)->ordered(40,40,40); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),16)->ordered(40,40,40); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),32)->ordered(15,15,15); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),2)->ordered(60,60,60); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),4)->ordered(45,45,45); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),8)->ordered(40,40,40); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),16)->ordered(40,40,40); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),32)->ordered(15,15,15); return c*lena(); </illustration></td> **! <td><ref>ordered</ref> dither</td> **! </tr><tr valign=center> **! <td><illustration> return lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),2)->randomcube(60,60,60); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),4)->randomcube(45,45,45); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),8)->randomcube(40,40,40); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),16)->randomcube(40,40,40); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),32)->randomcube(15,15,15); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),2)->randomcube(60,60,60); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),4)->randomcube(45,45,45); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),8)->randomcube(40,40,40); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),16)->randomcube(40,40,40); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),32)->randomcube(15,15,15); return c*lena(); </illustration></td> **! <td><ref>randomcube</ref> dither</td> **! </tr><tr valign=center> **! <td>original</td> @@ -3782,8 +3782,8 @@ void image_colortable_spacefactors(INT32 args) **! **! <table><tr valign=center> **! <td><illustration> return lena(); </illustration></td> -**! <td><illustration> object c=Colortable(4,4,4)->floyd_steinberg(); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(lena(),16)->floyd_steinberg(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(4,4,4)->floyd_steinberg(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(lena(),16)->floyd_steinberg(); return c*lena(); </illustration></td> **! </tr><tr valign=center> **! <td>original</td> **! <td>floyd_steinberg to a 4�4�4 colorcube</td> @@ -3917,8 +3917,8 @@ void image_colortable_nodither(INT32 args) **! **! <table><tr valign=center> **! <td><illustration> return lena(); </illustration></td> -**! <td><illustration> object c=Colortable(4,4,4)->randomcube(); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(4,4,4)->randomgrey(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(4,4,4)->randomcube(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(4,4,4)->randomgrey(); return c*lena(); </illustration></td> **! </tr><tr valign=top> **! <td>original</td> **! <td colspan=2>mapped to <br><tt>Image.Colortable(4,4,4)-></tt></td> @@ -3928,23 +3928,23 @@ void image_colortable_nodither(INT32 args) **! <td>randomgrey()</td> **! </tr><tr valign=top> **! <td><illustration> -**! object i=Image(lena()->xsize(),lena()->ysize()); +**! object i=Image.Image(lena()->xsize(),lena()->ysize()); **! i->tuned_box(0,0,i->xsize()-1,i->ysize()-1, **! ({({0,0,0}),({0,0,0}),({255,255,255}),({255,255,255})})); **! return i; **! </illustration></td> **! <td><illustration> -**! object i=Image(lena()->xsize(),lena()->ysize()); +**! object i=Image.Image(lena()->xsize(),lena()->ysize()); **! i->tuned_box(0,0,i->xsize()-1,i->ysize()-1, **! ({({0,0,0}),({0,0,0}),({255,255,255}),({255,255,255})})); -**! object c=Colortable(4,4,4)->randomcube(); +**! object c=Image.Colortable(4,4,4)->randomcube(); **! return c*i; **! </illustration></td> **! <td><illustration> -**! object i=Image(lena()->xsize(),lena()->ysize()); +**! object i=Image.Image(lena()->xsize(),lena()->ysize()); **! i->tuned_box(0,0,i->xsize()-1,i->ysize()-1, **! ({({0,0,0}),({0,0,0}),({255,255,255}),({255,255,255})})); -**! object c=Colortable(4,4,4)->randomgrey(); +**! object c=Image.Colortable(4,4,4)->randomgrey(); **! return c*i; **! </illustration></td> **! </tr></table> @@ -4157,9 +4157,9 @@ static int *ordered_make_diff(int *errors,int sz,int err) **! **! <table><tr valign=center> **! <td><illustration> return lena(); </illustration></td> -**! <td><illustration> object c=Colortable(6,6,6)->ordered(42,42,42,2,2); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(6,6,6)->ordered(); return c*lena(); </illustration></td> -**! <td><illustration> object c=Colortable(6,6,6)->ordered(42,42,42,8,8,0,0,0,1,1,0); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(6,6,6)->ordered(42,42,42,2,2); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(6,6,6)->ordered(); return c*lena(); </illustration></td> +**! <td><illustration> object c=Image.Colortable(6,6,6)->ordered(42,42,42,8,8,0,0,0,1,1,0); return c*lena(); </illustration></td> **! </tr><tr valign=top> **! <td>original</td> **! <td colspan=2>mapped to <br><tt>Image.Colortable(6,6,6)-></tt></td> @@ -4170,30 +4170,30 @@ static int *ordered_make_diff(int *errors,int sz,int err) **! <td><tt>ordered<br> (42,42,42, 8,8,<br> 0,0, 0,1, 1,0)</tt></td> **! </tr><tr valign=top> **! <td><illustration> -**! object i=Image(lena()->xsize(),lena()->ysize()); +**! object i=Image.Image(lena()->xsize(),lena()->ysize()); **! i->tuned_box(0,0,i->xsize()-1,i->ysize()-1, **! ({({0,0,0}),({0,0,0}),({255,255,255}),({255,255,255})})); **! return i; **! </illustration></td> **! <td><illustration> -**! object i=Image(lena()->xsize(),lena()->ysize()); +**! object i=Image.Image(lena()->xsize(),lena()->ysize()); **! i->tuned_box(0,0,i->xsize()-1,i->ysize()-1, **! ({({0,0,0}),({0,0,0}),({255,255,255}),({255,255,255})})); -**! object c=Colortable(6,6,6)->ordered(42,42,42,2,2); +**! object c=Image.Colortable(6,6,6)->ordered(42,42,42,2,2); **! return c*i; **! </illustration></td> **! <td><illustration> -**! object i=Image(lena()->xsize(),lena()->ysize()); +**! object i=Image.Image(lena()->xsize(),lena()->ysize()); **! i->tuned_box(0,0,i->xsize()-1,i->ysize()-1, **! ({({0,0,0}),({0,0,0}),({255,255,255}),({255,255,255})})); -**! object c=Colortable(6,6,6)->ordered(); +**! object c=Image.Colortable(6,6,6)->ordered(); **! return c*i; **! </illustration></td> **! <td><illustration> -**! object i=Image(lena()->xsize(),lena()->ysize()); +**! object i=Image.Image(lena()->xsize(),lena()->ysize()); **! i->tuned_box(0,0,i->xsize()-1,i->ysize()-1, **! ({({0,0,0}),({0,0,0}),({255,255,255}),({255,255,255})})); -**! object c=Colortable(6,6,6)->ordered(42,42,42,8,8,0,0,0,1,1,0); +**! object c=Image.Colortable(6,6,6)->ordered(42,42,42,8,8,0,0,0,1,1,0); **! return c*i; **! </illustration></td> **! </tr></table> diff --git a/src/modules/Image/image.c b/src/modules/Image/image.c index ba0c762f6f2b37decc986c1b036f3e150c8c5380..baf9b738d4725105f867357a90544eefeefd7f1f 100644 --- a/src/modules/Image/image.c +++ b/src/modules/Image/image.c @@ -1,9 +1,9 @@ -/* $Id: image.c,v 1.189 2001/06/13 13:41:13 grubba Exp $ */ +/* $Id: image.c,v 1.190 2001/07/18 18:49:58 nilsson Exp $ */ /* **! module Image **! note -**! $Id: image.c,v 1.189 2001/06/13 13:41:13 grubba Exp $ +**! $Id: image.c,v 1.190 2001/07/18 18:49:58 nilsson Exp $ **! class Image **! **! The main object of the <ref>Image</ref> module, this object @@ -98,7 +98,7 @@ #include "stralloc.h" #include "global.h" -RCSID("$Id: image.c,v 1.189 2001/06/13 13:41:13 grubba Exp $"); +RCSID("$Id: image.c,v 1.190 2001/07/18 18:49:58 nilsson Exp $"); #include "pike_macros.h" #include "object.h" #include "constants.h" @@ -2468,18 +2468,18 @@ void image_threshold(INT32 args) **! <td>->rgb_to_hsv();</td> **! </tr><tr valign=center> **! <td><illustration> -**! return image(67,67)->tuned_box(0,0, 67,67, +**! return Image.image(67,67)->tuned_box(0,0, 67,67, **! ({ ({ 255,255,128 }), ({ 0,255,128 }), **! ({ 255,255,255 }), ({ 0,255,255 })})); **! </illustration></td> **! <td><illustration> -**! return image(67,67)->tuned_box(0,0, 67,67, +**! return Image.image(67,67)->tuned_box(0,0, 67,67, **! ({ ({ 255,255,128 }), ({ 0,255,128 }), **! ({ 255,255,255 }), ({ 0,255,255 })})) **! ->hsv_to_rgb(); **! </illustration></td> **! <td><illustration> -**! return image(67,67)->tuned_box(0,0, 67,67, +**! return Image.image(67,67)->tuned_box(0,0, 67,67, **! ({ ({ 255,255,128 }), ({ 0,255,128 }), **! ({ 255,255,255 }), ({ 0,255,255 })})) **! ->rgb_to_hsv(); diff --git a/src/modules/Image/pattern.c b/src/modules/Image/pattern.c index fbc0449308283bfa4fa6d15dedbe5ed88d0bfec9..65f33ac42b6fcb66467f8a4d09f2202d7e9c56a5 100644 --- a/src/modules/Image/pattern.c +++ b/src/modules/Image/pattern.c @@ -1,9 +1,9 @@ -/* $Id: pattern.c,v 1.23 2000/12/01 08:10:02 hubbe Exp $ */ +/* $Id: pattern.c,v 1.24 2001/07/18 18:49:59 nilsson Exp $ */ /* **! module Image **! note -**! $Id: pattern.c,v 1.23 2000/12/01 08:10:02 hubbe Exp $ +**! $Id: pattern.c,v 1.24 2001/07/18 18:49:59 nilsson Exp $ **! class Image */ @@ -345,7 +345,7 @@ static void init_colorrange(rgb_group *cr,struct svalue *s,char *where) **! **! Example: **! <tt>->noise( ({0,({255,0,0}), 0.3,({0,255,0}), 0.6,({0,0,255}), 0.8,({255,255,0})}), 0.2,0.0,0.0,1.0 );</tt> -**! <br><illustration>return Image(200,100)->noise( ({0,({255,0,0}), 0.3,({0,255,0}), 0.6,({0,0,255}), 0.8,({255,255,0})}), 0.2,0.0,0.0,1.0 );</illustration> +**! <br><illustration>return Image.Image(200,100)->noise( ({0,({255,0,0}), 0.3,({0,255,0}), 0.6,({0,0,255}), 0.8,({255,255,0})}), 0.2,0.0,0.0,1.0 );</illustration> **! **! arg array(float|int|array(int)) colorrange **! colorrange table @@ -415,8 +415,8 @@ void image_noise(INT32 args) **! **! Example: <br> **! <tt>->turbulence( ({0,({229,204,204}), 0.9,({229,20,20}), 0.9,Color.black}) );</tt> -**! <br><illustration>return Image(200,100)-> -**! turbulence( ({0,({229,204,204}), 0.9,({229,20,20}), 0.9,Color.black}));</illustration> +**! <br><illustration>return Image.Image(200,100)-> +**! turbulence( ({0,({229,204,204}), 0.9,({229,20,20}), 0.9,Image.Color.black}));</illustration> **! arg array(float|int|array(int)) colorrange **! colorrange table **! arg int octaves diff --git a/src/modules/_Image_GIF/image_gif.c b/src/modules/_Image_GIF/image_gif.c index 00e10bf418fa72e75d37775b8df7df5852f363ca..bb54847ad45303ec8338fb1d35046ea486a8b701 100644 --- a/src/modules/_Image_GIF/image_gif.c +++ b/src/modules/_Image_GIF/image_gif.c @@ -1,9 +1,9 @@ -/* $Id: image_gif.c,v 1.5 2001/07/17 03:27:58 nilsson Exp $ */ +/* $Id: image_gif.c,v 1.6 2001/07/18 18:50:15 nilsson Exp $ */ /* **! module Image **! note -**! $Id: image_gif.c,v 1.5 2001/07/17 03:27:58 nilsson Exp $ +**! $Id: image_gif.c,v 1.6 2001/07/18 18:50:15 nilsson Exp $ **! submodule GIF **! **! This submodule keep the GIF encode/decode capabilities @@ -35,7 +35,7 @@ #include <ctype.h> #include "stralloc.h" -RCSID("$Id: image_gif.c,v 1.5 2001/07/17 03:27:58 nilsson Exp $"); +RCSID("$Id: image_gif.c,v 1.6 2001/07/18 18:50:15 nilsson Exp $"); #include "pike_macros.h" #include "object.h" #include "constants.h" @@ -609,8 +609,8 @@ CHRONO("gif _render_block end"); **! </pre> **! **! <illustration type=image/gif> -**! object nct=colortable(lena(),32,({({0,0,0})})); -**! string s=GIF.header_block(lena()->xsize(),lena()->ysize(),nct); +**! object nct=Image.colortable(lena(),32,({({0,0,0})})); +**! string s=Image.GIF.header_block(lena()->xsize(),lena()->ysize(),nct); **! foreach ( ({lena()->xsize(), **! (int)(lena()->xsize()*0.75), **! (int)(lena()->xsize()*0.5), @@ -623,14 +623,14 @@ CHRONO("gif _render_block end"); **! object o=lena()->scale(xsize,lena()->ysize()); **! object p=lena()->clear(0,0,0); **! p->paste(o,(lena()->xsize()-o->xsize())/2,0); -**! s+=GIF.render_block(p,nct,0,0,0,25); +**! s+=Image.GIF.render_block(p,nct,0,0,0,25); **! } -**! s+=GIF.netscape_loop_block(200); -**! s+=GIF.end_block(); +**! s+=Image.GIF.netscape_loop_block(200); +**! s+=Image.GIF.end_block(); **! return s; **! </illustration>The above animation is thus created: **! <pre> -**! object nct=colortable(lena,32,({({0,0,0})})); +**! object nct=Image.colortable(lena,32,({({0,0,0})})); **! string s=GIF.header_block(lena->xsize(),lena->ysize(),nct); **! foreach ( ({lena->xsize(), **! (int)(lena->xsize()*0.75), @@ -644,10 +644,10 @@ CHRONO("gif _render_block end"); **! object o=lena->scale(xsize,lena->ysize()); **! object p=lena->clear(0,0,0); **! p->paste(o,(lena->xsize()-o->xsize())/2,0); -**! s+=GIF.render_block(p,nct,0,0,0,25); +**! s+=Image.GIF.render_block(p,nct,0,0,0,25); **! } -**! s+=GIF.netscape_loop_block(200); -**! s+=GIF.end_block(); +**! s+=Image.GIF.netscape_loop_block(200); +**! s+=Image.GIF.end_block(); **! write(s); **! </pre> **!