Ver Fonte

continue translate

gogoend há 6 anos atrás
pai
commit
4d9cd64b7a
3 ficheiros alterados com 61 adições e 67 exclusões
  1. 2 3
      docs/api/zh/math/Quaternion.html
  2. 29 31
      docs/api/zh/math/Ray.html
  3. 30 33
      docs/api/zh/math/Sphere.html

+ 2 - 3
docs/api/zh/math/Quaternion.html

@@ -12,8 +12,8 @@
 
 		<p class="desc">
 			这个类是对[link:http://en.wikipedia.org/wiki/Quaternion quaternion](四元数)的实现。
-			它用于排除万向锁([link:http://en.wikipedia.org/wiki/Gimbal_lock gimbal lock])问题,对物体进行旋转([link:https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotation rotating things]),
-			同时它还具有其它优点。
+			它用于排除万向锁([link:http://en.wikipedia.org/wiki/Gimbal_lock gimbal lock])问题,对物体进行旋转([link:https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotation rotating things]),
+			此外它还具有其它优点。
 		</p>
 
 
@@ -69,7 +69,6 @@
 
 		<h3>[method:Quaternion conjugate]()</h3>
 		<p>
-			返回该四元数的旋转共轭。四元数
 		Returns the rotational conjugate of this quaternion. The conjugate of a quaternion
 		represents the same rotation in the opposite direction about the rotational axis.
 		</p>

+ 29 - 31
docs/api/zh/math/Ray.html

@@ -8,62 +8,61 @@
 		<link type="text/css" rel="stylesheet" href="page.css" />
 	</head>
 	<body>
-		<h1>[name]</h1>
+		<h1>射线([name]</h1>
 
 		<p class="desc">
-			A ray that emits from an origin in a certain direction. This is used by the
-			[page:Raycaster] to assist with [link:https://en.wikipedia.org/wiki/Ray_casting raycasting].
-			Raycasting is used for mouse picking (working out what objects in the 3D space the mouse is over) amongst
-			other things.
+			射线由一个原点向一个确定的方向发射。它被[page:Raycaster](光线投射)所使用,
+			以用于辅助[link:https://en.wikipedia.org/wiki/Ray_casting raycasting]。
+			光线投射用于在各个物体之间进行拾取(当鼠标经过三维空间中的物体/对象时进行拾取)。
 		</p>
 
 
-		<h2>Constructor</h2>
+		<h2>构造函数</h2>
 
 
 		<h3>[name]( [param:Vector3 origin], [param:Vector3 direction] )</h3>
 		<p>
-		[page:Vector3 origin] - (optional) the origin of the [page:Ray]. Default is a [page:Vector3] at (0, 0, 0).<br />
-		[page:Vector3 direction] - [page:Vector3] The direction of the [page:Ray]. This must be normalized
-		 (with [page:Vector3.normalize]) for the methods to operate properly.  Default is a [page:Vector3] at (0, 0, 0).<br /><br />
+		[page:Vector3 origin] - (可选)[page:Ray](射线)的原点,默认值是一个位于(0, 0, 0)的[page:Vector3]。<br />
+		[page:Vector3 direction] - [page:Vector3] [page:Ray](射线)的方向。该向量必须被标准化(使用[page:Vector3.normalize]函数),这样才能使方法正常运行。
+		默认值是一个位于(0, 0, 0)的[page:Vector3]。<br /><br />
 
-		Creates a new [name].
+		创建一个新的[name]。
 		</p>
 
-		<h2>Properties</h2>
+		<h2>属性</h2>
 
 		<h3>[property:Vector3 origin]</h3>
-		<p>The origin of the [page:Ray]. Default is a [page:Vector3] at (0, 0, 0).</p>
+		<p>[page:Ray](射线)的原点,默认值是一个位于(0, 0, 0)的[page:Vector3]。</p>
 
 		<h3>[property:Vector3 direction]</h3>
 		<p>
-		The direction of the [page:Ray]. This must be normalized (with [page:Vector3.normalize])
-		for the methods to operate properly. Default is a [page:Vector3] at (0, 0, 0).
+		[page:Ray](射线)的方向。该向量必须被标准化(使用[page:Vector3.normalize]函数),这样才能使方法正常运行。
+		默认值是一个位于(0, 0, 0)的[page:Vector3]。
 		</p>
 
 
 
 
-		<h2>Methods</h2>
+		<h2>方法</h2>
 
 		<h3>[method:Ray applyMatrix4]( [param:Matrix4 matrix4] )</h3>
 		<p>
-		[page:Matrix4 matrix4] - the [page:Matrix4] to apply to this [page:Ray].<br /><br />
+		[page:Matrix4 matrix4] - 将被用于这个[page:Ray]的[page:Matrix4]。<br /><br />
 
-		Transform this [page:Ray] by the [page:Matrix4].
+		使用传入的[page:Matrix4]来变换这个[page:Ray]。
 		</p>
 
 		<h3>[method:Vector3 at]( [param:Float t], [param:Vector3 target] ) </h3>
 		<p>
-		[page:Float t] - the distance along the [page:Ray] to retrieve a position for.<br />
-		[page:Vector3 target] — the result will be copied into this Vector3.<br /><br />
+		[page:Float t] - 使用这一传入的距离,在[page:Ray]上确定一个位置。<br />
+		[page:Vector3 target] — 结果将复制到这一Vector3中。<br /><br />
 
-		Get a [page:Vector3] that is a given distance along this [page:Ray].
+		获得这一[page:Ray]上给定距离处的[page:Vector3]。
 		</p>
 
 		<h3>[method:Ray clone]()</h3>
 		<p>
-			Creates a new Ray with identical [page:.origin origin] and [page:.direction direction]  to this one.
+			创建一个新的和这个Ray具有相同[page:.origin origin]和[page:.direction direction]的Ray。
 		</p>
 
 		<h3>[method:Vector3 closestPointToPoint]( [param:Vector3 point], [param:Vector3 target] )</h3>
@@ -71,20 +70,19 @@
 		[page:Vector3 point] - the point to get the closest approach to. <br />
 		[page:Vector3 target] — the result will be copied into this Vector3.<br /><br />
 
-		Get the point along this [page:Ray] that is closest to the [page:Vector3] provided.
+		沿着[page:Ray],获得与所传入[page:Vector3]最接近的点。
 		</p>
 
 		<h3>[method:Ray copy]( [param:Ray ray] )</h3>
 		<p>
-			Copies the [page:.origin origin] and [page:.direction direction] properties
-			of [page:Ray ray] into this ray.
+			复制所传入Ray的[page:.origin origin]和[page:.direction direction]属性到这个Ray上。
 		</p>
 
 		<h3>[method:Float distanceSqToPoint]( [param:Vector3 point] )</h3>
 		<p>
 		[page:Vector3 point] - the [page:Vector3] to compute a distance to.<br /><br />
 
-		Get the squared distance of the closest approach between the [page:Ray] and the [page:Vector3].
+		获得[page:Ray]与传入的[page:Vector3]之间最近的平方距离。
 		</p>
 
 		<h3>[method:Float distanceSqToSegment]( [param:Vector3 v0], [param:Vector3 v1], [param:Vector3 optionalPointOnRay], [param:Vector3 optionalPointOnSegment] )</h3>
@@ -116,10 +114,9 @@
 
 		<h3>[method:Boolean equals]( [param:Ray ray] )</h3>
 		<p>
-		[page:Ray ray] - the [page:Ray] to compare to.<br /><br />
+		[page:Ray ray] - 用于比较的[page:Ray]。<br /><br />
 
-		Returns true if this and the other [page:Ray ray] have equal [page:.offset offset]
-		 and [page:.direction direction].
+		如果所传入的[page:Ray ray]具有和当前Ray相同的[page:.offset offset]和[page:.direction direction]则返回true。
 		</p>
 
 		<h3>[method:Vector3 intersectBox]( [param:Box3 box], [param:Vector3 target] )</h3>
@@ -127,6 +124,7 @@
 		[page:Box3 box] - the [page:Box3] to intersect with.<br />
 		[page:Vector3 target] — the result will be copied into this Vector3.<br /><br />
 
+		相交
 		Intersect this [page:Ray] with a [page:Box3], returning the intersection point or
 		*null* if there is no intersection.
 		</p>
@@ -182,9 +180,9 @@
 
 		<h3>[method:Ray lookAt]( [param:Vector3 v] )</h3>
 		<p>
-		[page:Vector3 v] - The [page:Vector3] to look at.<br /><br />
+		[page:Vector3 v] - 将要“直视”的[page:Vector3]<br /><br />
 
-		Adjusts the direction of the ray to point at the vector in world coordinates.
+		调整光线的方向到世界坐标中该向量所指代的点。
 		</p>
 
 		<h3>[method:Ray recast]( [param:Float t] )</h3>
@@ -207,7 +205,7 @@
 
 
 
-		<h2>Source</h2>
+		<h2>源代码</h2>
 
 		[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
 	</body>

+ 30 - 33
docs/api/zh/math/Sphere.html

@@ -27,100 +27,97 @@
 
 
 		<h3>[property:Vector3 center]</h3>
-		<p>A [page:Vector3] defining the center of the sphere. Default is (0, 0, 0).</p>
+		<p>A [page:Vector3]定义了球心的位置,默认值位于(0, 0, 0)。</p>
 
 		<h3>[property:Float radius]</h3>
-		<p>The radius of the sphere. Default is 0.</p>
+		<p>球的半径,默认值为0。</p>
 
-		<h2>Methods</h2>
+		<h2>方法</h2>
 
 		<h3>[method:Sphere applyMatrix4]( [param:Matrix4 matrix] )</h3>
 		<p>
-			[page:Matrix4 matrix] - the [Page:Matrix4] to apply <br /><br />
+			[page:Matrix4 matrix] - 将被应用的[Page:Matrix4]矩阵。<br /><br />
 
-			Transforms this sphere with the provided [page:Matrix4].
+			使用所传入的[page:Matrix4]矩阵来对球进行变换。
 		</p>
 
 		<h3>[method:Vector3 clampPoint]( [param:Vector3 point], [param:Vector3 target] )</h3>
 		<p>
-		[page:Vector3 point] - [page:Vector3] The point to clamp.<br />
-		[page:Vector3 target] — the result will be copied into this Vector3.<br /><br />
+		[page:Vector3 point] - [page:Vector3] 将要夹取的点。<br />
+		[page:Vector3 target] — 结果将被复制到这个Vector3中。<br /><br />
 
-		Clamps a point within the sphere. If the point is is outside the sphere, it will clamp it to the
-		closets point on the edge of the sphere. Points already inside the sphere will not be affected.
+		从球中夹取一个点。若这一点位于球外,则将会夹取到该点球边缘最近的点。已位于球中的点将不会受到影响。
 		</p>
 
 		<h3>[method:Sphere clone]()</h3>
-		<p>Returns a new sphere with the same [page:.center center] and [page:.radius radius] as this one.</p>
+		<p>返回一个新的球,新的球与这个球具有相同的[page:.center center]和[page:.radius radius]。</p>
 
 		<h3>[method:Boolean containsPoint]( [param:Vector3 point] )</h3>
 		<p>
 		[page:Vector3 point] - the [page:Vector3] to be checked<br /><br />
 
-		Checks to see if the sphere contains the provided [page:Vector3 point] inclusive of the
-		surface of the sphere.
+		检查球体中是否包含所传入的[page:Vector3 point]点,包括球的表面。
 		</p>
 
 		<h3>[method:Sphere copy]( [param:Sphere sphere] )</h3>
 		<p>
-		Copies the values of the passed sphere's [page:.center center] and [page:.radius radius]
-		properties to this sphere.
+		复制所传入的球的[page:.center center]和[page:.radius radius]到这个球上。
 		</p>
 
 		<h3>[method:Float distanceToPoint]( [param:Vector3 point] )</h3>
 		<p>
-		Returns the closest distance from the boundary of the sphere to the [page:Vector3 point]. If the sphere contains the point,
-		the distance will be negative.
+		返回球的边界到所传入的[page:Vector3 point]点的最近距离。
+		若这个点,则距离将为负值。
 		</p>
 
 		<h3>[method:Boolean empty]()</h3>
-		<p>Checks to see if the sphere is empty (the radius set to 0).</p>
+		<p>检查球是否为空(其半径设为了0).</p>
 
 		<h3>[method:Boolean equals]( [param:Sphere sphere] )</h3>
 		<p>
-		Checks to see if the two spheres' centers and radii are equal.
+		检查这两个球的球心与半径是否相等。
 		</p>
 
 		<h3>[method:Box3 getBoundingBox]( [param:Box3 target] )</h3>
 		<p>
-		[page:Box3 target] — the result will be copied into this Box3.<br /><br />
+		[page:Box3 target] — 结果将被复制到这个Box3中。<br /><br />
 
-		Returns a[link:https://en.wikipedia.org/wiki/Minimum_bounding_box Minimum Bounding Box] for the sphere.
+		返回这个球的[link:https://en.wikipedia.org/wiki/Minimum_bounding_box Minimum Bounding Box](最小包围盒)。
 		</p>
 
 		<h3>[method:Boolean intersectsBox]( [param:Box3 box] )</h3>
 		<p>
-		[page:Box3 box] - [page:Box3] to check for intersection against.<br /><br />
+		[page:Box3 box] - 将被用于测试是否与这个球有交集的[page:Box3]。<br /><br />
 
-		Determines whether or not this sphere intersects a given [page:Box3 box].
+		检测这个球与所传入的[page:Box3 box]是否有交集。
 		</p>
 
 		<h3>[method:Boolean intersectsPlane]( [param:Plane plane] )</h3>
 		<p>
-		[page:Plane plane] - Plane to check for intersection against.<br /><br />
+		[page:Plane plane] - 将被用于测试是否与这个球有交集的Plane。<br /><br />
 
-		Determines whether or not this sphere intersects a given [page:Plane plane].
+		检测这个球与所传入的[page:Plane plane]是否有交集。
 		</p>
 
 		<h3>[method:Boolean intersectsSphere]( [param:Sphere sphere] )</h3>
 		<p>
-		[page:Sphere sphere] - Sphere to check for intersection against.<br /><br />
+		[page:Sphere sphere] - 将被用于测试是否与这个球有交集的Sphere。<br /><br />
 
-		Checks to see if two spheres intersect.
+		检测两球之间是否有交集。
 		</p>
 
 		<h3>[method:Sphere set]( [param:Vector3 center], [param:Float radius] )</h3>
 		<p>
-			[page:Vector3 center] - center of the sphere.<br />
-			[page:Float radius] - radius of the sphere.<br /><br />
+			[page:Vector3 center] - 球心位置。<br />
+			[page:Float radius] - 球的半径。<br /><br />
 
-		Sets the [page:.center center] and [page:.radius radius] properties of this sphere.
+		设置球的[page:.center center]和[page:.radius radius]属性。
 		</p>
 
 		<h3>[method:Sphere setFromPoints]( [param:Array points], [param:Vector3 optionalCenter] )</h3>
 		<p>
-		[page:Array points] - an [page:Array] of [page:Vector3] positions.<br />
-		[page:Vector3 optionalCenter] - Optional [page:Vector3] position for the sphere's center.<br /><br />
+		[page:Array points] - 一个包含有[page:Vector3]位置的[page:Array]。<br />
+		[page:Vector3 optionalCenter] - 可选, [page:Vector3] position for the sphere's center.<br /><br />
 
 		Computes the minimum bounding sphere for an array of [page:Array points]. If  [page:Vector3 optionalCenter]is given,
 		it is used as the sphere's center. Otherwise, the center of the axis-aligned bounding box encompassing
@@ -129,10 +126,10 @@
 
 		<h3>[method:Sphere translate]( [param:Vector3 offset] )</h3>
 		<p>
-		Translate the sphere's center by the provided offset [page:Vector3].
+		使用所给定[page:Vector3] offset(偏移量)平移球心。
 		</p>
 
-		<h2>Source</h2>
+		<h2>源代码</h2>
 
 		[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
 	</body>