Questions tagged [webcam.js]

HTML5 Webcam Image Capture Library with Flash Fallback

is a small (~2.7K minified and gzipped) standalone library for capturing still images from your computer's camera, and delivering them to you as JPEG or PNG Data URIs. The images can then be displayed in your web page, rendered into a canvas, or submitted to your server. WebcamJS uses HTML5 getUserMedia, but provides an automatic and invisible Flash fallback.

WebcamJS is based on my old JPEGCam project, but has been redesigned for the modern web. Instead of relying on Flash and only being able to submit images directly to a server, WebcamJS delivers your images as client-side Data URIs, and it uses HTML5 getUserMedia where available. Flash is only used if your browser doesn't support getUserMedia, and the fallback is handled automatically.

Demo: http://pixlcore.com/demos/webcamjs/basic.html
GitHub: https://github.com/jhuckaby/webcamjs

78 questions
7
votes
3 answers

How can I open rear camera in mobile device using webcam.js?

I am using webcam.js by https://github.com/jhuckaby/webcamjs and In mobile devices, the front camera is opening by default. I want to change the default to the rear camera. Is there any way to change the camera device?
Shubham
  • 93
  • 1
  • 1
  • 8
6
votes
1 answer

Uploading image generated from webcam to mysql database with php not working

Trying to insert image generated from user webcam into mysql database with php, but it does not work. I am using webcam.js and everything works fine. When user takes a snapshot the image is stored on the server, however, the mysql insert does not…
Mickey Ulasi
  • 93
  • 2
  • 9
5
votes
6 answers

Webcam js Error in Chrome: Could not access webcam

I am using Webcam JS in one of my projects. https://github.com/jhuckaby/webcamjs version I was using: 1.0.0 Latest version available: 1.0.5 It was working fine in both Chrome and Firefox. But lately webcam error started showing only in CHROME.…
Sajeev C
  • 1,538
  • 4
  • 17
  • 30
4
votes
1 answer

Re prompt for Camera permission in JS after initial denial

I want to re-prompt for camera permission if the user denies it the first time. Code: navigator.mediaDevices.getUserMedia({video: true, audio: false}).then(function(){ document.getElementById("submitbutton").style.display="inline"; …
3
votes
1 answer

Is there any way to force showing ask permission in chrome?

I don't know if this is code issue or browser issue. Currently i'm using webcam.js to my web for showing camera. But when i open the page url. It shows error because the camera is not allowed. But why it's not showing permission before? When i…
3
votes
3 answers

convert base64 image to jpeg

Struggling to convert a base64 image captured using a webcam into a jpeg for upload. The following capture / display photo works (note that I am using webcam.min.js (which returns base64) and not webcam.js (which returns jpeg but relies on Flash)…
Ralph
  • 115
  • 1
  • 13
3
votes
1 answer

Render image from request in bottle

My intention is to upload an image and do some image processing. For now, I intend to render the uploaded image. I used the code here to build my front end and I wrote the backend in python using bottle, which is as follows: @route('/test',…
virupaksha
  • 363
  • 2
  • 11
3
votes
0 answers

How to save utf-8(ñ) in file_put_contents?

This code is working. it saves the photo using webcam.js. the problem is when I'm saving file with the file name of Peña its not working. I got a result of Peña.jpg or Pe?a.jpg file name. but in the database I got it right(peña). The problem is on…
kim de castro
  • 299
  • 6
  • 19
2
votes
0 answers

Webcam.set() not showing but Webcam.snap() works

I'm currently new to javascript and I'm attempting to learn to set my webcam and have it take a snap using js. However, only the Webcam.snap() works on my end. My Webcam.set() and Webcam.attach() won't show despite being able to take a…
2
votes
1 answer

Webcam.js Error: No supported webcam interface found

I'm using Webcam.js in my Laravel Project for capturing image. I have already come across from this thread (Webcam js Error in Chrome: Could not access webcam) I did same but still, I got this error: Webcam.js Error: No supported webcam interface…
Sayandeep Majumdar
  • 370
  • 1
  • 9
  • 20
2
votes
0 answers

How to get each frame from the webcam Reactjs

I am running web cam from navigator.media devices and its working fine, but I want to get each single frame from a video how can I achieve that? class Recognize extends Component { constructor(props) { super(props); this.videoTag…
Nabeel Ayub
  • 1,060
  • 3
  • 15
  • 35
2
votes
0 answers

WebcamJS : Uncaught TypeError: Cannot read property 'submit' of null

Im trying to customize my WebcamJS settings to work with AJAX post method but get this error. Uncaught TypeError: Cannot read property 'submit' of null I already following the steps on the documentation with just reading, copy it, and do some edit…
2
votes
1 answer

MediastreamTrack Stop - Webcam light on - HTTPS

Can anyone please help with the fix for https . I am able to stop the video streaming using stop() but the camera light is still on . Was not able to find any fix in the other posts mediaStream.stop(); //…
user2814819
  • 111
  • 1
  • 5
1
vote
2 answers

URI to Bitmap C# ASP.NET

I am capturing a URI in ASP.NET MVC with webcam.js. I would like to turn this URI to to bitmap in C#. Below is my current code for attempting to parse the URI into a bitmap, but it, but it gives error "Invalid length for a Base-64 char array or…
micah
  • 838
  • 7
  • 21
1
vote
2 answers

Can't figure out how to fix this: "Uncaught TypeError (webcam.snap is not a function)" <-- javascript

I have a JavaScript script that I am getting an error for that I can't figure out. I am trying to take a picture of the webcam feed using JavaScript The error is: Uncaught TypeError: webcam.snap is not a function I am using webcam.js to take the…
ironmantis7x
  • 807
  • 2
  • 23
  • 58
1
2 3 4 5 6