pike.git
/
src
/
modules
/
Image
/
colors.c
version
»
Context lines:
10
20
40
80
file
none
3
pike.git/src/modules/Image/colors.c:1:
/* **! module Image **! note
-
**! $Id: colors.c,v 1.
30
2000/
02
/
03
19
:
02
:
22
grubba Exp $
+
**! $Id: colors.c,v 1.
31
2000/
07
/
07
13
:
56
:
45
grubba Exp $
**! submodule Color **! **! This module keeps names and easy handling **! for easy color support. It gives you an easy **! way to get colors from names. **! **! A color is here an object, containing color **! information and methods for conversion, see below. **! **! <ref>Image.Color</ref> can be called to make a color object.
pike.git/src/modules/Image/colors.c:172:
**! class Color **! This is the color object. It has six readable variables, **! <tt>r</tt>, <tt>g</tt>, <tt>b</tt>, for the <i>red</i>, **! <i>green</i> and <i>blue</i> values, **! and <tt>h</tt>, <tt>s</tt>, <tt>v</tt>, for **! the <i>hue</i>, <i>saturation</i> anv <i>value</i> values. */ #include "global.h"
-
RCSID("$Id: colors.c,v 1.
30
2000/
02
/
03
19
:
02
:
22
grubba Exp $");
+
RCSID("$Id: colors.c,v 1.
31
2000/
07
/
07
13
:
56
:
45
grubba Exp $");
#include "image_machine.h" #include <math.h> #include "stralloc.h" #include "pike_macros.h" #include "object.h" #include "constants.h" #include "interpret.h"
pike.git/src/modules/Image/colors.c:307:
f_aggregate(n); colornames=sp[-1].u.array; sp--; dmalloc_touch_svalue(sp); } #ifdef THIS #undef THIS /* Needed for NT */ #endif
-
#define THIS ((struct color_struct*)(fp->current_storage))
-
#define THISOBJ (fp->current_object)
+
#define THIS ((struct color_struct*)(
Pike_
fp->current_storage))
+
#define THISOBJ (
Pike_
fp->current_object)
static void init_color_struct(struct object *dummy) { THIS->rgb.r=THIS->rgb.g=THIS->rgb.b=0; THIS->name=NULL; } static void exit_color_struct(struct object *dummy) { if (THIS->name)