Jump to content
  • Advertisement
Sign in to follow this  
davek20

MD3 Model help - SOLVED

This topic is 4057 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I need some help rendering MD3 models. What I have right now is a model that is broke into a head, torso and legs. I can render them fine separately, but I'm stumped on how to render it as a whole. I know that in the Tags there is an orientation matrix and position associated with it but I couldn't find anything on what is held in the orientation. Does it have BOTH rotation and translation or just the rotation? Also, is it a transformation matrix or a quaternion? I noticed that when I print out the position of head tag associated with the torso they are non-zero, while in the head model the head tag is 0,0,0. So what would be the best way to render all the parts? Should I render the torso, then for each tag, go to that position, apply the transformation and then render that part? Or do I have to search through all the other model parts and find a model that has that tag in it? (since its a bad idea to assume that all models have the same number of models and tags and names) Once I get 2 parts connected, then the whole model can be loaded lol. Thanks in advance. [Edited by - davek20 on May 16, 2007 10:07:36 AM]

Share this post


Link to post
Share on other sites
Advertisement
I guess this would help ;)

http://rapidshare.com/files/31419184/MD3Animation_SDL.zip

Enjoy,

EnygmyX.

Share this post


Link to post
Share on other sites
Thanks for that link. It looks like it will help out a lot. Everything in there is nicely explained and EVERYTHING is commented :)

Share this post


Link to post
Share on other sites
np ..... but be warned that since this code was meant to be a tutorial by the author therefore it is quite unoptimized and there are a few memory leaks even. So if you are planning to do something worthwhile quite a few optimizations will be needed like replacing all those matrix multiplications with quaternions etc.

EnygmyX.

Share this post


Link to post
Share on other sites
Quote:
Original post by enygmyx
np ..... but be warned that since this code was meant to be a tutorial by the author therefore it is quite unoptimized and there are a few memory leaks even. So if you are planning to do something worthwhile quite a few optimizations will be needed like replacing all those matrix multiplications with quaternions etc.

EnygmyX.


Ok, thanks for that heads up. I'm trying to make a game and using the MD3 models in it. I got it working with the head linked to the torso, but I found a problem that will happen later on with different models being loaded in and attached.

I looked at the animation.cfg file and it looks like it would solve this and keep things synced up. I found this sit with some info about the file format for the .cfg file http://education.mit.edu/starlogo-tng/shapes-tutorial/shapetutorial.html

I really don't see how that can be used to animate it? Like how would it sync the head and leg models with the torso?

Share this post


Link to post
Share on other sites
Nevermind, I found what I needed in the code you posted. I guess I should have read over the code more closely.

Thanks for the help enygmyx

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!