Scene.html 2.2 KB
Newer Older
M
r59  
Mr.doob 已提交
1 2 3
<!DOCTYPE html>
<html lang="en">
	<head>
M
r82  
Mr.doob 已提交
4
		<meta charset="utf-8" />
M
r96  
Mr.doob 已提交
5
		<base href="../../../" />
M
r72  
Mr.doob 已提交
6 7 8
		<script src="list.js"></script>
		<script src="page.js"></script>
		<link type="text/css" rel="stylesheet" href="page.css" />
M
r59  
Mr.doob 已提交
9 10 11 12 13
	</head>
	<body>
		[page:Object3D] &rarr;
		<h1>[name]</h1>

M
r92  
Mr.doob 已提交
14
		<p class="desc">Scenes allow you to set up what and where is to be rendered by three.js. This is where you place objects, lights and cameras.</p>
M
r59  
Mr.doob 已提交
15 16 17 18 19 20


		<h2>Constructor</h2>


		<h3>[name]()</h3>
M
r92  
Mr.doob 已提交
21
		<p>
M
r66  
Mr.doob 已提交
22
		Create a new scene object.
M
r92  
Mr.doob 已提交
23
		</p>
M
r59  
Mr.doob 已提交
24 25 26 27


		<h2>Properties</h2>

M
r69  
Mr.doob 已提交
28
		<h3>[property:boolean autoUpdate]</h3>
M
r92  
Mr.doob 已提交
29
		<p>
M
r82  
Mr.doob 已提交
30 31
		Default is true. If set, then the renderer checks every frame if the scene and its objects needs matrix updates.
		When it isn't, then you have to maintain all matrices in the scene yourself.
M
r92  
Mr.doob 已提交
32
		</p>
M
r82  
Mr.doob 已提交
33 34

		<h3>[property:Object background]</h3>
M
r92  
Mr.doob 已提交
35
		<p>
M
r120  
Mr.doob 已提交
36 37
		If not null, sets the background used when rendering the scene, and is always rendered first.
		Can be set to a [page:Color] which sets the clear color, a [page:Texture] covering the canvas, a cubemap as a [page:CubeTexture] or [page:WebGLCubeRenderTarget] or an equirectangular as a [page:Texture] . Default is null.
M
r92  
Mr.doob 已提交
38
		</p>
M
r59  
Mr.doob 已提交
39

M
r112  
Mr.doob 已提交
40
		<h3>[property:Texture environment]</h3>
M
r92  
Mr.doob 已提交
41
		<p>
M
r112  
Mr.doob 已提交
42
		If not null, this texture is set as the environment map for all physical materials in the scene.
M
r118  
Mr.doob 已提交
43
		However, it's not possible to overwrite an existing texture assigned to [page:MeshStandardMaterial.envMap]. Default is null.
M
r92  
Mr.doob 已提交
44
		</p>
M
r83  
Mr.doob 已提交
45

M
r112  
Mr.doob 已提交
46 47 48 49 50 51 52 53 54 55
		<h3>[property:Fog fog]</h3>

		<p>A [page:Fog fog] instance defining the type of fog that affects everything rendered in the scene. Default is null.</p>

		<h3>[property:Material overrideMaterial]</h3>

		<p>If not null, it will force everything in the scene to be rendered with that material. Default is null.</p>

		<h2>Methods</h2>

M
r118  
Mr.doob 已提交
56
		<h3>[method:Object toJSON]( [param:Object meta] )</h3>
M
r112  
Mr.doob 已提交
57 58 59 60 61
		<p>
		meta -- object containing metadata such as textures or images for the scene.<br />
		Convert the scene to three.js [link:https://github.com/mrdoob/three.js/wiki/JSON-Object-Scene-format-4 JSON Object/Scene format].
		</p>

M
r59  
Mr.doob 已提交
62 63
		<h2>Source</h2>

M
r108  
Mr.doob 已提交
64 65 66
		<p>
			[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
		</p>
M
r59  
Mr.doob 已提交
67 68
	</body>
</html>