Skip to content

Commit

Permalink
chore(web): override default light (#667)
Browse files Browse the repository at this point in the history
  • Loading branch information
keiya01 committed Sep 7, 2023
1 parent 422decc commit b3c7e8c
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions web/src/beta/lib/core/engines/Cesium/hooks.ts
Expand Up @@ -132,6 +132,16 @@ export default ({
: undefined,
intensity: property.light?.lightIntensity,
});
} else {
light = cesium.current?.cesiumElement?.scene.light;
if (light) {
light.color = property?.light?.lightColor
? Color.fromCssColorString(property.light.lightColor)
: light.color;
light.intensity = property?.light?.lightIntensity
? property.light.lightIntensity
: light.intensity;
}
}
return light;
}, [
Expand Down

0 comments on commit b3c7e8c

Please sign in to comment.