UE4 坐标系坐标轴旋转轴

来源:互联网 发布:windows启动管理器 编辑:程序博客网 时间:2024/04/30 12:05

1.UE4X轴是前方。

2. UE4unity都是左手坐标系。

判断方法:四指由X卷向Y,看大拇指的朝向和Z轴朝向,由此判断使用的是左手坐标系还是右手坐标系。

3. UE4中,RotationX是翻滚角Roll,围绕X轴旋转。Y是俯仰角pitch,围绕Y轴旋转。Z当然是偏航角yaw了,围绕Z轴。

  (翻滚)Roll,(俯仰)Pitch,(偏航)Yaw如下(顾名思义很好记):

 

 

4. UE4里,蓝图中的rotation的三个依次为roll,pitch,yawC++FRotator里是pitch,yaw,roll。(很蛋疼!!!)


   

  

 

   


c++中:

 

总之不管怎么样,根据三个角的定义来就行。

 

5.

Get component relative rotation -> get forward vector, that will return the local forward vector OR if you want the world forward vector...Get component world rotation -> get forward vector. The rotation return will be based on the mesh's root x axis no matter which way it is facing.  

get forward vector  //获得物体的自身的前方

Get component world rotation -> get forward vector.  //获得根节点X轴的前方

原创粉丝点击