threema-ch/webrtc-android

How to use CameraManager.setTorchMode in a video call?

Closed this issue · 2 comments

Hello, nice to use your open source project.
I encountered some problems in the process of using it. When I was talking, I wanted to use the settorchmode method of camera manger to turn on the flashlight of my mobile phone, but the system would throw an exception: android hardware. camera2.CameraAccessException: CAMERA_ IN_ Use (4): settorchmode:1905: torch for camera "0" is not available due to an existing camera user, how can I turn on the flashlight correctly when I am making a video call?

The version I use is ' ch.threema:webrtc-android:94.0.0 ',

Hi. As noted in the README:

⚠️ This build of WebRTC contains patches specific to Threema. We offer no support for this package outside of Threema.

Unfortunately we cannot offer support for general WebRTC or Android questions here. For WebRTC related questions, you could ask in the discuss-webrtc mailing list or on StackOverflow.

Also, as already mentioned above, this build of WebRTC contains patches specific to Threema. Certain aspects (for example RTP header extensions) may behave differently than stock WebRTC and you might run into compatibility issues in some cases.