imagecolorstotal

(PHP 4, PHP 5, PHP 7) Find out the number of colors in an image's palette int imagecolorstotal ( resource $image ) Returns the number of colors in an image palette. Parameters: image An image resource, returned by one of the image creation functions, such as imagecreatefromgif(). Returns: Returns the number of colors in the specified image's pale

imagecolorsforindex

(PHP 4, PHP 5, PHP 7) Get the colors for an index array imagecolorsforindex ( resource $image, int $index ) Gets the color for a specified index. Parameters: image An image resource, returned by one of the image creation functions, such as imagecreatetruecolor(). index The color index. Returns: Returns an associa

imagecolorset

(PHP 4, PHP 5, PHP 7) Set the color for the specified palette index void imagecolorset ( resource $image, int $index, int $red, int $green, int $blue [, int $alpha = 0 ] ) This sets the specified index in the palette to the specified color. This is useful for creating flood-fill-like effects in palleted images without the overhead of performing the actual flood-fill. Parameters: ima

imagecolorresolvealpha

(PHP 4 >= 4.0.6, PHP 5, PHP 7) Get the index of the specified color + alpha or its closest possible alternative int imagecolorresolvealpha ( resource $image, int $red, int $green, int $blue, int $alpha ) This function is guaranteed to return a color index for a requested color, either the exact color or the closest possible alternative. Parameters: image An image resour

imagecolorresolve

(PHP 4, PHP 5, PHP 7) Get the index of the specified color or its closest possible alternative int imagecolorresolve ( resource $image, int $red, int $green, int $blue ) This function is guaranteed to return a color index for a requested color, either the exact color or the closest possible alternative. If you created the image from a file, only colors used in the image are resolved. Colors present only in the palette are n

imagecolormatch

(PHP 4 >= 4.3.0, PHP 5, PHP 7) Makes the colors of the palette version of an image more closely match the true color version bool imagecolormatch ( resource $image1, resource $image2 ) Makes the colors of the palette version of an image more closely match the true color version. Parameters: image1 A truecolor image link resource. image2

imagecolorexactalpha

(PHP 4 >= 4.0.6, PHP 5, PHP 7) Get the index of the specified color + alpha int imagecolorexactalpha ( resource $image, int $red, int $green, int $blue, int $alpha ) Returns the index of the specified color+alpha in the palette of the image. Parameters: image An image resource, returned by one of the image creation functions, such as imagecreatetruecolor().

imagecolorexact

(PHP 4, PHP 5, PHP 7) Get the index of the specified color int imagecolorexact ( resource $image, int $red, int $green, int $blue ) Returns the index of the specified color in the palette of the image. If you created the image from a file, only colors used in the image are resolved. Colors present only in the palette are not resolved. Parameters: image An image resource, r

imagecolordeallocate

(PHP 4, PHP 5, PHP 7) De-allocate a color for an image bool imagecolordeallocate ( resource $image, int $color ) De-allocates a color previously allocated with imagecolorallocate() or imagecolorallocatealpha(). Parameters: image An image resource, returned by one of the image creation functions, such as imagecreatetruecolor(). color The c

imagecolorclosesthwb

(PHP 4 >= 4.0.1, PHP 5, PHP 7) Get the index of the color which has the hue, white and blackness int imagecolorclosesthwb ( resource $image, int $red, int $green, int $blue ) Get the index of the color which has the hue, white and blackness nearest the given color. Parameters: image An image resource, returned by one of the image creation functions, such as imagecreatet