I'm testing current "master" branch with FBX assets downloaded from CGtrader, Mixamo, and Sketchfab.
Attempting to import a certain FBX file causes the following crash:
Jan 28, 2023 11:58:05 PM com.jme3.app.LegacyApplication handleError
SEVERE: Uncaught exception thrown in Thread[jME3 Main,5,main]
java.lang.UnsupportedOperationException: Bind poses don't match
at com.jme3.scene.plugins.fbx.node.FbxNode.setWorldBindPose(FbxNode.java:163)
at com.jme3.scene.plugins.fbx.FbxLoader.applyBindPoses(FbxLoader.java:282)
at com.jme3.scene.plugins.fbx.FbxLoader.load(FbxLoader.java:113)
at com.jme3.asset.DesktopAssetManager.loadLocatedAsset(DesktopAssetManager.java:272)
at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:388)
at com.jme3.asset.DesktopAssetManager.loadModel(DesktopAssetManager.java:439)
at com.jme3.asset.DesktopAssetManager.loadModel(DesktopAssetManager.java:444)
at jme3test.helloworld.HelloJME3.loadModel(HelloJME3.java:88)
at jme3test.helloworld.HelloJME3.simpleInitApp(HelloJME3.java:67)
at com.jme3.app.SimpleApplication.initialize(SimpleApplication.java:240)
at com.jme3.system.lwjgl.LwjglAbstractDisplay.initInThread(LwjglAbstractDisplay.java:139)
at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:221)
at java.base/java.lang.Thread.run(Thread.java:833)
The failing code tests for exact equality between two bind-pose matrices:
|
public void setWorldBindPose(Matrix4f worldBindPose) { |
|
if (cachedWorldBindPose != null) { |
|
if (!cachedWorldBindPose.equals(worldBindPose)) { |
|
throw new UnsupportedOperationException("Bind poses don't match"); |
|
} |
|
} |
For the file I'm studying, the actual differences between the matrices are less than 10^-19, so I assume they're caused by roundoff error somewhere upstream. There ought to be some tolerance in the comparison.
I'm testing current "master" branch with FBX assets downloaded from CGtrader, Mixamo, and Sketchfab.
Attempting to import a certain FBX file causes the following crash:
The failing code tests for exact equality between two bind-pose matrices:
jmonkeyengine/jme3-plugins/src/fbx/java/com/jme3/scene/plugins/fbx/node/FbxNode.java
Lines 160 to 165 in 7a5d085
For the file I'm studying, the actual differences between the matrices are less than 10^-19, so I assume they're caused by roundoff error somewhere upstream. There ought to be some tolerance in the comparison.