I'm trying to get the color of pixel, and "get" function returns me something like "-5526613", how to convert this value into something like "color(150,160,255,0)", or maybe even in simple grayscale value from 0 to 255 ?
After reading up on the color datatype, look under the Color > Creating & Reading area of the Reference for how to get values such as:
alpha()
blue()
brightness()
green()
hue()
red()
saturation()
...but keep in mind that what get() returns is a color. So you can set(c) another pixel with it, pass it to background(c), mix it with another color using lerpColor(c, c2) etc. etc. And if you want to print it:
Answers
https://Processing.org/reference/color_datatype.html
https://Processing.org/reference/rightshift.html
After reading up on the color datatype, look under the Color > Creating & Reading area of the Reference for how to get values such as:
...but keep in mind that what get() returns is a color. So you can set(c) another pixel with it, pass it to background(c), mix it with another color using lerpColor(c, c2) etc. etc. And if you want to print it:
thanks, people!