react-native-camera-kit
react-native-camera-kit copied to clipboard
[ios 14] wrong orientation
when I use iOS 14 device take a picture, I got wrong orientation of Image.
--
debug it, I got [UIDevice currentDevice].orientation == UIDeviceOrientationPortrait
as picture above, the orientation value is 1, but after captureStillImageAsynchronouslyFromConnection
, the orientation in imageDataSampleBuffer
is 6. And final Image's orientation is 6 too.
In Portrait, camera looks good but if I change to landscape then camera is not rotating correctly it shows image in opposite direction.
This still seems to be an issue
Still it is an issue. Working perfectly when screen is in PORTRAIT mode but not rotating when screen is in LANDSCAPE mode. Anyone please 🥴
@aarongrider ser please 🙏
Should be fixed by #547
To elaborate on David's comment, while mostly fixed, many of these issues are caused by the rotation of the UI. I highly recommend locking the UI orientation to portrait and optionally using the onOrientationChange
event handler to rotate UI elements manually. This is what the native iOS+Android camera does on phones.
The problem is that iOS does not expose what orientation the phone is in if the user uses orientation lock, which means we cannot reliably know which orientation the phone should be considered to be in. So we are integrating accelerometer readings into the camera to interpret it, so pictures get orientated the way you'd expect (instead of what the OS reports).
@scarlac when you guys planing to release this new feature?
We are preparing a beta release soon. You will be able to update to that one until we do a full release once it’s been battle tested and docs are fully up to date
This is working for me on beta v14