Panda has bunch of dlls. Although most of their names are self explanatory, I have no idea what others are for. Is there some kind of list showing which dll is used for what? Or do I need to read the source?
The thing is resently I asked myself a question: how would I make a 3d model viewer like all the others with just few megabytes of size, powered by Panda? I would only need the core panda3d stuff, only opengl renderer, no collisions, no physics, audio, shaders, nothing else. If you use Packpanda, you end up with few hundred megs of extracted folder, use ppackage and you need internet connection, same for pdeploy, which is also buggy and experimental. And also, I dont want to have all the data in an exe, but rather in folders.
And this isnt just about model viewers. Just about any small game created like this will end up too big for what it uses.
I would like to know what I can delete manually to keep the size to minimum
If you really want a stripped-down version of Panda3D, you’ll need to compile your own version.
But why not create a .p3d file, and use “pdeploy” to create a “standalone” version? It will contact the internet to grab compressed and optimised versions of the required Panda3D libraries.
I remember I couldnt get pdeploy to work even after all the help from David. I think the “installer” mode worked fine though. But for such a simple program I prefer to distribute it as an archive.
Also, does standalone mode merge all the files into a single exe file? Is there a way to disable this?
Do the snapshot builds have the bugs fixed, or do you mean they arent fixed yet?
Maybe I should compile my own version of Panda, at least for now.
I thought my program would still work if I removed some dlls which it never uses anyway.
If I wanted to add my own formats like obj or md5, where should I start? I don’t mind if its only possible with C++.
How hard would it be to add formats which store textures in them (or like with obj, store materials in another file)?
I know there might not be a single answer for these questions, I just dont know where to start.
To view these models in Panda, you would have to write a converter to a Panda model format. Today that would mean egg, so you would need to write a program that converts obj to egg (or md5 to egg). For formats that store embedded images, you’d have to write the images to a disk file first, or extend egg to support embedded image data itself.
Or, you can wait until the Collada importer is finished, and write your converter to go obj to dae. It depends on how patient you are, of course.
In any case, if you wrote your converter in C++, using the tools in Pandatool (similar to lwoegg and xfileegg), you can write it as an OBJToEggConverter class, which means you can integrate it tightly with the existing Panda loader to allow it to transparently load .obj files directly, the same way it loads .lwo and .x files directly today. If you’d prefer to write the converter in Python or some other language, then you won’t be able to do this.
Let me get this straight: when Collada becomes the standard, then the structure of Panda3D’s internal vertex and geometry data objects is going to change?
I rather go with the first option.
I dont think I can wait a year for this one.
Till now I never thought how this worked. So you write a command line program and Panda calls it every time you load with loader and converts it to egg? Isnt this a bit slow?
Or did I not understand it correctly?
The bold text is the part I didnt understand.
Anyway, I should browse Panda’s source for this one. What classes should I look at and what class should I inherit from?
You could use the existing dae2egg in the meantime, which will be improved and maintained until the alternative is finished.
That’s how we currently do most of our importers. And no, Panda3D doesn’t internally call the command-line program - it just interfaces with the SomethingToEggConverter derivative and directly loads the resulting EggData structure.
Also, the second time the same file is loaded, it is of course read from the model-cache (which stores as .bam).
The SomethingToEggConverter class. You should take a look at the other importers in pandatool.
I think that currently dae doesnt even support normals properly, so I don’t mind just porting my whole code for dae when its done. In an other thread you said it will be ready for panda 2.0, and drwr once said that will be in the far future (or something like that).
“derivatives”?
Is this simply put- they use the same classes?