Loading

Pred

processing

Extracts the red value from a color, scaled to match current PcolorMode. The value is always returned as a double.

The Pred function is easy to use and understand, but it is slower than bit shifting.

Link to original Processing doc

Pred is available since version 1.0.0.

See also

Signatures

Examples

100 100 '2D' PGraphics 0x2Aff0000 //red, 0x2A transparent Pred //returns red value