getRelativeRotation
fun getRelativeRotation(destRotationDegrees: Int, sourceRotationDegrees: Int, isOppositeFacing: Boolean): Int
Calculates the delta between a source rotation and destination rotation.
A typical use of this method would be calculating the angular difference between the display orientation (destRotationDegrees) and camera sensor orientation (sourceRotationDegrees).
Parameters
destRotationDegrees
The destination rotation relative to the device's natural rotation.
sourceRotationDegrees
The source rotation relative to the device's natural rotation.
isOppositeFacing
Whether the source and destination planes are facing opposite directions.