Assimp对FBX文件中geometric transformations的处理

关于geometric transformations可以参考http://download.autodesk.com/us/fbx/20112/FBX_SDK_HELP/index.html?url=WS1a9193826455f5ff1f92379812724681e696651.htm,topicNumber=d0e7429

需要注意的是geometric transformations仅参与当前节点的变换:即:WorldTransform = ParentWorldTransform * T * R * S * OT * OR * OS中,ParentWorldTransform 不会包含parent节点的OT/OR/OS。

对于结构:A<-B<-C,即A为B的父节点,B为C的父节点,如果B节点有一项GeometricRotation,那么该结构利用assimp加载后会变成:

A <- BT <- BR <- BS <- BGeometricRotation <- B(local transform为单位阵) <- BGeometricRotationInverse <- C.

其中红色节点为assimp添加的辅助节点,这样做既将GeometricRotation的计算统一到树结构中,又保证了GeometricRotation不被下面的节点继承。

posted @ 2019-08-20 20:38  redips  阅读(516)  评论(0编辑  收藏  举报