From 4cf6897337ef0f07dca6e40d724c45dcad9f0359 Mon Sep 17 00:00:00 2001 From: Hudson Miears Date: Tue, 9 Jan 2024 16:47:14 +0200 Subject: [PATCH 1/3] add sceneview ambientLightColor param --- .../main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt b/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt index 88a5124a0..f01a9af1d 100644 --- a/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt +++ b/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt @@ -24,6 +24,8 @@ import androidx.compose.runtime.getValue import androidx.compose.runtime.remember import androidx.compose.runtime.rememberUpdatedState import androidx.compose.ui.Modifier +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.graphics.toArgb import androidx.compose.ui.platform.LocalContext import androidx.compose.ui.platform.LocalLifecycleOwner import androidx.compose.ui.semantics.contentDescription @@ -68,6 +70,7 @@ import kotlinx.coroutines.launch * @param cameraController the [CameraController] to manage the position, orientation, and movement of the camera * @param timeExtent the [TimeExtent] used by the composable SceneView * @param onTimeExtentChanged lambda invoked when the composable SceneView's [TimeExtent] is changed + * @param ambientLightColor the color of the scene view's ambient light. * @param onNavigationChanged lambda invoked when the navigation status of the composable SceneView has changed * @param onSpatialReferenceChanged lambda invoked when the spatial reference of the composable SceneView has changed * @param onLayerViewStateChanged lambda invoked when the composable SceneView's layer view state is changed @@ -99,6 +102,7 @@ public fun SceneView( cameraController: CameraController = GlobeCameraController(), timeExtent: TimeExtent? = null, onTimeExtentChanged: ((TimeExtent?) -> Unit)? = null, + ambientLightColor: Color = Color(220, 220, 220, 255), onNavigationChanged: ((isNavigating: Boolean) -> Unit)? = null, onSpatialReferenceChanged: ((spatialReference: SpatialReference?) -> Unit)? = null, onLayerViewStateChanged: ((GeoView.GeoViewLayerViewStateChanged) -> Unit)? = null, @@ -128,6 +132,7 @@ public fun SceneView( it.selectionProperties = selectionProperties it.setTimeExtent(timeExtent) it.cameraController = cameraController + it.ambientLightColor = com.arcgismaps.Color(ambientLightColor.toArgb()) }) DisposableEffect(Unit) { From a25e0ea838e6ce247da02558bbe1bf261ea62708 Mon Sep 17 00:00:00 2001 From: Hudson Miears Date: Wed, 10 Jan 2024 12:31:10 +0200 Subject: [PATCH 2/3] fix doc --- .../main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt b/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt index 898d66bf6..6add3918a 100644 --- a/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt +++ b/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt @@ -74,7 +74,7 @@ import java.time.Instant * @param sunTime the position of the sun in the scene view based on a specific date and time * @param sunLighting the type of ambient sunlight and shadows in the scene view * @param onTimeExtentChanged lambda invoked when the composable SceneView's [TimeExtent] is changed - * @param ambientLightColor the color of the scene view's ambient light. + * @param ambientLightColor the color of the composable SceneView's ambient light. * @param onNavigationChanged lambda invoked when the navigation status of the composable SceneView has changed * @param onSpatialReferenceChanged lambda invoked when the spatial reference of the composable SceneView has changed * @param onLayerViewStateChanged lambda invoked when the composable SceneView's layer view state is changed From 0b8938e49da27489b914c0396aac96a84427911d Mon Sep 17 00:00:00 2001 From: Hudson Miears Date: Thu, 11 Jan 2024 18:32:11 +0200 Subject: [PATCH 3/3] rm full stop --- .../main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt b/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt index dccefe5b3..5d3c317fc 100644 --- a/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt +++ b/toolkit/geo-compose/src/main/java/com/arcgismaps/toolkit/geocompose/SceneView.kt @@ -77,7 +77,7 @@ import java.time.Instant * @param onTimeExtentChanged lambda invoked when the composable SceneView's [TimeExtent] is changed * @param sunTime the position of the sun in the scene view based on a specific date and time * @param sunLighting the type of ambient sunlight and shadows in the scene view - * @param ambientLightColor the color of the composable SceneView's ambient light. + * @param ambientLightColor the color of the composable SceneView's ambient light * @param onNavigationChanged lambda invoked when the navigation status of the composable SceneView has changed * @param onSpatialReferenceChanged lambda invoked when the spatial reference of the composable SceneView has changed * @param onLayerViewStateChanged lambda invoked when the composable SceneView's layer view state is changed