Comments (5)
@ikeliec For android devices, I had used the following steps to provide switch camera functionality
-
Add a button to switch / toggle the camera
-
Onclick of button reset the camera using the reset method
Webcam.reset();
-
Re-Initialise the camera
`cameraFacingMode = (cameraFacingMode == 'user') ? 'environment' : 'user'; Webcam.set({ width: 50, height: 50, flip_horiz: true, image_format: 'jpeg', jpeg_quality: 100, constraints: { facingMode: cameraFacingMode } });
`
- Attach camera to the div
Webcam.attach('#capture_img');
from webcamjs.
Hello, what have you tried.? Can you share some codes.
from webcamjs.
Awesome! @ankush-maherwal . It worked...
Thanks! Gracias!! I appreciate.
from webcamjs.
@ikeliec For android devices, I had used the following steps to provide switch camera functionality
- Add a button to switch / toggle the camera
- Onclick of button reset the camera using the reset method
Webcam.reset();
- Re-Initialise the camera
`cameraFacingMode = (cameraFacingMode == 'user') ? 'environment' : 'user'; Webcam.set({ width: 50, height: 50, flip_horiz: true, image_format: 'jpeg', jpeg_quality: 100, constraints: { facingMode: cameraFacingMode } });
`
- Attach camera to the div
Webcam.attach('#capture_img');
Doesn't work for me, I checked the source code and there's no parameter for facingMode or cameraFacingMode. Should I add it into the source code first?
from webcamjs.
Awesome! @ankush-maherwal . It worked...
Thanks! Gracias!! I appreciate.
Can you show your code how it works? I couldn't get it to flip on my phone browser
from webcamjs.
Related Issues (20)
- Webcam.js Error: No supported webcam interface found HOT 2
- Demo Website Not Working in Chrome, Works in IE and Microsoft Edge HOT 2
- On the problem that the func function in snap function is undefined
- Webcam Not working for IE11 in React project HOT 1
- No supported webcam interface is found
- I am using webcam.js plugin to use camera in web app. But i am not getting solution for choose front or rear camera choice. please give me some solution to use camera choice. HOT 1
- Iphone open device camera instead of web camera
- How to turn off after snapshat?
- Capture webcam in IE11 HOT 2
- webcam.js displays black screen on initialization in android webview
- webcam.swf's allowDomain * detected as potential vulnerability HOT 1
- Webcam.js Error: Could not access webcam: NotAllowedError: Permission denied NotAllowedError: Permission denied
- Remove Red Icon on browser tab HOT 1
- Webcam.Snap firing more than once
- Facial guideline on canvas
- Edge Mobile (Android) requires video.play();
- Plain Green image returned on some android devices
- When webcam node is hidden, live images are not getting captured properly in safari HOT 1
- Demo links are broken HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from webcamjs.