diff --git a/docs/api/zh/cameras/OrthographicCamera.html b/docs/api/zh/cameras/OrthographicCamera.html index 23a78ecea91045950b17795689dea9ef2c98e47e..49a177dad3ef6984b6181e726158b04a309f0971 100644 --- a/docs/api/zh/cameras/OrthographicCamera.html +++ b/docs/api/zh/cameras/OrthographicCamera.html @@ -13,16 +13,17 @@

[name]

- Camera that uses [link:https://en.wikipedia.org/wiki/Orthographic_projection orthographic projection].

+ 这一摄像机使用[link:https://en.wikipedia.org/wiki/Orthographic_projection orthographic projection](正交投影)来进行投影。

- In this projection mode, an object's size in the rendered image stays constant - regardless of its distance from the camera.

+ 在这种投影模式下,无论物体距离相机距离远或者近,在最终渲染的图片中物体的大小都保持不变。 +

- This can be useful for rendering 2D scenes and UI elements, amongst other things. + + 这对于渲染2D场景或者UI元素是非常有用的。

-

Example

+

示例

[example:canvas_camera_orthographic camera / orthographic ]

[example:webgl_camera camera ]

@@ -40,104 +41,104 @@ scene.add( camera ); -

Constructor

+

构造器

[name]( [param:Number left], [param:Number right], [param:Number top], [param:Number bottom], [param:Number near], [param:Number far] )

- left — Camera frustum left plane.
- right — Camera frustum right plane.
- top — Camera frustum top plane.
- bottom — Camera frustum bottom plane.
- near — Camera frustum near plane.
- far — Camera frustum far plane.

- - Together these define the camera's [link:https://en.wikipedia.org/wiki/Viewing_frustum viewing frustum]. + left — 摄像机视锥体左侧面。
+ right — 摄像机视锥体右侧面。
+ top — 摄像机视锥体上侧面。
+ bottom — 摄像机视锥体下侧面。
+ near — 摄像机视锥体近端面。
+ far — 摄像机视锥体远端面。

+ + 这些参数一起定义了摄像机的[link:https://en.wikipedia.org/wiki/Viewing_frustum viewing frustum](视锥体)。

-

Properties

+

属性

- See the base [page:Camera] class for common properties.
- Note that after making changes to most of these properties you will have to call - [page:OrthographicCamera.updateProjectionMatrix .updateProjectionMatrix] for the changes to take effect. + 请参阅其基类[page:Camera]来查看其共有属性。 +
+ 请注意,在大多数属性发生改变之后,你将需要调用[page:OrthographicCamera.updateProjectionMatrix .updateProjectionMatrix]来使得这些改变生效。

[property:Float bottom]

-

Camera frustum bottom plane.

+

摄像机视锥体下侧面。

[property:Float far]

- Camera frustum far plane. Default is *2000*.

- - The valid range is between the current value of the [page:.near near] plane and infinity. + 摄像机视锥体远端面,其默认值为*2000*。

+ 其值的有效范围介于[page:.near near](摄像机视锥体近端面)和无穷大之间。

[property:Boolean isOrthographicCamera]

- Used to test whether this or derived classes are OrthographicCameras. Default is *true*.

- - This should not be changed as it is used internally by the renderer for optimisation. + 用于测试这个类或者派生类是否为OrthographicCameras,默认为*true*。

+ 你不应当对这个属性进行改变,因为它在内部由渲染器使用,以用于优化。

[property:Float left]

-

Camera frustum left plane.

+

摄像机视锥体左侧面。

[property:Float near]

- Camera frustum near plane. Default is *0.1*.

+ 摄像机视锥体近端面。其默认值为*0.1*.

+ + 其值的有效范围介于0和[page:.far far](摄像机视锥体远端面)之间。 +
+ 请注意,和[page:PerspectiveCamera]不同,*0*对于OrthographicCamera的近端面来说是一个有效值。 - The valid range is between 0 and the current value of the [page:.far far] plane. - Note that, unlike for the [page:PerspectiveCamera], *0* is a valid value for an - OrthographicCamera's near plane.

[property:Float right]

-

Camera frustum right plane.

+

摄像机视锥体右侧面。

[property:Float top]

-

Camera frustum top plane.

+

摄像机视锥体上侧面。

[property:Object view]

-

Set by [page:OrthographicCamera.setViewOffset setViewOffset]. Default is *null*.

+

这个值是由[page:OrthographicCamera.setViewOffset setViewOffset]来设置的,其默认值为*null*。

[property:number zoom]

-

Gets or sets the zoom factor of the camera. Default is *1*.

+

+ 获取或者设置摄像机的缩放倍数,其默认值为*1*。

-

Methods

-

See the base [page:Camera] class for common methods.

+

方法

+

请参阅其基类[page:Camera]来查看其共有方法。

[method:null setViewOffset]( [param:Float fullWidth], [param:Float fullHeight], [param:Float x], [param:Float y], [param:Float width], [param:Float height] )

- fullWidth — full width of multiview setup
- fullHeight — full height of multiview setup
- x — horizontal offset of subcamera
- y — vertical offset of subcamera
- width — width of subcamera
- height — height of subcamera

- - Sets an offset in a larger [link:https://en.wikipedia.org/wiki/Viewing_frustum viewing frustum]. - This is useful for multi-window or multi-monitor/multi-machine setups. - For an example on how to use it see [page:PerspectiveCamera.setViewOffset PerspectiveCamera]. + fullWidth — 多视图的全宽设置
+ fullHeight — 多视图的全高设置
+ x — 副摄像机的水平偏移
+ y — 副摄像机的垂直偏移
+ width — 副摄像机的宽度
+ height — 副摄像机的高度

+ + 在较大的[link:https://en.wikipedia.org/wiki/Viewing_frustum viewing frustum](视锥体)中设置偏移量,对于多窗口或者多显示器的设置是很有用的。 + 对于如何使用它,请查看[page:PerspectiveCamera.setViewOffset PerspectiveCamera]中的示例。 +

[method:null clearViewOffset]()

- Removes any offset set by the .setViewOffset method. + 清除任何由.setViewOffset设置的偏移量。

[method:null updateProjectionMatrix]()

- Updates the camera projection matrix. Must be called after any change of parameters. + 更新摄像机投影矩阵。在任何参数被改变以后必须被调用。

[method:JSON toJSON]()

- Return the camera's data in JSON format. + 使用JSON格式来返回摄像机数据。

-

Source

+

源代码

[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]