static inline UByte SubtractCh(unsigned c1, unsigned c2);
SubtractCh combines two colors by taking the clamped difference of the two channels (c1 - c2). For 8 bit channels, the actual equation used is: max(c1 - c2, 0).
Parameters |
Description |
unsigned c1 |
The first (the destination) of two channels that are combined to form the new value (return value). |
unsigned c2 |
The second (the source) of two channels that are combined to form the new value (return value). |
An UByte value formed from the difference of the two channels (c1 - c2).