Summary
A Java application uses jMonkey for rendering purposes. This application is loading a custom icon when in view mode. The icon in use is 32x32 and is loaded like this, as it is a cursor:
JmeCursor cursor = (JmeCursor) Services.getAssetManager().loadAsset( "/path/someIcon.ico" );
Where Services
is just some irrelevant class to retrieve the jMonkey AssetManager
.
I read about typical .ico
sizes and one of them appears to be 96x96. However when attempting to load a 96x96 .ico
file as an asset using the code snippet above, I ran into jMonkey not being able to load the asset, even though according to debugger output the resource was indeed found.
When checking with the debugger, I can follow the loading process into the DesktopAssetManager#loadAsset
until it dives deeper into classes I cannot see and then a Throwable
without useful stack trace, message or other info shows up. When I switch to any other 32x32 .ico
file all works fine again.
Question
Right to the chase: