jme3-plugins fails to load UnicodeTest
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 42/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- java
- Domain
- computer-graphics
Research direction
Start with GltfLoader.loadFromStream(), then inspect getBytes(), readData(), and readBuffer() at the stack-trace locations. Reproduce the UnicodeTest failure with TestGltfLoading on Windows and compare it with DesktopAssetManager loading the same .bin asset. Done means the UnicodeTest glTF and its binary asset load successfully on Windows without path corruption.
Written by the indexing model from the issue text.
Description
I noticed a defect in GltfLoader while developing the MonkeyWrench library.
The test data is UnicodeTest from Khronos's glTF sample models.
The test passed on my desktop computer running Mint Linux.
On my laptop computer running Microsoft Windows 11, it failed with the following diagnostic:
com.jme3.asset.AssetLoadException: An error occurred loading Unicode??Test/glTF/Unicode??Test.gltf
I reproduced this behavior using the TestGltfLoading app with the following modifications:
assetManager.registerLocator("..\\..\\ext\\glTF-Sample-Models\\2.0", FileLocator.class);
//...
loadModel("Unicode\u2764\u267bTest/glTF/Unicode\u2764\u267bTest.gltf", new Vector3f(0, 1, 0), 1);
I then added e.printStackTrace(); in GltfLoader.loadFromStream() and got the following stack trace:
Caused by: com.jme3.asset.AssetNotFoundException: Unicode??Test/glTF/Unicode�?�♻Binary.bin
at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:387)
at com.jme3.scene.plugins.gltf.GltfLoader.getBytes(GltfLoader.java:607)
at com.jme3.scene.plugins.gltf.GltfLoader.readData(GltfLoader.java:584)
at com.jme3.scene.plugins.gltf.GltfLoader.readBuffer(GltfLoader.java:557)
at com.jme3.scene.plugins.gltf.GltfLoader$VertexBufferPopulator.populate(GltfLoader.java:1341)
at com.jme3.scene.plugins.gltf.GltfLoader$VertexBufferPopulator.populate(GltfLoader.java:1309)
at com.jme3.scene.plugins.gltf.GltfLoader.readAccessorData(GltfLoader.java:537)
at com.jme3.scene.plugins.gltf.GltfLoader.readMeshPrimitives(GltfLoader.java:384)
at com.jme3.scene.plugins.gltf.GltfLoader.readNode(GltfLoader.java:253)
at com.jme3.scene.plugins.gltf.GltfLoader.readChild(GltfLoader.java:302)
at com.jme3.scene.plugins.gltf.GltfLoader.readScenes(GltfLoader.java:219)
at com.jme3.scene.plugins.gltf.GltfLoader.loadFromStream(GltfLoader.java:155)
The issue isn't intrinsic to jme3-core since MonkeyWrench is able to open the same .bin asset using DesktopAssetManager on Windows 11.
I'm unsure where the root cause lies. Perhaps GltfLoader.getBytes() is decoding a URI that wasn't properly encoded to begin with?
- Dominant language
- Java
- Stars
- 4.3k
- Forks
- 1.2k
- Avg merge
- 4d 7h
- Merged PRs (30d)
- 14
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from jMonkeyEngine/jmonkeyengine
-
Documentation
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
jMonkeyEngine/jmonkeyengine#2928 · 4 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
jMonkeyEngine/jmonkeyengine#2919 · 1 comment ·
-
defect
Difficulty 1/5 Under an hour Newbie friendliness 88/100
jMonkeyEngine/jmonkeyengine#2717 ·
-
Documentation
Difficulty 3/5 1-2 days Newbie friendliness 55/100
jMonkeyEngine/jmonkeyengine#2931 · 1 comment ·
-
Documentation
Difficulty 3/5 1-2 days Newbie friendliness 57/100
jMonkeyEngine/jmonkeyengine#2930 · 3 comments ·
All issues in jMonkeyEngine/jmonkeyengine
Similar issues
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
inu-appcenter/memorIN-backend#288 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
-
frontend maui-pilot pilot-ask question
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
area/plugin
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
kestra-io/plugin-kestra#190 ·