Created
November 24, 2019 04:50
-
-
Save Lavanyagaur22/717491cfabbb3f6c0da0af94cb0a50b2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Get the system service for the camera manager | |
val manager = getSystemService(Context.CAMERA_SERVICE) as CameraManager | |
// Gets the first camera id | |
var cameraId = manager.getCameraIdList().get(0) | |
// Determine the rotation on the FritzVisionImage from the camera orientaion and the device rotation. | |
// "this" refers to the calling Context (Application, Activity, etc) | |
var imageRotationFromCamera = FritzVisionOrientation.getImageRotationFromCamera(this, cameraId) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment