Quantcast
Channel: Processing Forum
Viewing all articles
Browse latest Browse all 1768

Re : Capturing images from webcam

$
0
0

Thanks..
this will only turn  on my webcam..
but the issue is that  i want whenever the code is run it will automatically open the webcam and capture an image..
the below program does only opening the webcam..
  1. import processing.video.*;
    Capture webcam;

    void setup() {
      size(640,480);
      webcam = new Capture(this,640,480); 
      String[] devices = Capture.list();
      println(devices);
      webcam.start();
     
    }

    void draw() {
      if (webcam.available() == true) {
        webcam.read();
        image(webcam ,0,0);
      }
      saveFrame("line.bmp");
    }

Viewing all articles
Browse latest Browse all 1768

Trending Articles