It’s exactly what I have done . I have packaged those tcl files and extracted them at runtime… It works but it’s maybe done in an ugly way…
Maybe panda is doing things better than me for the dll files ? Where can I found the dll’s extraction code to ensure that I am not over-coding things for nothing.
After that I would be glad if I can contribute to the build of a new tk package and extraction for panda3d.
Also I have similar issue for the cursor files.
It seems that they cannot be loaded directly through the vfs… I tried to backtrace this. And first I realised that vfs firstly points on start/ directory (in AppData/Local/Panda3D/ on windows). On the other side, packages are mount in their own installation directory (in …/hosts/domainname/packagename/versionNum/).
For loader.loadTexture() it founds files with the original pathname given on packaging. But for PNMImage() I should use the mounted package pathname in the relative way (…/hosts/…/image.png) or in the absolute way (/c/…/hosts/…/image.png ).
For cursor, it’s just impossible to open it through a vfs… It blocks in this part of panda3d sources (x11GraphicsWindow.cxx:1905) :
// If it wasn't found, resolve the filename and search for that.
Filename resolved = filename;
if (!resolved.resolve_filename(get_model_path())) {
// The filename doesn't exist.
x11display_cat.warning() << "Could not find cursor filename " << filename << "\n";
return None;
}
Some lines below, it’s calling the vfs. But in this part they are no reference to vfs (so it returns None and so it stops here the cursor loading)… is Filename module knowing the vfs ? I’m not sure of this… The resolve_filename() and exists() methods always return ‘False’ on my cursor pathname.
My cursor file is in the package (according to the result of ‘multify -vfs mypackage.mf’).
So, am I missing somethings ? Is it a panda3d strange behavior ? A is it a bug ? May I have to extract my cursor files outside the vfs ?
Thanks for your answers.