Processing Forum
a)if we try http://www.processing.org/reference/libraries/video/Capture.html
import processing.video.*; Capture myCapture; void setup() { size(200, 200); // The name of the capture device is dependent on // the cameras that are currently attached to your // computer. To get a list of the // choices, uncomment the following line // println(Capture.list()); // To select the camera, replace "Camera Name" // in the next line with one from Capture.list() // myCapture = new Capture(this, width, height, "Camera Name", 30); // This code will try to use the camera used myCapture = new Capture(this, width, height, 30); } void captureEvent(Capture myCapture) { myCapture.read(); } void draw() { image(myCapture, 0, 0); }
does nothing....
b)if we use http://www.processing.org/reference/libraries/video/Capture_available_.html
import processing.video.*; Capture myCapture; void setup() { size(200, 200); println(myCapture.list()); String s = "FaceTime HD Camera (Built-in)"; //the mane in
myCapture = new Capture(this, s, width, height, 30); } void draw() { // myCapture.available() returns true // when there is a new frame if(myCapture.available()) { myCapture.read(); } image(myCapture, 0, 0); }
the result:
The constructor Capture(sketch, String, int, int, is undefined)
c)http://www.processing.org/reference/libraries/video/captureEvent_.html
import processing.video.*; Capture myCapture; void setup() { size(200, 200); myCapture = new Capture(this, width, height, 30); } void draw() { image(myCapture, 0, 0); } void captureEvent(Capture myCapture) { myCapture.read(); }
...
nothing, the light of the camera does not work, and no frame is displayed.
what are we missing?
is there something to add to processing to use the webcamera?
the camera is working correctly in other programs...
thank you a lot