- Name
-
GammaBrush -- correct gamma values of brush (V5.0)
- Synopsis
-
GammaBrush(id, red, green, blue)
- Function
-
This function can be used to gamma correct the color channels of the
specified brush. For each color channel, you have to pass a floating
point value that specifies the desired gamma correction. A value of
1.0 means no change, a value smaller than 1.0 darkens the channel, a
value greater than 1.0 lightens the channel.
Note that if id
specifies a palette brush, InvertBrush() will
just apply the gamma correction to the palette colors which makes this
function really fast when used with palette brushes.
- Inputs
-
- id
- brush to gamma correct
- red
- gamma correction for red channel
- green
- gamma correction for green channel
- blue
- gamma correction for blue channel
- Example
-
GammaBrush(1, 1.5, 1.0, 0.5)
The code above lightens the red channel and darkens the blue channel,
while leaving the green color channel untouched.