Light
fun FilamentSceneScope.Light(type: LightManager.Type, vararg keys: Any?, configure: LightManager.Builder.() -> Unit)
Low-level escape hatch: adds a light configured directly through the raw LightManager.Builder, for cases the typed composables (DirectionalLight, SpotLight, …) don't cover. You own the full builder; this composable only manages the entity, scene membership, and (when inside a Group) the transform so the light follows the group.
The component is built once and rebuilt whenever any value in keys changes — pass every input your configure reads so updates take effect (same convention as FilamentEffect and rememberMaterialInstance). When the light is not parented, positioning is via builder.position(...); inside a Group, it follows the group instead.
Light(LightManager.Type.SPOT, intensity) {
position(2f, 3f, 0f); direction(0f, -1f, 0f)
intensity(intensity); spotLightCone(0.3f, 0.5f)
castShadows(true)
}Content copied to clipboard