Hi,
I have a question regarding multipart characters: I’m working on a configurable character system where I want to be able to change textures on geometryparts or geometryparts alltogether.
So, when the artist creates a character in the modelling package (we use Maya, btw) he creates a bunch of seperate geometries with speaking names, such as “Legs”, “Body”, “Head” and so on.
The artist is well-trained and well-behaving, so I know that each distinct geometry in the source model makes sense and should be kept seperate, even when the model is turned into an Actor.
I also understand, that I can achieve this by using the egg-optchar tool with the -flag option, so I’m doing something like:
egg-optchar -inplace -flag Legs=Legs -flag Body=Body -flag Head=Head ...
And it all works fine.
So here’s my problem:
I want to give the Artist total freedom, and thus don’t know the geometrynames a-priori. The artist might come up with new, unplanned bodyparts such as “Beard”, “Eyes”, “LeftUpperArm”, “Shoulders”, etc.
So whenever I get a new model from the Artist, I need to first find out the names of all GeomNodes, so I can feed them to egg-optchar.
Is there an easy, built-in way for doing this?
I have a workaround, but I don’t like it:
- I first export the geometry as a Model (maya2egg -a none …), so that the geometries won’t get combined
- I then load the model, and analyze the subtree to find all geomnames
- Export the model a second time, this time as Actor (maya2egg -a model …)
- Now I have the info to run "egg-optchar -inplace <long list of -flag options>
I’m not happy because I need to export everything twice. Is there a better way to achieve this?
Other ideas I had:
*) export once, as actor, and then parse the egg file. Alas, there are the egg parser classes in python, but I don’t know how to use them
*) change egg-optchar to take a new option, something like -flagall which would keep all geometries similar to the -keepall option keeping all joints
So if anyone has a great idea, please let me know…
Cheers,
Erik