فهرست منبع

Minor updates to Renderers docs

Lewy Blue 8 سال پیش
والد
کامیت
d3717df280
3فایلهای تغییر یافته به همراه103 افزوده شده و 56 حذف شده
  1. 28 24
      docs/api/renderers/WebGLRenderTarget.html
  2. 25 7
      docs/api/renderers/WebGLRenderTargetCube.html
  3. 50 25
      docs/api/renderers/WebGLRenderer.html

+ 28 - 24
docs/api/renderers/WebGLRenderTarget.html

@@ -10,7 +10,12 @@
 	<body>
 	<body>
 		<h1>[name]</h1>
 		<h1>[name]</h1>
 
 
-		<div class="desc">A render target is a buffer where the video card draws pixels for a scene that is being rendered in the background. It is used in different effects. </div>
+		<div class="desc">
+			A [link:https://msdn.microsoft.com/en-us/library/bb976073.aspx render target] is a buffer
+			where the video card draws pixels for a scene that	is being rendered in the background.
+			It is used in different effects, such as applying postprocessing to a rendered image
+			before displaying it on the screen.
+		</div>
 
 
 
 
 		<h2>Constructor</h2>
 		<h2>Constructor</h2>
@@ -19,27 +24,26 @@
 		<h3>[name]([page:Number width], [page:Number height], [page:Object options])</h3>
 		<h3>[name]([page:Number width], [page:Number height], [page:Object options])</h3>
 
 
 		<div>
 		<div>
-		width -- The width of the renderTarget. <br />
-		height -- The height of the renderTarget.
-		</div>
+		[page:Float width] - The width of the renderTarget. <br />
+		[page:Float height] - The height of the renderTarget.<br />
+		options - (optional0 object that holds texture parameters for an auto-generated target
+		texture and depthBuffer/stencilBuffer booleans.
 
 
-		<div>options is an optional object that holds texture parameters for an auto-generated target texture and depthBuffer/stencilBuffer booleans. For an explanation of the texture parameters see [page:Texture Texture].</div>
+		For an explanation of the texture parameters see [page:Texture Texture]. The following are
+		valid options:<br /><br />
 
 
-		<div>
-		wrapS — [page:Number] default is *THREE.ClampToEdgeWrapping*. <br />
-		wrapT — [page:Number] default is *THREE.ClampToEdgeWrapping*. <br />
-		magFilter — [page:Number], default is *THREE.LinearFilter*. <br />
-		minFilter — [page:Number], default is *THREE.LinearFilter*. <br />
-		format — [page:Number], default is *THREE.RGBAFormat*. <br />
-		type — [page:Number], default is *THREE.UnsignedByteType*. <br />
-		anisotropy — [page:Number], default is *1*. <br />
-		encoding — [page:Number], default is *THREE.LinearEncoding*. <br />
-		depthBuffer — [page:Boolean], default is *true*. Set this to false if you don't need it. <br />
-		stencilBuffer — [page:Boolean], default is *true*. Set this to false if you don't need it.
-		</div>
+		[page:Constant wrapS] - default is [page:Textures ClampToEdgeWrapping]. <br />
+		[page:Constant wrapT] - default is [page:Textures ClampToEdgeWrapping]. <br />
+		[page:Constant magFilter] - default is [page:Textures .LinearFilter]. <br />
+		[page:Constant minFilter] - default is [page:Textures LinearFilter]. <br />
+		[page:Constant format] - default is [page:Textures RGBAFormat]. <br />
+		[page:Constant type] - default is [page:Textures UnsignedByteType]. <br />
+		[page:Number anisotropy] - default is *1*. See [page:Texture.anistropy]<br />
+		[page:Constant encoding] - default is [page:Textures LinearEncoding]. <br />
+		[page:BooleandepthBuffer] - default is *true*. Set this to false if you don't need it. <br />
+		[page:BooleanstencilBuffer] - default is *true*. Set this to false if you don't need it.<br /><br />
 
 
-		<div>
-		Creates a new render target with a certain width and height.
+		Creates a new [name]]
 		</div>
 		</div>
 
 
 		<h2>Properties</h2>
 		<h2>Properties</h2>
@@ -58,7 +62,7 @@
 		<div>
 		<div>
 		The height of the render target.
 		The height of the render target.
 		</div>
 		</div>
-		
+
 		<h3>[property:Vector4 scissor]</h3>
 		<h3>[property:Vector4 scissor]</h3>
 		<div>
 		<div>
 		A rectangular area inside the render target's viewport. Fragments that are outside the area will be discarded.
 		A rectangular area inside the render target's viewport. Fragments that are outside the area will be discarded.
@@ -116,10 +120,10 @@
 		<div>
 		<div>
 		Dispatches a dispose event.
 		Dispatches a dispose event.
 		</div>
 		</div>
-		
-		
-		
-		
+
+
+
+
 
 
 		<h3>[page:EventDispatcher EventDispatcher] methods are available on this class.</h3>
 		<h3>[page:EventDispatcher EventDispatcher] methods are available on this class.</h3>
 
 

+ 25 - 7
docs/api/renderers/WebGLRenderTargetCube.html

@@ -9,13 +9,15 @@
 	</head>
 	</head>
 	<body>
 	<body>
 		[page:WebGLRenderTarget] &rarr;
 		[page:WebGLRenderTarget] &rarr;
-		
+
 		<h1>[name]</h1>
 		<h1>[name]</h1>
 
 
-		<div class="desc">[page:CubeCamera] uses this as its [page:WebGLRenderTarget]</div>
+		<div class="desc">
+			Used by the [page:CubeCamera] as its [page:WebGLRenderTarget].
+		</div>
 
 
 		<h2>Examples</h2>
 		<h2>Examples</h2>
-		
+
 		<div>See [page:CubeCamera] for examples.</div>
 		<div>See [page:CubeCamera] for examples.</div>
 
 
 
 
@@ -24,12 +26,28 @@
 
 
 		<h3>[name]([page:Number width], [page:Number height], [page:Object options])</h3>
 		<h3>[name]([page:Number width], [page:Number height], [page:Object options])</h3>
 		<div>
 		<div>
-		width -- The width of the renderTarget. <br />
-		height -- The height of the renderTarget. <br />
-		options -- The options sets the properties of the render target.
+		[page:Float width] - The width of the renderTarget. <br />
+		[page:Float height] - The height of the renderTarget. <br />
+		options - (optional0 object that holds texture parameters for an auto-generated target
+		texture and depthBuffer/stencilBuffer booleans.
+
+		For an explanation of the texture parameters see [page:Texture Texture]. The following are
+		valid options:<br /><br />
+
+		[page:Constant wrapS] - default is [page:Textures ClampToEdgeWrapping]. <br />
+		[page:Constant wrapT] - default is [page:Textures ClampToEdgeWrapping]. <br />
+		[page:Constant magFilter] - default is [page:Textures .LinearFilter]. <br />
+		[page:Constant minFilter] - default is [page:Textures LinearFilter]. <br />
+		[page:Constant format] - default is [page:Textures RGBAFormat]. <br />
+		[page:Constant type] - default is [page:Textures UnsignedByteType]. <br />
+		[page:Number anisotropy] - default is *1*. See [page:Texture.anistropy]<br />
+		[page:Constant encoding] - default is [page:Textures LinearEncoding]. <br />
+		[page:BooleandepthBuffer] - default is *true*. Set this to false if you don't need it. <br />
+		[page:BooleanstencilBuffer] - default is *true*. Set this to false if you don't need it.<br /><br />
+
+		Creates a new [name]]
 		</div>
 		</div>
 
 
-
 		<h2>Properties</h2>
 		<h2>Properties</h2>
 
 
 		<h3>[property:integer activeCubeFace]</h3>
 		<h3>[property:integer activeCubeFace]</h3>

+ 50 - 25
docs/api/renderers/WebGLRenderer.html

@@ -10,58 +10,83 @@
 	<body>
 	<body>
 		<h1>[name]</h1>
 		<h1>[name]</h1>
 
 
-		<div class="desc">The WebGL renderer displays your beautifully crafted scenes using WebGL, if your device supports it.</div>
+		<div class="desc">
+			The WebGL renderer displays your beautifully crafted scenes using
+			[link:https://en.wikipedia.org/wiki/WebGL WebGL].
+		</div>
 
 
 		<h2>Constructor</h2>
 		<h2>Constructor</h2>
 
 
 		<h3>[name]( [page:Object parameters] )</h3>
 		<h3>[name]( [page:Object parameters] )</h3>
-
 		<div>
 		<div>
-		parameters is an optional object with properties defining the renderer's behaviour.
+		[page:Object parameters] - (optional) object with properties defining the renderer's behaviour.
 			The constructor also accepts no parameters at all. In all cases, it will assume sane defaults
 			The constructor also accepts no parameters at all. In all cases, it will assume sane defaults
-			when parameters are missing.
-		</div>
+			when parameters are missing. The following are valid parameters:<br /><br />
+
+		[page:DOMElement canvas] - A [link:https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas canvas]
+		where the renderer draws its output.
+		This corresponds to the [page:WebGLRenderer.domElement domElement] property below.
+		If not passed in here, a new canvas element will be created.<br />
 
 
-		<div>
-		canvas — A [link:https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas canvas] where the renderer draws its output.
-		This corresponds to the [page:WebGLRenderer.domElement .domElement] property below.<br />
 
 
-		context — This can be used to attach the renderer to an existing [link:https://developer.mozilla.org/en-US/docs/Web/API/WebGLRenderingContext RenderingContext].<br />
+		[page:WebGLRenderingContext context] - This can be used to attach the renderer to an existing
+	  [link:https://developer.mozilla.org/en-US/docs/Web/API/WebGLRenderingContext RenderingContext].
+		Default is null.<br />
 
 
-		precision — Shader precision. Can be *"highp"*, *"mediump"* or *"lowp"*. Defaults to *"highp"* if supported by the device.<br />
+		[page:String precision] - Shader precision. Can be *"highp"*, *"mediump"* or *"lowp"*.
+		Defaults to *"highp"* if supported by the device. See the note in "Things to Avoid"
+		[link:https://developer.mozilla.org/en-US/docs/Web/API/WebGL_API/WebGL_best_practices here].<br />
 
 
-		alpha — whether the canvas contains an alpha (transparency) buffer or not. Default is *false*.<br />
+		[page:Boolean alpha] - whether the canvas contains an alpha (transparency) buffer or not.
+	  Default is *false*.<br />
 
 
-		premultipliedAlpha — whether the renderer will assume that colors have premultiplied alpha. Default is *true*.<br />
+		[page:Boolean premultipliedAlpha] - whether the renderer will assume that colors have
+		[link:https://en.wikipedia.org/wiki/Glossary_of_computer_graphics#Premultiplied_alpha premultiplied alpha].
+		Default is *true*.<br />
 
 
-		antialias — whether to perform antialiasing. Default is *false*.<br />
+		[page:Boolean antialias] - whether to perform antialiasing. Default is *false*.<br />
 
 
-		stencil — whether the drawing buffer has a stencil buffer of at least 8 bits. Default is *true*.<br />
+		[page:Boolean stencil] - whether the drawing buffer has a
+		[link:https://en.wikipedia.org/wiki/Stencil_buffer stencil buffer] of at least 8 bits.
+		Default is *true*.<br />
 
 
-		preserveDrawingBuffer — whether to preserve the buffers until manually cleared or overwritten. Default is *false*.<br />
+		[page:Boolean preserveDrawingBuffer] - whether to preserve the buffers until manually cleared
+	  or overwritten. Default is *false*.<br />
 
 
-		depth — whether the drawing buffer has a depth buffer of at least 16 bits. Default is *true*.<br />
+		[page:Boolean depth] - whether the drawing buffer has a
+		[link:https://en.wikipedia.org/wiki/Z-buffering depth buffer] of at least 16 bits.
+		Default is *true*.<br />
 
 
-		logarithmicDepthBuffer —  whether to use a lograthimic depth buffer. Default is *false*.
-		See the [example:webgl_camera_logarithmicdepthbuffer camera / logarithmicdepthbuffer] example.
+		[page:Boolean logarithmicDepthBuffer] -  whether to use a logarithmic depth buffer. It may
+		be neccesary to use this if dealing with huge differences in scale in a single scene.
+		Default is *false*. See the [example:webgl_camera_logarithmicdepthbuffer camera / logarithmicdepthbuffer] example.
 		</div>
 		</div>
 
 
 		<h2>Properties</h2>
 		<h2>Properties</h2>
 
 
 		<h3>[property:Boolean autoClear]</h3>
 		<h3>[property:Boolean autoClear]</h3>
-		<div>Defines whether the renderer should automatically clear its output before rendering.</div>
+		<div>Defines whether the renderer should automatically clear its output before rendering a frame.</div>
 
 
 
 
 		<h3>[property:Boolean autoClearColor]</h3>
 		<h3>[property:Boolean autoClearColor]</h3>
-		<div>If autoClear is true, defines whether the renderer should clear the color buffer. Default is *true*.</div>
+		<div>
+			If [page:.autoClear autoClear] is true, defines whether the renderer should clear the color buffer.
+			Default is *true*.
+		</div>
 
 
 
 
 		<h3>[property:Boolean autoClearDepth]</h3>
 		<h3>[property:Boolean autoClearDepth]</h3>
-		<div>If autoClear is true, defines whether the renderer should clear the depth buffer. Default is *true*.</div>
+		<div>
+			If [page:.autoClear autoClear] is true, defines whether the renderer should clear the depth buffer.
+			Default is *true*.
+		</div>
 
 
 
 
 		<h3>[property:Boolean autoClearStencil]</h3>
 		<h3>[property:Boolean autoClearStencil]</h3>
-		<div>If autoClear is true, defines whether the renderer should clear the stencil buffer. Default is *true*.</div>
+		<div>
+			If [page:.autoClear autoClear] is true, defines whether the renderer should clear the stencil buffer.
+			Default is *true*.
+		</div>
 
 
 		<h3>[property:Object capabilities]</h3>
 		<h3>[property:Object capabilities]</h3>
 		<div>
 		<div>
@@ -357,9 +382,9 @@
 		<div>Render a buffer geometry group using the camera and with the specified material.</div>
 		<div>Render a buffer geometry group using the camera and with the specified material.</div>
 
 
 		<h3>[method:null renderBufferImmediate]( [page:Object3D object], [page:shaderprogram program], [page:Material shading] )</h3>
 		<h3>[method:null renderBufferImmediate]( [page:Object3D object], [page:shaderprogram program], [page:Material shading] )</h3>
-		<div>object  an instance of [page:Object3D]<br />
-		program  an instance of shaderProgram<br />
-		shading  an instance of Material<br /><br />
+		<div>object - an instance of [page:Object3D]<br />
+		program - an instance of shaderProgram<br />
+		shading - an instance of Material<br /><br />
 
 
 		Render an immediate buffer. Gets called by renderImmediateObject.
 		Render an immediate buffer. Gets called by renderImmediateObject.
 		</div>
 		</div>