提交 e9c6a16a 编写于 作者: L Lewy Blue

Updated HemisphereLight docs

上级 5b521a9f
......@@ -12,40 +12,73 @@
<h1>[name]</h1>
<div class="desc">A light source positioned directly above the scene.</div>
<div class="desc">
A light source positioned directly above the scene, with color fading from the sky color to the ground color.
This light cannot be used to cast shadows.
</div>
<h2>Example</h2>
<div>[example:webgl_lights_hemisphere lights / hemisphere ]</div>
<div>[example:misc_controls_pointerlock controls / pointerlock ]</div>
<div>[example:webgl_decals decals ]</div>
<div>[example:webgl_loader_collada_kinematics loader / collada / kinematics ]</div>
<div>[example:webgl_materials_lightmap materials / lightmap ]</div>
<div>[example:webgl_shaders_ocean shaders / ocean ]</div>
<div>
[example:webgl_lights_hemisphere lights / hemisphere ]<br />
[example:misc_controls_pointerlock controls / pointerlock ]<br />
[example:webgl_decals decals ]<br />
[example:webgl_loader_collada_kinematics loader / collada / kinematics ]<br />
[example:webgl_materials_lightmap materials / lightmap ]<br />
[example:webgl_shaders_ocean shaders / ocean ]
</div>
<code>var light = new THREE.HemisphereLight( 0xffffbb, 0x080820, 1 );
scene.add( light );</code>
<code>
var light = new THREE.HemisphereLight( 0xffffbb, 0x080820, 1 );
scene.add( light );
</code>
<h2>Constructor</h2>
<h3>[name]( [page:Integer skyColor], [page:Integer groundColor], [page:Float intensity] )</h3>
<div>
[page:Integer skyColor] — Numeric value of the RGB sky color.<br />
[page:Integer groundColor] — Numeric value of the RGB ground color.<br />
[page:Float intensity] — Numeric value of the light's strength/intensity.
<div>
[page:Integer skyColor] - (optional) hexadecimal color of the sky. Default is 0xffffff.<br />
[page:Integer groundColor] - (optional) hexadecimal color of the ground. Default is 0xffffff.<br />
[page:Float intensity] - (optional) numeric value of the light's strength/intensity. Default is 1.<br /><br />
Creates a new [name].
</div>
<h2>Properties</h2>
<div>
See the base [page:Light Light] class for common properties.
</div>
<h3>[property:Boolean castShadow]</h3>
<div>
This is set to *undefined* in the constructor as hemisphere lights cannot cast shadows.
</div>
See the base [page:Light Light] class for common properties.
<h3>[property:Float color]</h3>
<div>
The light's sky color, as passed in the constructor.
Default is a new [page:Color] set to white (0xffffff).
</div>
<h3>[property:Float groundColor]</h3>
<div>
The light's ground color, as passed in the constructor.
Default is a new [page:Color] set to white (0xffffff).
</div>
<h3>[property:Boolean isHemisphereLight]</h3>
<div>
Light's ground color.<br />
Used to check whether this or derived classes are hemisphere lights. Default is *true*.<br /><br />
You should not change this, as it used internally for optimisation.
</div>
<h3>[property:Vector3 position]</h3>
<div>
This is set equal to [page:Object3D.DefaultUp], so that the light shines from the top down.
</div>
<h2>Methods</h2>
......@@ -53,8 +86,8 @@ scene.add( light );</code>
<h3>[method:HemisphereLight copy]( [page:HemisphereLight source] )</h3>
<div>
<br />
Copies value of *source* to this HemisphereLight object.
Copies the value of [page:.color color], [page:.intensity intensity] and
[page:.groundColor groundColor] from the [page:Light source] light into this one.
</div>
<h2>Source</h2>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册