-
new AreaLight(params)
-
面光源
Name Type Description params
Object optional 创建对象的属性参数。可包含此类的所有属性。
Extends
Members Show Inherited
Name | Type | Default | Description |
---|---|---|---|
isAreaLight
|
boolean | true | |
className
|
string | AreaLight | |
width
|
Number | 10 |
width |
height
|
Number | 10 |
height |
ltcTexture1
|
DataTexture |
ltcTexture1 |
|
ltcTexture2
|
DataTexture |
ltcTexture1 |
|
amount
|
Number | 1 |
inherited
光强度 |
enabled
|
Boolean | true |
inherited
是否开启灯光 |
constantAttenuation
|
Number | 1 |
inherited
光常量衰减值, PointLight 和 SpotLight 时生效 |
linearAttenuation
|
Number | 0 |
inherited
光线性衰减值, PointLight 和 SpotLight 时生效 |
quadraticAttenuation
|
Number | 0 |
inherited
光二次衰减值, PointLight 和 SpotLight 时生效 |
range
|
Number | 0 |
inherited
光照范围, PointLight 和 SpotLight 时生效, 0 时代表光照范围无限大。 |
shadow
|
object | null |
inherited
阴影生成参数,默认不生成阴影 |
isDirty
|
Boolean | false |
inherited
是否光照信息变化 |
color
|
Color | new Color(1, 1, 1) |
inherited
灯光颜色 |
-
staticAreaLight.ltcTexture1DataTexture
-
ltcTexture1
- Default Value:
- null
-
staticAreaLight.ltcTexture2DataTexture
-
ltcTexture2
- Default Value:
- null
-
staticAreaLight.ltcTextureReadyBoolean
-
ltcTexture 是否加载完成
- Default Value:
- false
-
staticAreaLight.ltcTextureUrlString
-
ltcTexture 地址
Methods Show Inherited
-
staticAreaLight.loadLtcTexture()
-
初始化 ltcTexture
-
inherited toInfoArray(out, offset)
-
获取光范围信息, PointLight 和 SpotLight 时生效
Name Type Description out
Array 信息接受数组
offset
Number 偏移值
-
inherited createShadowMap(renderer, camera)
-
生成阴影贴图,支持阴影的子类需要重写
Name Type Description renderer
WebGLRenderer camera
Camera