HTML/CSS3: getUserMedia
Trick for accessing the camera
HTML/CSS3: getUserMedia
3 types of parameters:
constraints – This should be an object that specifies which media streams you would like to access. For example, to get both video and audio you would use: { video: true, audio: true }
successCallback – A function that will be called if the media stream is successfully loaded. The function will be passed a LocalMediaStream object.
errorCallback (optional) – A function that will be called if the media stream cannot be loaded.
HTML/CSS3: getUserMedia
What about Safari?
<input type="file" accept="image/*" capture="camera"> <input type="file" accept="video/*" capture="camera">
Javascript API's
PhoneGap Plugins:
Flashlight Demo
From scratch or using Dreamweaver