Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Black screen on some mobile chrome and safari #99

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

yamaha252
Copy link
Contributor

Fix #95

@@ -56,9 +56,9 @@ export class WebcamComponent implements AfterViewInit, OnDestroy {
private switchCameraSubscription: Subscription;
/** MediaStream object in use for streaming UserMedia data */
private mediaStream: MediaStream = null;
@ViewChild('video', { static: true }) private video: any;
@ViewChild('video', {static: true}) private video: any;
Copy link
Contributor Author

@yamaha252 yamaha252 Nov 25, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry for that changes

@jmeinke
Copy link

jmeinke commented Dec 22, 2020

Thanks for the fix @yamaha252 - we are facing the problem mentioned in #95 as well.
@basst314 It would be great if you could merge this and release a new version of the library!

@jmeinke
Copy link

jmeinke commented Dec 22, 2020

@yamaha252 Could you explain what the problem was? Why are your code changes fixing the problem?

@yamaha252
Copy link
Contributor Author

It seems twice execution of navigator.mediaDevices.enumerateDevices causes this issue. I changed WebcamUtil.getAvailableVideoInputs method to avoid execution if there are already video inputs. That's the main change.

@jmeinke
Copy link

jmeinke commented Jan 8, 2021

@basst314 Happy new year to you - it would be great if you could merge this sometime soon. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Black screen on live-demo
2 participants