HSLa

Category: Arithmetics
Since engine version: 4.9.5.0 CE

Description

Creates a 32 bit color value from four parameters. Range is 0-255 for all parameters.

Syntax

int HSLa (int byH, int byS, int byL, int byA);

Parameters

byH:
Hue of the color. 0 is red, 85 is green, 170 is blue, and 255 is red again.
byS:
Saturation of the color. This is the color contrast.
byL:
Brightniss of the color. A brightness of 0 would correspond to RGB(0,0,0).
byA:
Transparency of the color.

Example

SetClrModulation(HSLa(0,0,255,64),FindObject(TRE1));
Colors a randomly chosen tree white and somewhat transparent.
See also: HSLa, RGB, RGBa
Newton, Juni 2005