You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
2.9 KiB
HTML

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!DOCTYPE html>
<html lang="zh">
<head>
<meta charset="utf-8" />
<base href="../../../" />
<script src="page.js"></script>
<link type="text/css" rel="stylesheet" href="page.css" />
</head>
<body>
[page:Object3D] &rarr;
<h1>场景([name]</h1>
<p class="desc">
场景能够让你在什么地方、摆放什么东西来交给three.js来渲染这是你放置物体、灯光和摄像机的地方。</p>
<h2>构造器</h2>
<h3>[name]()</h3>
<p>
创建一个新的场景对象。
</p>
<h2>属性</h2>
<h3>[property:Object background]</h3>
<p>
若不为空,在渲染场景的时候将设置背景,且背景总是首先被渲染的。
可以设置一个用于的“clear”的[page:Color]颜色、一个覆盖canvas的[page:Texture](纹理),
或是 a cubemap as a [page:CubeTexture] or an equirectangular as a [page:Texture]。默认值为null。
</p>
<h3>[property:Float backgroundBlurriness]</h3>
<p>
设置背景的模糊度。仅影响分配给 [page:Scene.background] 的环境贴图。有效输入是介于 *0* 到 *1*。默认值为 *0*。
</p>
<h3>[property:Float backgroundIntensity]</h3>
<p>
减弱背景色。仅适用于背景纹理。默认值为 `1`。
</p>
<h3>[property:Euler backgroundRotation]</h3>
<p>
背景的旋转(以弧度为单位)。仅影响分配给 [page:Scene.background]。默认值为 `(0,0,0)`。
</p>
<h3>[property:Texture environment]</h3>
<p>
若该值不为null则该纹理贴图将会被设为场景中所有物理材质的环境贴图。
然而,该属性不能够覆盖已存在的、已分配给 [page:MeshStandardMaterial.envMap] 的贴图。默认为null。
</p>
<h3>[property:Float environmentIntensity]</h3>
<p>
减弱环境色。仅影响指定给 [page:Scene.environment]。默认值为 `1`。
</p>
<h3>[property:Euler environmentRotation]</h3>
<p>
环境贴图的旋转(以弧度为单位)。仅在使用 [page:.environment] 时影响场景中的物理材质。默认值为 `(0,0,0)`。
</p>
<h3>[property:Fog fog]</h3>
<p>一个[page:Fog fog]实例定义了影响场景中的每个物体的雾的类型。默认值为null。
</p>
<h3>[property:Boolean isScene]</h3>
<p>
只读标志用于检查给定的对象是否属于 [name] 类型。
</p>
<h3>[property:Material overrideMaterial]</h3>
<p>如果不为空它将强制场景中的每个物体使用这里的材质来渲染。默认值为null。</p>
<h2>方法</h2>
<h3>[method:Object toJSON]</h3>
<p>
meta -- 包含有元数据的对象,例如场景中的的纹理或图片。
将scene对象转换为 three.js [link:https://github.com/mrdoob/three.js/wiki/JSON-Object-Scene-format-4 JSON Object/Scene format]three.js JSON 物体/场景格式)。
</p>
<h2>源代码</h2>
<p>
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
</p>
</body>
</html>