Repository navigation
Conversation
|
@JakeF14-SN is attempting to deploy a commit to the Margelo Team on Vercel. A member of the Team first needs to authorize it. |
|
we also should start to use the RotationCoordinator to every output out there |
|
@ismaelsousa Amazing! I didnt see that PR before putting up my issue and pr, please feel free to close this one. Great to see that it was already being handled! I am happy to provide some physical device test coverage if you dont have an iPhone Duo (the device I was having issues with) |
|
@Jakef14, actually, this PR is exactly the next step of mine, we can combine both |
|
Great I will leave this PR up then! Let me know if anything is needed |
Use AVCaptureDevice.RotationCoordinator on iOS 17 and later, creating the interface orientation manager only on older versions. Apply preview rotation updates synchronously and clean up observation on reconfiguration and deinit. Related PR: margelo#4237 Validation: VisionCamera iOS target build, Swift formatting, and git diff --check passed.
|
@Jakef14 just ported the rotation coordinator into my branch and also removing on the unmount of the component. |
Use AVCaptureDevice.RotationCoordinator on iOS 17 and later, creating the interface orientation manager only on older versions. Apply preview rotation updates synchronously and clean up observation on reconfiguration and deinit. Related PR: margelo#4237 Validation: VisionCamera iOS target build, Swift formatting, and git diff --check passed.
|
@ismaelsousa I like that the preview updates are a module, however I feel the actual preview rotation should not come with a secondary module but should instead be a part of the base library |
|
@Jakef14 Oh, definitely, it's just a quick step while we are waiting for the fix that will come soon. The whole orientation needs to change, so probably the fix will come in the next iteration of the library. Meanwhile, we can extend it :) |
fb47f2d to
b102859
Compare
On iOS 17+, the preview's rotation now comes from AVCaptureDevice.RotationCoordinator (videoRotationAngleForHorizonLevelPreview) instead of the interface orientation. The interface orientation is 90° off on displays that aren't aligned with the camera, like the iPhone Duo's inner display, so the preview showed up rotated. Below iOS 17 it still uses HybridInterfaceOrientationManager.
Fixes #4236