You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you create a canvas with P2D or P3D, the webcam capture does not contain any data (it is an array of black pixels).
Expected Behavior
The capture object pixel array should contain data
Current Behavior
The capture object pixel array contains all black
Steps to Reproduce
Run this program
import processing.video.*;
Capture video;
PImage theImage;
void setup() {
//this loads an array of black pixels
size(640, 480, P3D);
//this works as expected
//size(640, 480);
video = new Capture(this, 640, 480);
video.start();
}
Description
When you create a canvas with P2D or P3D, the webcam capture does not contain any data (it is an array of black pixels).
Expected Behavior
The capture object pixel array should contain data
Current Behavior
The capture object pixel array contains all black
Steps to Reproduce
Run this program
import processing.video.*;
Capture video;
PImage theImage;
void setup() {
//this loads an array of black pixels
size(640, 480, P3D);
//this works as expected
//size(640, 480);
video = new Capture(this, 640, 480);
video.start();
}
void draw(){
if (video.available()) video.read();
theImage = video.get();
theImage.loadPixels();
image(theImage,0,0);
}
Your Environment
The text was updated successfully, but these errors were encountered: