Expo Camera - Incorrect orientation of captured photo if device orientation is locked
See original GitHub issueSummary
When capturing a photo via the Expo Camera component, if the device is orientation locked in Portrait for example, and you then rotate to Landscape, the resulting photo is captured in Portrait. The iOS camera app and native SDK will ignore the system portrait lock setting when capturing photos.
Managed or bare workflow? If you have ios/
or android/
directories in your project, the answer is bare!
managed
What platform(s) does this occur on?
iOS
SDK Version (managed workflow only)
44.0.0
Environment
expo-env-info 1.0.2 environment info: System: OS: macOS 12.2.1 Shell: 5.8 - /bin/zsh Binaries: Node: 17.4.0 - /usr/local/bin/node Yarn: 1.22.11 - /usr/local/bin/yarn npm: 8.3.1 - /usr/local/bin/npm Watchman: 2022.01.31.00 - /usr/local/bin/watchman Managers: CocoaPods: 1.11.2 - /Users/nick/.rvm/gems/ruby-3.0.0/bin/pod SDKs: iOS SDK: Platforms: DriverKit 21.4, iOS 15.4, macOS 12.3, tvOS 15.4, watchOS 8.5 IDEs: Android Studio: 2020.3 AI-203.7717.56.2031.7678000 Xcode: 13.3/13E113 - /usr/bin/xcodebuild npmPackages: @expo/webpack-config: ~0.16.2 => 0.16.16 expo: ^44.0.0 => 44.0.5 react: 17.0.1 => 17.0.1 react-dom: 17.0.1 => 17.0.1 react-native: 0.64.3 => 0.64.3 react-native-web: 0.17.1 => 0.17.1 npmGlobalPackages: eas-cli: 0.39.0 expo-cli: 5.0.3 Expo Workflow: managed
Reproducible demo
Embed this component into any view and then enable rotation lock on your device, then take a photo.
Issue Analytics
- State:
- Created a year ago
- Comments:11
@yohamta Nothing I’ve seen. I’m thinking of making a Flutter app instead and hoping that doesn’t have the same problem
We ended up switching to React Native Camera. It is old and deprecated, but works. You could look at React Native Vision Camera.