You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[camera_android] Wait for creating capture session when initializing (flutter#8894)
As discussed in the linked issue, this is an attempt to palliate one of the thread race conditions. In particular, returning to Dart possibly before creating the session and then let other function like "startImageStream" create a different session in parallel and interleave, causing the `java.lang.IllegalArgumentException: CaptureRequest contains unconfigured Input/Output Surface!` error.
Fixesflutter/flutter#165092
cc @camsim99
## Pre-Review Checklist
[^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
Copy file name to clipboardExpand all lines: packages/camera/camera_android/CHANGELOG.md
+4Lines changed: 4 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1,3 +1,7 @@
1
+
## 0.10.10+3
2
+
3
+
* Waits for the creation of the capture session when initializing the camera to avoid thread race conditions.
4
+
1
5
## 0.10.10+2
2
6
3
7
* Don't set the FPS range unless video recording. It can cause dark image previews on some devices becuse the auto exposure algorithm is more constrained after fixing the min/max FPS range to the same value. This change has the side effect that providing the `fps` parameter will not affect the camera preview when not video recording. And if you need a lower frame rate in your image streaming handler, you can skip frames by checking the time it passed since the last frame.
0 commit comments