diff --git a/docs/api/zh/geometries/BoxGeometry.html b/docs/api/zh/geometries/BoxGeometry.html index 53fea8cdcba7e7..1de21d47733af5 100644 --- a/docs/api/zh/geometries/BoxGeometry.html +++ b/docs/api/zh/geometries/BoxGeometry.html @@ -11,7 +11,9 @@
[name]是四边形的原始几何类,它通常使用构造函数所提供的“width”、“height”、“depth”参数来创建立方体或者不规则四边形。
++ [name] 是四边形的原始几何类,它通常使用构造函数所提供的 “width”、“height”、“depth” 参数来创建立方体或者不规则四边形。 +
@@ -33,36 +35,37 @@const geometry = new THREE.BoxGeometry( 1, 1, 1 );
- const material = new THREE.MeshBasicMaterial( {color: 0x00ff00} );
- const cube = new THREE.Mesh( geometry, material );
+
+ const geometry = new THREE.BoxGeometry( 1, 1, 1 );
+ const material = new THREE.MeshBasicMaterial( {color: 0x00ff00} );
+ const cube = new THREE.Mesh( geometry, material );
scene.add( cube );
- 构造器
+ 构造函数(Constructor)
[name]([param:Float width], [param:Float height], [param:Float depth], [param:Integer widthSegments], [param:Integer heightSegments], [param:Integer depthSegments])
- width — X轴上面的宽度,默认值为1。
- height — Y轴上面的高度,默认值为1。
- depth — Z轴上面的深度,默认值为1。
- widthSegments — (可选)宽度的分段数,默认值是1。
- heightSegments — (可选)高度的分段数,默认值是1。
- depthSegments — (可选)深度的分段数,默认值是1。
+ width — X 轴上面的宽度,默认值为 `1`。
+ height — Y 轴上面的高度,默认值为 `1`。
+ depth — Z 轴上面的深度,默认值为 `1`。
+ widthSegments — (可选)宽度的分段数,默认值是 `1`。
+ heightSegments — (可选)高度的分段数,默认值是 `1`。
+ depthSegments — (可选)深度的分段数,默认值是 `1`。
- 属性
- 共有属性请参见其基类[page:BufferGeometry]。
+ 属性(Properties)
+ 共有属性请参见其基类 [page:BufferGeometry]。
[property:Object parameters]
一个包含着构造函数中每个参数的对象。在对象实例化之后,对该属性的任何修改都不会改变这个几何体。
- 方法(Methods)
- 共有方法请参见其基类[page:BufferGeometry]。
+ 方法(Methods)
+ 共有方法请参见其基类 [page:BufferGeometry]。
- 源代码
+ 源码(Source)
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
diff --git a/docs/api/zh/geometries/PlaneGeometry.html b/docs/api/zh/geometries/PlaneGeometry.html
index 1156a3f3ca57f3..cf89e6651c9c33 100644
--- a/docs/api/zh/geometries/PlaneGeometry.html
+++ b/docs/api/zh/geometries/PlaneGeometry.html
@@ -13,7 +13,10 @@
平面缓冲几何体([name])
一个用于生成平面几何体的类。
-
+
-
代码示例
- const geometry = new THREE.PlaneGeometry( 1, 1 );
- const material = new THREE.MeshBasicMaterial( {color: 0xffff00, side: THREE.DoubleSide} );
- const plane = new THREE.Mesh( geometry, material );
- scene.add( plane );
+
+const geometry = new THREE.PlaneGeometry( 1, 1 );
+const material = new THREE.MeshBasicMaterial( {color: 0xffff00, side: THREE.DoubleSide} );
+const plane = new THREE.Mesh( geometry, material );
+scene.add( plane );
- 构造器
+ 构造函数(Constructor)
- [name]([param:Float width], [param:Float height], [param:Integer widthSegments], [param:Integer heightSegments])
+
+ [name]([param:Float width], [param:Float height], [param:Integer widthSegments], [param:Integer heightSegments])
+
- width — 平面沿着X轴的宽度。默认值是1。
- height — 平面沿着Y轴的高度。默认值是1。
- widthSegments — (可选)平面的宽度分段数,默认值是1。
- heightSegments — (可选)平面的高度分段数,默认值是1。
+ width — 平面沿着 X 轴的宽度。默认值是 `1`。
+ height — 平面沿着 Y 轴的高度。默认值是 `1`。
+ widthSegments — (可选)平面的宽度分段数,默认值是 `1`。
+ heightSegments — (可选)平面的高度分段数,默认值是 `1`。
- 属性
- 共有属性请参见其基类[page:BufferGeometry]。
+ 属性(Properties)
+ 共有属性请参见其基类 [page:BufferGeometry]。
- .parameters
+ [property:Object parameters]
一个包含着构造函数中每个参数的对象。在对象实例化之后,对该属性的任何修改都不会改变这个几何体。
- 方法(Methods)
+ 方法(Methods)
共有方法请参见其基类[page:BufferGeometry]。
- 源代码
+ 源码(Source)
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
diff --git a/docs/api/zh/helpers/AxesHelper.html b/docs/api/zh/helpers/AxesHelper.html
index c1c1d6acb90060..ac788485e2eddc 100644
--- a/docs/api/zh/helpers/AxesHelper.html
+++ b/docs/api/zh/helpers/AxesHelper.html
@@ -29,18 +29,16 @@
例子
[example:webgl_loader_nrrd WebGL / loader / nrrd]
- 构造函数
-
-
+ 构造函数(Constructor)
[name]( [param:Number size] )
- [page:Number size] -- (可选的) 表示代表轴的线段长度. 默认为 *1*.
+ [page:Number size] -- (可选的) 表示代表轴的线段长度. 默认为 `1`.
- 属性
+ 属性(Properties)
请到基类 [page:LineSegments] 页面查看公共属性.
- 方法
+ 方法(Methods)
请到基类 [page:LineSegments] 页面查看公共方法.
@@ -55,8 +53,7 @@ [method:undefined dispose]()
释放此实例分配的GPU相关资源。每当应用程序中不再使用此实例时,请调用此方法。
- 源码
-
+ 源码(Source)
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
diff --git a/docs/manual/zh/introduction/WebGL-compatibility-check.html b/docs/manual/zh/introduction/WebGL-compatibility-check.html
index 9fafed7a07d30e..875a587a63a55d 100644
--- a/docs/manual/zh/introduction/WebGL-compatibility-check.html
+++ b/docs/manual/zh/introduction/WebGL-compatibility-check.html
@@ -9,23 +9,28 @@
WebGL兼容性检查([name])
- 虽然这个问题现在已经变得越来不明显,但不可否定的是,某些设备以及浏览器直到现在仍然不支持WebGL。
以下的方法可以帮助你检测当前用户所使用的环境是否支持WebGL,如果不支持,将会向用户提示一条信息。
+ 虽然这个问题现在已经变得越来不明显,但不可否定的是,某些设备以及浏览器直到现在仍然不支持WebGL。
+
以下的方法可以帮助你检测当前用户所使用的环境是否支持WebGL,如果不支持,将会向用户提示一条信息。
-
请将[link:https://github.com/mrdoob/three.js/blob/master/examples/jsm/capabilities/WebGL.js]引入到你的文件,并在尝试开始渲染之前先运行该文件。
-
-
-
-if (WebGL.isWebGLAvailable()) {
- // Initiate function or other initializations here
- animate();
-} else {
- const warning = WebGL.getWebGLErrorMessage();
- document.getElementById('container').appendChild(warning);
-}
-
-
+ 导入 WebGL 兼容检测模块,并在尝试渲染任何内容之前运行以下程序。
+
+
+ import WebGL from 'three/addons/capabilities/WebGL.js';
+
+ if ( WebGL.isWebGLAvailable() ) {
+
+ // Initiate function or other initializations here
+ animate();
+
+ } else {
+
+ const warning = WebGL.getWebGLErrorMessage();
+ document.getElementById( 'container' ).appendChild( warning );
+
+ }
+