We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Hello,
(this is my first time posting)
I have a light temp. sensor connected to an arduino which sends the analog values of light temp. to processing to be graphed. What I would like is each bar in the graph to be colored according to the light temp. value it is displaying.
I have a table of light temps in 100K increments and corresponding color temps but i'm not sure how to go about converting the analog values into a color.
Do I use a 2D array? Would a table be better? Any info would help a lot.
Thank you
Answers
You can use the map function to convert the analog values into a range of colors. processing.org/reference/map_.html or use fill directly if you get the values in 255.
http://processing.org/reference/fill_.html
. Also check the Processing reference pagehttp://processing.org/reference/