Bones and Geometry and the Axis Tool

About Truespace Archives

These pages are a copy of the official truespace forums prior to their removal somewhere around 2011.

They are retained here for archive purposes only.

Bones and Geometry and the Axis Tool // Tech Forum

1  |  

Post by RonHiler // Mar 8, 2009, 8:20am

Total Posts: 30
Hey Guys,

This is all Workspace side.

So I built a model of a person. Then I added some bones. All good. Everything works pretty well so far.

I moved the axis origin for the geometry using the Axis Tool so that the character's origin was at his feet centered underneath him.

Then I tried to import my model into my engine. I had a heck of a time becaue the bones kept being offset from the model (they were well above it). It took me a while to realize that the bone's orgin is different from the model's origin in TrueSpace.

So I went back in and hit the Shape Skeleton tool, then hit the Axis Tool, and sure enough, the bone's origin was up in the middle of the model. Oops. So I brought that down between the character's feet as well.

That's all fine, except is there any way to synch those two origins automaticaly (or at least be able to input numbers somewhere)? As it is, I only have visual clues. I can get them pretty close, but they are not *exact*, and that's going to cause me issues (clipping problems for one thing). I need those twol origins to be RIGHT on top of each other, heh. What's the best way of going about this?

Post by trueBlue // Mar 8, 2009, 8:40am

Total Posts: 1761
If you select the Pivot node inside your object, you can set it exactly with the Object Information panel. Select your object and then use the Down Arrow keyboard key until you see the Pivot in the Object Information panel.

Post by RonHiler // Mar 8, 2009, 8:52am

Total Posts: 30
I spoke too soon. I assumed putting the origins in the same place was going to do the trick, but it did not. The skeleton is still appearing in the engine way above (on the y axis) where the geometry is.

Why is this happening? It has to be something in TrueSpace. I tried flattening the history. What else should I do?

Post by clintonman // Mar 8, 2009, 9:00am

Total Posts: 304
This is how I got the skeleton to behave when exporting for the Doom3 and Unreal game engines.

qoute from my website:
"These are the steps needed to insure the the first joint position and rotation are relative to the world coordinate system.
Start the skeleton in the front view, one bone, drawn top to bottom centered on the origin.
Exit the skeleton tool and reset the matrix on the Skeleton_root inside the Skeleton node.
Rename Bone to MyBone and Joint to MyJoint. Names required for the plugin.
Now move the top joint into a good general position and build the rest of the skeleton from that joint."

One other thing is to be sure that the mesh rotation is (0,0,0) and the scale is (1,1,1) before skinning to the skeleton. I don't use the Axis tool because it just adds a level of confusion for me when exporting.


Post by TomG // Mar 9, 2009, 2:31am

Total Posts: 3397
You might try locating the object so that it is centered in 0,0,0 too - not sure it will have any effect though. This would put the object "half below the ground" in tS. Would be interesting to know if the skeleton's position relative to the world affects what you see in the exported mesh.

Given his experience with exports, clintonman's advice is most likely the best to be following though :)

Let us know how you get on.



Post by RonHiler // Mar 9, 2009, 5:06am

Total Posts: 30
Thanks guys,

I got it to work, but not in a real satisfying manner.

I've determined that for animations to work in the engine with the proper orientation, the model needs to be rotated to 0, -90, 0 and at the origin before doing any animation poses. The skeleton and geometry still import into the engine offset (for some reason I just can't figure out), but once converted from a world reference into a model (it's a C4 specific thing), they remerge, so it doesn't seem important that they export to the same place as long as they are oriented the same.

Now, I don't know if that orientation is a truism for every model I intend to do, or if that's just an artifact of some setting somewhere that I can't find. Guess I'll find out :) Maybe it's the skeleton matrix or something.

The big reason it's not so satisfying is that I spent an entire day trying different setting and exports, and I could really not find a pattern to how the model ended up in the engine. Sometimes it would be stuck in the ground, sometimes the skeleton was rotated differently than the geometry (which, as you can imagine, did bad things when the animations started), and sometimes it worked but the model was oriented wrong in game (the character would be animating walking sideways instead of foward).

I'm sure most of this is just an artifact of my inexperience with exporting, hehe. But at this point I'm not yet confident that I could reproduce the steps that led to a proper model facing forward with everything aligned. It's going to take a bit more experimenting on my part, I think.

I will try Clintonman's suggestion. I don't think I can leave the model origin at default, or it ends up half-buried in the ground in-game, so I HAVE to mess with the axis tool. Anyway, I'll keep working on it.

It bothers me that the model and skeleton don't import into the same place in the engine. It gives me a nagging feeling that something is wrong. As a programmer, I've learned that whenever I get that feeling, there usuallly is. Unfortunately, once I hit that step, I can't fix it in the engine (for non-rigged static models I can move them wherever I want, but for rigged models they pretty much have to stay right where they import or it really messes up the animations).

I was hoping to have a walking animation done and in-game by the end of the weekend, but that didn't happen, hehe. Ah well, such is life when you are learning new aspects of the tools, heh.

Post by Jack Edwards // Mar 9, 2009, 10:15am

Jack Edwards
Total Posts: 4062
Ron, also be aware that the shape skeleton tool doesn't change your animation keyframes. So if you already have animation key frames, the model will snap back to it's previous position during animation.

You have to finish all your skeleton shaping before applying keyframes.

This is a huge problem with BVH, since the BVH will will automatically snap your model into the shape of the BVH even if you use the shape skeleton tool to fit the skeleton to your model. The only work around for this at current is to use an external tool to modify the BVH data to fit your model. MrBones recommends BVH Hacker for this.

In my opinion the shape skeleton tool limitation is one of the most important issues that I'd like to see addressed in the 7.61 patch. is a privately held community resource website dedicated to Active Worlds.
Copyright (c) Mark Randall 2006 - 2021. All Rights Reserved.   ·   ProLibraries Live   ·   Twitter   ·   LinkedIn