ALIGN_UL
ALIGN_UL
A class to provide a convenient way of watermarking images.
it uses preferences from the CGExtensions module admin panel.
set_text_color(int $red, int $green, int $blue)
Set the color for text based watermarking.
The default value for this setting is white (255,255,255)
int | $red | (red portion, between 0 and 255) |
int | $green | (green portion, between 0 and 255) |
int | $blue | (blue portion, between 0 and 255) |
set_background_color(int $red, int $green, int $blue, bool $transparent)
Set the background color for text based watermarks.
The default value is black (0,0,0) and transparent.
int | $red | The red value for the color (between 0 and 255) |
int | $green | The green value for the color (between 0 and 255) |
int | $blue | The blue value for the color (between 0 and 255) |
bool | $transparent | Wether the background color is to be treated as transparent. |
create_watermarked_image(string $srcfile, string $destfile) : bool
Watermark an input image given the current settings, and output it into the destination location.
string | $srcfile | The input file specification. Must be an image file |
string | $destfile | The output file specification. Must be a writable location. |