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

[Android] camera session is bound and idle on unmount 🐛 #1685

Closed
3 of 4 tasks
Skizu opened this issue Aug 9, 2023 · 1 comment · Fixed by #1466
Closed
3 of 4 tasks

[Android] camera session is bound and idle on unmount 🐛 #1685

Skizu opened this issue Aug 9, 2023 · 1 comment · Fixed by #1466
Labels
🐛 bug Something isn't working

Comments

@Skizu
Copy link

Skizu commented Aug 9, 2023

What were you trying to do?

An app that has multiple camera device controllers will be blocked from using camera devices or creating camera sessions due to unclosed and unbound camera sessions.

Reproduceable Code

No response

What happened instead?

Camera session unable to be created due to limit reached.

Relevant log output

2023-08-08 14:43:46.488 15004-15023 CameraManagerGlobal     {app_id}        I  Camera 0 facing CAMERA_FACING_BACK state now CAMERA_STATE_IDLE for client {app_id} API Level 2
...
2023-08-08 14:44:54.638 15004-15973 {TAG}      {app_id}        E  Camera2Session: Error: Camera device could not be opened because there are too many other open camera devices.
...

Device

Samsung S10-S22, Samsung XCover Pro V3-6, Pixel 3a-6

VisionCamera Version

2.15.5

Additional information

@mrousavy
Copy link
Owner

Hey! I've rewritten the entire Android codebase of VisionCamera from CameraX to Camera2 in the efforts of ✨ VisionCamera V3.

I just now completed the Camera2 rewrite and I believe the core structure is running, but there might be some edge cases to iron out. Can you try and test the PR #1674 for me to see if you can still reproduce this issue here?

Here's an instruction on how you can test that: #1674 (comment)

If the issue cannot be reproduced with that version/PR anymore, then hoorayy, I fixed it! 🎉
Otherwise please let me know and I'll keep this issue open to keep track of it.

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working
Projects
None yet
2 participants