Fix #134 - Ability to scale camera preview horizontally and vertically on Android #160
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
CameraPreviewScaleYandCameraPreviewScaleXproperties to the camera view and implemented updates via theUpdatePreviewScaleon the camera manager.As far as I know, this is not a problem on iOS -- only with some Android devices. I did not provide an implementation in the iOS platform-specific code.
The reason this is needed is some Android devices do not provide the correct camera orientation. Thus, the PreviewView cannot orient itself correctly to the user's perspective.
An example of this is a Microtouch IDC 15-inch tablet. The screen orientation can be manually set (no internal accelerometer or gyro), but when you do this, the camera's orientation is not changed. This leaves the camera preview upside down or sideways in some cases.