OrbitCameraState

Drives a CameraState using a Filament Manipulator in ORBIT mode.

Create with rememberOrbitCameraState, pass the same CameraState to FilamentView, and attach Modifier.orbitGestures to the view's surface. Call setViewport whenever the surface size changes via Modifier.onSizeChanged.

Functions

Link copied to clipboard

Restore a previously saved bookmark.

Link copied to clipboard

Snap back to the initial eye/target position.

Link copied to clipboard

Save the current camera position as a bookmark to restore later.

Link copied to clipboard
fun setViewport(width: Int, height: Int)

Update whenever the render surface is resized.