jPCT-AE - a 3d engine for Android > Support
code package
(1/1)
Thomas.:
How can I do package from my code? I mean something like jPCT, that contains also shaders. I have no idea how can I load shaders and textures from package... And are there any rules as to how it should look like?
EgonOlsen:
I'm just adding the shaders to the jar (with no package, but that should work as well) and get the stream to them via
--- Code: ---this.getClass().getResourceAsStream(name)
--- End code ---
However, some tools for deploying the app via USB seem not to support this way. They simply drop all non-class files from the jar when creating the APK, because the behaviour of what is supposed to happen to these files isn't very well defined for Android/Dalvik.
Thomas.:
it works, thanks ;)
Navigation
[0] Message Index
Go to full version