get function problem in Processing 2
in
Programming Questions
•
3 months ago
Hi,
But the get() return, only on the image that i have load, a strange int (is big).
I have write in Processing 2 this simple program:
- void setup() {
- size(800, 600);
- }
- void draw()
- {
- background(0);
- PImage myImage = loadImage("prova2.jpg");
- image(myImage, 200, 0, width, height);
- color k=get(500,500);
- fill(255,0,0);
- rect(200,0,width,height);
- fill(0,255,0);
- color c = get(400, 400);
- System.out.println(c+"-"+(color(255,0,0))+"-"+k);
- fill(c);
- noStroke();
- rect(0, 0, 180, height);
- }
Why don't works?
Thanks,
Marco!
2