Selaa lähdekoodia

Update WebGLRenderer.html (#23209)

translate and remove `clearTarget` meth from zh-CN doc.
Keriy 3 vuotta sitten
vanhempi
commit
9d7d148d83
1 muutettua tiedostoa jossa 8 lisäystä ja 22 poistoa
  1. 8 22
      docs/api/zh/renderers/WebGLRenderer.html

+ 8 - 22
docs/api/zh/renderers/WebGLRenderer.html

@@ -44,10 +44,8 @@
 
 		[page:String powerPreference] - 提示用户代理怎样的配置更适用于当前WebGL环境。 可能是*"high-performance"*, *"low-power"* 或 *"default"*。默认是*"default"*.
 		详见[link:https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.12 WebGL spec]<br />
-
-
-		[page:Boolean failIfMajorPerformanceCaveat] - whether the renderer creation will fail upon low perfomance is detected. Default is *false*.
-		See [link:https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.12 WebGL spec] for details.<br />
+			
+		[page:Boolean failIfMajorPerformanceCaveat] - 检测渲染器是否会因性能过差而创建失败。默认为false。详见 [link:https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.12 WebGL spec] for details.<br />
 
 		[page:Boolean depth] - 绘图缓存是否有一个至少6位的深度缓存([link:https://en.wikipedia.org/wiki/Z-buffering depth buffer] )。
 		默认是*true*.<br />
@@ -143,7 +141,7 @@
 		<p>查看[page:Textures texture constants]页面以获取其他格式细节</p>
 
 		<h3>[property:Object info]</h3>
-		<p>一个对象,包含有关图形板内存和渲染过程的一系列统计信息。这些信息可用于调试或仅仅满足下好奇心。对象包含以下字段:</p>
+		<p>一个对象,包含有关图形板内存和渲染过程的一系列统计信息。这些信息可用于调试或仅仅满足下好奇心。对象包含以下字段:</p>
 		<p>
 		<ul>
 			<li>memory:
@@ -165,12 +163,11 @@
 			</li>
 		</ul>
 		</p>
-		<p>By default these data are reset at each render call but when having multiple render passes per frame (e.g. when using post processing) it can be preferred to reset with a custom pattern.
-			First, set *autoReset* to *false*.
+		<p>默认情况下,这些字段在每次渲染调用时都会重置,但是当每帧有多个渲染通道时(例如,使用后处理时),最好使用自定义模式重置。先将 autoReset 设置为 false.
 		<code>
 		renderer.info.autoReset = false;
 		</code>
-		Call *reset()* whenever you have finished to render a single frame.
+		然后在单个帧时渲染完成后调用 reset().
 		<code>
 		renderer.info.reset();
 		</code>
@@ -220,7 +217,7 @@
 		定义渲染器是否应对对象进行排序。默认是*true*.<br /><br />
 
 		说明: 排序用于尝试正确渲染出具有一定透明度的对象。根据定义,排序可能不总是有用。根据应用的需求,可能需要关闭排序并使其他方法来处理透明度的渲染,例如,
-		手动确定每个对象的显然顺序。
+		手动确定每个对象的渲染顺序。
 		</p>
 
 		<h3>[property:Object state]</h3>
@@ -260,17 +257,6 @@
 		<h3>[method:undefined clearStencil]( )</h3>
 		<p>清除模板缓存。相当于调用[page:WebGLRenderer.clear .clear]( false, false, true )</p>
 
-		<h3>[method:undefined clearTarget]([param:WebGLRenderTarget renderTarget], [param:Boolean color], [param:Boolean depth], [param:Boolean stencil])</h3>
-		<p>
-		renderTarget -- 需要被清除的[page:WebGLRenderTarget renderTarget]<br />
-		color -- 如果设置, 颜色会被清除 <br />
-		depth -- 如果设置, 深度缓存会被清除 <br />
-		stencil -- 如果设置, 模板缓存会被清除
-		</p>
-		<p>
-		该方法清楚了一个rendertarget。为此它会激活此endertarget
-		</p>
-
 		<h3>[method:undefined compile]( [param:Object3D scene], [param:Camera camera] )</h3>
 		<p>使用相机编译场景中的所有材质。这对于在首次渲染之前预编译着色器很有用。</p>
 
@@ -341,7 +327,7 @@
 		<p>返回包含渲染器输出canvas的宽度和高度(单位像素)的对象。</p>
 
 		<h3>[method:undefined initTexture]( [param:Texture texture] )</h3>
-		<p> Initializes the given texture. Useful for preloading a texture rather than waiting until first render (which can cause noticeable lags due to decode and GPU upload overhead).</p>
+		<p>初始化给定的纹理。用于预加载纹理而不是等到第一次渲染(可能会由于解码和 GPU 上传的开销而导致明显的延迟).</p>
 
 		<h3>[method:undefined resetGLState]( )</h3>
 		<p>将GL状态重置为默认值。WebGL环境丢失时会内部调用</p>
@@ -364,7 +350,7 @@
 		</p>
 
 		<h3>[method:undefined resetState]()</h3>
-		<p>Can be used to reset the internal WebGL state. This method is mostly relevant for applications which share a single WebGL context across multiple WebGL libraries.</p>
+		<p>可用于重置内部 WebGL 状态。此方法主要与跨多个 WebGL 库共享单个 WebGL 上下文的应用程序相关。</p>
 
 		<h3>[method:undefined setAnimationLoop]( [param:Function callback] )</h3>
 		<p>[page:Function callback] — 每个可用帧都会调用的函数。 如果传入‘null’,所有正在进行的动画都会停止。</p>