studioGPU

 
   
 

You must be signed-in to post a topic or reply

sgpuWriteModel
Posted: 19 June 2009 02:58 PM   [ Ignore ]
Newbie
Rank
Total Posts:  7
Joined  2009-04-17

Just a quick noob question:

I know that if you’re using sgpuWriteModel to do animation based on joints, not on point caching, that you have to parent all meshes to joints or skin them up.  I was just wondering: do all the joint have to come back to a single root joint, or can that part be avoided?  If so, that effects the way I’m going to be rigging a few of the assets here.

Also, does it have to be one joint per mesh chunk, or can I parent an entire hierarchy to one single joint?

Lastly, in another thread it’s mentioned that the -confirm flag is supposed to stop those confirmation boxes from popping up, but even with the latest downloaded version of the exporter I can’t get those boxes to go away in my baking scripts.  What does that flag take as a parameter?

Thanks!

Profile
 
 
Posted: 20 June 2009 08:55 AM   [ Ignore ]   [ # 1 ]
Administrator
Rank
Total Posts:  16
Joined  2009-03-03

sgpuWriteModel will export one or more hierarchies of joints and transform nodes. These hierarchies can be mixed so that you can have multiple joint chains within a single model and you can have joint chains that are broken by transform nodes. You can also just have an animation of transform nodes without using any joints.

To use this command, you select the root(s) of the hierarchies that you want to export. You can export multiple root nodes, but just make sure you select the same root nodes when exporting animation.

In general, it is more efficient if you have a single transform as the root, so I would recommend that. Since Maya can have different paths to the same nodes, it might be easiest to have a special transform node in the Outliner represent your root node for exporting and then let that node have the multiple root nodes you want to export as its children.

There should not be any nodes above the selected roots that have transformation because those parent transformations would not be exported.

This command supports hierarchical rigid animation through parenting and skinned animation through influences in skin clusters. These types of animation will produce smaller animation files compared to sgpuWriteVerts because only the transformation information will be exported.

In addition, you can mix in some baked vertex animation with this command also by adding the extra attribute “Cloth” to a shape. When the exporter sees this flag is turned on, it will export object space vertex animation for this shape only. This allows you to use free form and other types of deformation on some meshes within a model that is mostly hierarchically animating.

Common syntax is:
Geometry, GXB: “sgpuWriteModel -geom”
Animation, GAB: “sgpuWriteModel -anim -bake”

Profile
 
 
Posted: 20 June 2009 09:00 AM   [ Ignore ]   [ # 2 ]
Administrator
Rank
Total Posts:  16
Joined  2009-03-03

The confirm flag usage looks like this:

“sgpuWriteModel -geom -confirm”

will not display the confirmation dialog about meshes being double-sided, etc. that the command

“sgpuWriteModel -geom”

by itself would. I just tested this with version 1.1.7 of the Maya exporter and the confirmation dialog did not display for me.

Profile
 
 
Posted: 29 June 2009 04:22 PM   [ Ignore ]   [ # 3 ]
Newbie
Rank
Total Posts:  7
Joined  2009-04-17

Hi Coder Brian,

I was running 1.1.6, but I just today upgraded to 1.1.8 and I’m still getting the message boxes.

Here’s the script I’m attempting to run:

int $model 1;
int $animation 0

string $sel[] = `ls -sl`;

//string $s = "viking1:Viking";

for ($s in $sel{
    string $names[] 
= `python ("'" + $s + "'.split(':')")`;
    
string $wd = `workspace -q -rd` + "data/";
    
string $filename $wd "280_060_" $names[0] "_" $names[1];

    
select -r $s;
    if (
$model)
        
sgpuWriteModel -($filename ".gxb") -confirm;
    if (
$animation)
        
sgpuWriteModel -anim -bake -($filename ".gab") -confirm;

I still get the following warning:

- “Subdivision surfaces can only have one material, gloria:white_eye_LShape”

There was another one earlier today but I didn’t write it down; if it comes up again I’ll note it for you.

Thanks,
~ Charles

Profile
 
 
Posted: 30 June 2009 02:14 AM   [ Ignore ]   [ # 4 ]
Administrator
Rank
Total Posts:  16
Joined  2009-03-03

Okay, I see what you mean. There is a different confirmation dialog that the “-confirm” flag turns off. That confirmation dialog was just reporting about efficiencies in the flag settings that weren’t serious errors.

This dialog you are seeing was a warning/error that more serious, so the “-confirm” flag wasn’t applied to that dialog.

But, it makes sense for the confirm flag to turn off all dialogs as long as errors are reported to the output window instead. I’ll fix that in a new version.

I also hope to remove the requirement about multiple materials on a subdivision surface soon.

Profile
 
 
   
 
 
RSS 2.0     Atom Feed