فهرست منبع

Bugfix: Fixing scaled mesh rendering when animation is enabled but animation clip is not assigned

BearishSun 8 سال پیش
والد
کامیت
3307100542
1فایلهای تغییر یافته به همراه4 افزوده شده و 0 حذف شده
  1. 4 0
      Source/BansheeFBXImporter/BsFBXImporter.cpp

+ 4 - 0
Source/BansheeFBXImporter/BsFBXImporter.cpp

@@ -1581,6 +1581,10 @@ namespace bs
 
 			FbxAMatrix invLinkTransform = linkTransform.Inverse();
 			bone.localTfrm = bone.node->localTransform;
+			bone.localTfrm[0][3] *= scene.scaleFactor;
+			bone.localTfrm[1][3] *= scene.scaleFactor;
+			bone.localTfrm[2][3] *= scene.scaleFactor;
+
 			bone.bindPose = FBXToNativeType(invLinkTransform);
 
 			// Apply global scale to bind pose (we only apply the scale to translation portion because we scale the