rememberCameraState

fun rememberCameraState(eye: Position = Position(0f, 1f, 10f), target: Position = Position(0f, 0f, 0f), up: Direction = Direction(0f, 1f, 0f), projection: Projection = Projection.Perspective(), exposure: Exposure = Exposure(), shift: Float2 = Float2(0f, 0f), scaling: Float2 = Float2(1f, 1f)): CameraState

Creates and remembers a CameraState.

The initial values are used only on first composition; subsequent recompositions return the same instance regardless of changes to the parameters. To programmatically change the camera, mutate the returned state's fields.