Update from 2012, November — you may want to read about newer approach to use camera from JS — webrtc and getUserMedia.
CamCanvas API 0.2
- Get the list of available Cameras.
- Initialize the camera with the resolution width and height.
- Capture Webcam Images via JavaScript.
- Access the webcam image using the canvas tag.
- Manipulate, encode, upload as you wish.
- ____ and what else?
This is a demonstration of the CamCanvas JS API. The following box has a flash widget ( SWF ) object which requests permission to access your camera. In this sample, there are no server-side capture or requests going on after the page is loaded. If you allow the cam access and click the button capture, the captured image should appear in the second box bellow the live camera image. That box has a canvas HTML5 element.
For code information please visit the github repository.
Demostrations
- Face Detection JS app by Bruno Barreto
- Remix your Webcam with Foxkeh Mozilla
- ___ add yours here___
Samples
The following box has a canvas tag. Pick one of the functions to render the image from the webcam to the canvas. Each function performs pixel operations to the webcam bits before drawing to the canvas element. To see the sample source code please check the CamCanvas JS API github repository samples.