I'm using the code below to view 3 webcams at once. But it only works with 2.
getCamera("0")
andgetCamera("1")
= ok%getCamera("1")
andgetCamera("2")
= ok%getCamera("0")
andgetCamera("2")
= no
No error appears, it just does not appear on the stage.
var cameras = Camera.names;
trace('Cameras: '+cameras);
// Cameras: Microsoft® LifeCam HD-3000,Integrated Webcam,USB2.0 Camera,IP Camera [JPEG/MJPEG]
// Camera.getCamera("0") = Microsoft® LifeCam HD-3000
// Camera.getCamera("1") = Integrated Webcam
// Camera.getCamera("2") = USB2.0 Camera
var camera0:Camera = Camera.getCamera("0");
camera0.setMode(400, 300, 100);
camera0.setQuality(0,100);
var video0:Video = new Video();
video0.smoothing = true;
video0.width = 400;
video0.height = 300;
video0.x=0;
video0.y=0;
video0.attachCamera(camera0);
addChild(video0);
var camera1:Camera = Camera.getCamera("1");
camera1.setMode(400, 300, 100);
camera1.setQuality(0,100);
var video1:Video = new Video();
video1.smoothing = true;
video1.width = 400;
video1.height = 300;
video1.x=400;
video1.y=0;
video1.attachCamera(camera1);
addChild(video1);
var camera2:Camera = Camera.getCamera("2");
camera2.setMode(400, 300, 100);
camera2.setQuality(0,100);
var video2:Video = new Video();
video2.smoothing = true;
video2.width = 400;
video2.height = 300;
video2.x=800;
video2.y=0;
video2.attachCamera(camera2);
addChild(video2);