浏览代码

Update urdf_appendix.md

/vidur-adding-primitive-size-documentation
vidurvij-Unity 3 年前
当前提交
d2a45af1
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 4
      tutorials/urdf_importer/urdf_appendix.md

4
tutorials/urdf_importer/urdf_appendix.md


<collision>
```
The size of the primitive will be set in Unity by changing the scale of gameObject containing UrdfCollision script.
The URDF Importer will set the size of the primitive using the "scale" parameter of the GameObject that contains the UrdfCollsion script.
This is done, as opposed to using the size API of the primitive collider, to have consistency across different mesh types. The sizing API is only available for primitive mesh colliders and not for complex collider meshes and visual meshes. Thats why we use the parent's scaling to change the shape of the primitive mesh. This scale is exported as the primitive size during URDF export.
The reason we set the size via the "scale" of the parent GameObject as opposed to the "size" of the primitive collider is to have consistency across different mesh types; the size API is only available for primitive mesh colliders and not for complex collider meshes and visual meshes, whose size must be changed using their parent GameObject's "scale" parameter. The "scale" parameter of the gameObject is also used set the values of primitive "size" in the URDF when performing an URDF export.
正在加载...
取消
保存