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

[windows] Crash accessing video camera if the camera is used by other app #18

Closed
ashellunts opened this issue Dec 6, 2021 · 4 comments

Comments

@ashellunts
Copy link
Contributor

Crash occurs when calling base_->factory_->CreateVideoTrack(source, uuid.c_str()); in FlutterMediaStream::GetUserVideo.

Crash is inside libwebrtc.
Also there is no (or I don't see) a way to understand that camera is busy and don't call createVideoTrack.

@cloudwebrtc
Copy link
Member

I think this needs to be traced to the video capture device level to find a solution.

https://github.com/webrtc-sdk/webrtc/tree/main/modules/video_capture/windows

@cloudwebrtc
Copy link
Member

cloudwebrtc commented Dec 6, 2021

1, If flutter-webrtc itself needs to create video capture multiple times, we need a video capture proxy to allow multiple sinks to capture the camera

2,If other applications occupy the camera, we can only inform the user that the camera cannot be obtained and prevent the crash from occurring.

@ashellunts
Copy link
Contributor Author

Sounds good 👍

@ashellunts
Copy link
Contributor Author

Currently https://github.com/webrtc-sdk/webrtc/blob/main/test/vcm_capturer.h is used for capturing on windows.
Will try to fix the bug if it takes not too long.

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

No branches or pull requests

2 participants