Class Image_Graph_Color

Description

Class for color-handling

This is used to extend the functionality of the current PEAR::Image_Color v0.4. I hope to be allowed to incorporate some of the improvements in a new Image_Color release.

Located in /Graph/Color.php (line 45)

Image_Color
   |
   --Image_Graph_Color
Method Summary
 resource allocateColor (resource &$img, mixed $color)
 array color2RGB (mixed $color)
 array getRange (string $degrees)
Methods
allocateColor (line 60)

Allocates a color in the given image.

Userdefined color specifications get translated into an array of rgb values.

resource allocateColor (resource &$img, mixed $color)
  • resource &$img: GD-resource
  • mixed $color: any color representation supported by color2RGB()
color2RGB (line 81)

Convert any color-representation into an array of 4 ints (RGBA).

Userdefined color specifications get translated into an array of rgb values.

  • return: Array of 4 ints (RGBA-representation)
  • static:
  • access: public
array color2RGB (mixed $color)
  • mixed $color: any color representation supported by Image_Graph_Color::color2RGB()
getRange (line 149)

getRange Given a degree, you can get the range of colors between one color and another color.

  • return: Returns an array of all the colors, one element for each color.
  • access: public
array getRange (string $degrees)
  • string $degrees: How much each 'step' between the colors we should take.

Documentation generated on Sat, 21 Feb 2004 23:28:00 +0100 by phpDocumentor 1.3.0RC2