Color::ModulateCh

Color::ModulateCh
static inline UByte ModulateCh(unsigned c1, unsigned c2);
Description

ModulateCh combines two colors by taking the clamped product of the two channels (c1 * c2). For 8 bit channels, the actual equation used is: (((c1+1) * c2)>>8).

Parameters
Parameters 
Description 
unsigned c1 
The first (the destination) of two channels that are multiplied to form the new value (return value). 
unsigned c2 
The second (the source) of two channels that are multiplied to form the new value (return value). 
Return Value

An UByte value formed from the product of the two channels (c1 * c2).

See Also