Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Models Limbs Origins

Author
Message
Jediam
14
Years of Service
User Offline
Joined: 14th Apr 2012
Location:
Posted: 18th May 2012 03:49
Hello,

When loading a model as an object, and checking all limbs x,y,z positions/offsets, they all have the same value(the models\\\' origin). How can I find the center of each limb relative to the model origin?
Pincho Paxton
23
Years of Service
User Offline
Joined: 8th Dec 2002
Location:
Posted: 18th May 2012 04:22
They may have all jumped back to the origin. I had that problem with Anim8or. Saving models sometimes loses the new limb positions.

Jediam
14
Years of Service
User Offline
Joined: 14th Apr 2012
Location:
Posted: 18th May 2012 05:59
Hello Pincho,

Do you know of any command within DBPro or any of its expansions that would "reset" the limbs positions?
Brendy boy
21
Years of Service
User Offline
Joined: 17th Jul 2005
Location: Croatia
Posted: 18th May 2012 10:57
Quote: "Do you know of any command within DBPro or any of its expansions that would "reset" the limbs positions? "

that can't be done. If the information doesn's exist in the file you can't "reset" it. What you can do is calculating it yourself. Of course the value probably won't be the same but you can calculate center point of each limb

zeroSlave
17
Years of Service
User Offline
Joined: 13th Jun 2009
Location: Springfield
Posted: 18th May 2012 11:32
To "reset" the position of the limb (If it's original x,y,&z positions are the same as the base model), I would assume that you could just reposition it to the base model.

So, if the original position of the limb is:
x = 0
y = 0
z = 0
And you move the limb:
x + 1000564
y - 6543
z + rnd(4000)
You should just be able to reset it by repositioning it to: 0,0,0.

Not sure on what the model/limbs are, so it's hard to judge what you are trying to accomplish.

Everybody is a genius. But if you judge a fish by its ability to climb a tree, it will live its whole life believing that it is stupid.
Pincho Paxton
23
Years of Service
User Offline
Joined: 8th Dec 2002
Location:
Posted: 18th May 2012 13:11 Edited at: 18th May 2012 13:14
Quote: "Hello Pincho,

Do you know of any command within DBPro or any of its expansions that would "reset" the limbs positions? "


What you probably need is a different exporter of the limb positions. I fixed my models with 3DS Max, but I'm sure that a lot of the packages work. In 3DS max you just click on each limb, and it is reset to its correct position.

Jediam
14
Years of Service
User Offline
Joined: 14th Apr 2012
Location:
Posted: 18th May 2012 16:36
Quote: "that can't be done. If the information doesn's exist in the file you can't "reset" it. What you can do is calculating it yourself. Of course the value probably won't be the same but you can calculate center point of each limb"


I had a feeling that would be the case. Calculating the center for each limb can't be accomplished unless each limbs individual extents/bounds can be established. As you know, all of the limbs are sharing the same center point because they are using the completed models extents.

Quote: "Not sure on what the model/limbs are, so it's hard to judge what you are trying to accomplish."


It's difficult to describe in words, but that's all I have for now. Say you draw a square and bisect it from its corners; where the lines meet is the squares' center and origin, the four lines making up the square are its extents. This can also be done with any rectangular shape. If we were to add a rectangle to the square and put it at its perimeter, both objects still have their own centers, but if they are treated as one object, both of their centers will move to the origin(in this case the center of the square). Unless the center of the rectangle is known before it moves to the origin, we can't relocate its' center unless we first unbind it from the origin.

Quote: "What you probably need is a different exporter of the limb positions. I fixed my models with 3DS Max, but I'm sure that a lot of the packages work. In 3DS max you just click on each limb, and it is reset to its correct position.
"


I'm using AC3D and exporting my model as an .x file. I think there is an option to export object data, but I don't know if this means the limbs data (including their centers) within the overall model get exported.

Thankyou for your help, I welcome all of it.
Brendy boy
21
Years of Service
User Offline
Joined: 17th Jul 2005
Location: Croatia
Posted: 18th May 2012 21:28
Quote: " Calculating the center for each limb can't be accomplished unless each limbs individual extents/bounds can be established."

you can calculate that yourself using vertexdata commands

Login to post a reply

Server time is: 2026-07-22 00:35:51
Your offset time is: 2026-07-22 00:35:51