全球雾。

全球雾效果图
| Name | Type | Default | Description | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
props |
Object |
包含如下属性的Object:
|
|||||||||||||||||||||||||
callback |
CallbackBoolean |
null
|
optional
加载成功后触发的函数回调。 |
Example:
var fog = new CooWasm.GlobalFog({},(state)=>{console.log("load status:" + state)})
Demo:
Members
全球雾对象uuid。
全球雾显隐状态。
-
Default Value:
true
color : ColorObj
雾颜色。
全球雾组件uuid。
常熟。
-
Default Value:
26
幂数。
-
Default Value:
50
采样数。
-
Default Value:
3
Methods
从场景中销毁自身。
| Name | Type | Default | Description |
|---|---|---|---|
callback |
CallbackBoolean |
null
|
optional
销毁后触发的函数回调。 |
Returns:
null 空值。
Example:
fog = fog.destroy((state)=>{console.log("destroy status:" + state)})
获取全球雾包含的属性。
Returns:
是否获取成功。获取成功时,会自动赋值给属性。
Example:
fog.getProperties()
更新单个或者多个对象属性,使之立即生效。
| Name | Type | Default | Description | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
props |
Object |
optional
包含如下属性的Object。
|
|||||||||||||||||||
callback |
CallbackBoolean |
null
|
optional
加载成功后触发的函数回调。 |
Example:
fog.update({
bVisible:false
},(state)=>{console.log("update status:" + state)})