设置天空参数
输入
| 参数 | 类型 | 必填 | 默认值 | 说明 |
|---|---|---|---|---|
cloudAltitude | string | 是 | 0.6 | 云层高度 |
cloudSpeed | string | 是 | 0.07 | 云朵速度 |
cloudDirection | string | 是 | 1.0 | 云朵方向 |
cloudShadows | string | 是 | true | 云朵阴影 |
fogDensity | string | 是 | 0.001 | 雾密度 |
fogDistance | string | 是 | 1.0 | 雾范围 |
skyLightIntensity | string | 是 | 1 | 天光强度 |
sunLightIntensity | string | 是 | 5 | 日光强度 |
sunAngle | string | 是 | 0 | 日光角度 |
moonShadow | string | 是 | true | 月光阴影 |
moonLightIntensity | string | 是 | 0.12 | 月光强度 |
moonScale | string | 是 | 0.7 | 月亮大小 |
moonPhase | string | 是 | 0.0 | 月相 |
showStar | string | 是 | false | 显示星系 |
starsIntensity | string | 是 | 0.75 | 星光强度 |
starsTiling | string | 是 | 3 | 星星密度 |
调用
typescript
piclient.emit("environment.setSkyParam",{
cloudAltitude: "0.6", //云层高度
cloudSpeed: "0.07", //云朵速度
cloudDirection: "1.0", //云朵方向
cloudShadows: "true", //云朵阴影
fogDensity: "0.001", //雾密度
fogDistance: "1.0", //雾范围
skyLightIntensity: "1", //天光强度
sunLightIntensity: "5", //日光强度
sunAngle: "0", //日光角度
moonShadow: "true", //月光阴影
moonLightIntensity: "0.12", //月光强度
moonScale: "0.7", //月亮大小
moonPhase: "0.0", //月相
showStar: "false", //显示星系
starsIntensity: "0.75", //星光强度
starsTiling: "3", //星星密度
})