webcam-grabber

0.1.1 • Public • Published

Webcam Grabber

This is a simple npm module for grabbing input from the user's webcam. It is intended to be used in a setup similar to stackgl and processed using browserify.

I used this post as a starting point when figuring out how to use getUserMedia, and utilize the getusermedia npm package for cross-browser compatibilit.

Usage

Usage is pretty straightforward, you pass a width and height for the video capture and an optional argument with setting for the getUserMedia constraints object.

 
var webcamGrabber = require('webcam-grabber');
 
var video = webcamGrabber(600, 400, { audio: false });
 
document.body.appendChild(video);
 
video.play();
 

Example

To run the included example:

npm install
npm run example

The example uses the budo development server to run.

Package Sidebar

Install

npm i webcam-grabber

Weekly Downloads

2

Version

0.1.1

License

ISC

Last publish

Collaborators

  • amdayton