toViewCoordinatesRotation

fun toViewCoordinatesRotation(context: Context, cameraId: String, result: Rotation2D)

Creates the rotation required to convert from OpenGL coordinates to Android view coordinates.

This rotation does not take into account the reversal of y coordinates performed when estimating a transformation, and only takes into account the current display and camera orientation.

Parameters

context

Android context.

cameraId

A camera id.

result

instance where counter-clockwise rotation indicating the amount of display rotation respect the camera sensor will be stored.


fun toViewCoordinatesRotation(context: Context, characteristics: CameraCharacteristics, result: Rotation2D)

Creates the rotation required to convert from OpenGL coordinates to Android view coordinates.

This rotation does not take into account the reversal of y coordinates performed when estimating a transformation, and only takes into account the current display and camera orientation.

Parameters

context

Android context.

characteristics

Information about the camera.

result

instance where counter-clockwise rotation indicating the amount of display rotation respect the camera sensor will be stored.


fun toViewCoordinatesRotation(context: Context, cameraId: String): Rotation2D

Creates the rotation required to convert from OpenGL coordinates to Android view coordinates.

This rotation does not take into account the reversal of y coordinates performed when estimating a transformation, and only takes into account the current display and camera orientation.

Return

counter-clockwise rotation indicating the amount of display rotation respect the camera sensor.

Parameters

context

Android context.

  • @param cameraId A camera id.


fun toViewCoordinatesRotation(context: Context, characteristics: CameraCharacteristics): Rotation2D

Creates the rotation required to convert from OpenGL coordinates to Android view coordinates.

This rotation does not take into account the reversal of y coordinates performed when estimating a transformation, and only takes into account the current display and camera orientation.

Return

counter-clockwise rotation indicating the amount of display rotation respect the camera sensor.

Parameters

context

Android context.

characteristics

Information about the camera.