浏览代码

improve SkinnedMesh.boneTransform docs (#23422)

makc 3 年之前
父节点
当前提交
d2fae357d7
共有 1 个文件被更改,包括 7 次插入1 次删除
  1. 7 1
      docs/api/en/objects/SkinnedMesh.html

+ 7 - 1
docs/api/en/objects/SkinnedMesh.html

@@ -148,9 +148,15 @@
 		This method sets the skinned mesh in the rest pose (resets the pose).
 		This method sets the skinned mesh in the rest pose (resets the pose).
 		</p>
 		</p>
 
 
-		<h3>[method:Vector3 boneTransform]( [index:Integer], [target:Vector3] )</h3>
+		<h3>[method:Vector3 boneTransform]( [param:Integer index], [param:Vector3 target] )</h3>
 		<p>
 		<p>
 		Calculates the position of the vertex at the given index relative to the current bone transformations.
 		Calculates the position of the vertex at the given index relative to the current bone transformations.
+		Target vector must be initialized with the vetrex coordinates prior to the transformation:
+		<code>
+const target = new THREE.Vector3();
+target.fromBufferAttribute( mesh.geometry.attributes.position, index );
+mesh.boneTransform( index, target );
+		</code>
 		</p>
 		</p>
 
 
 		<h2>Source</h2>
 		<h2>Source</h2>