Jump to content

  • Log In with Google      Sign In   
  • Create Account


Moving Milkshape Models w/out translatef


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
1 reply to this topic

#1 Magicchessmaster   Members   -  Reputation: 122

Like
Likes
Like

Posted 17 August 2001 - 06:00 AM

I would like to have more control over my Milkshape Models. i cannot figure out how to access a center point on a model (x,y,z) that i can change to change the position of my Model in OpenGL. The only thing i can figure out is to use Translatef() before my call to pModel->draw(). i believe that this will cause problems down the line, since it would be more difficult to determine collision and to move a possible 100 models in different directions simultaniosly. can anyone tell me how to find that center point and use it to move my models??

Sponsor:

#2 brettporter   Members   -  Reputation: 122

Like
Likes
Like

Posted 19 August 2001 - 12:15 AM

You''ll have to use translatef at some point, it just means you have to do the same when doing collision detection.

To find the centre of the model, you should just be able to do the averages of the (x,y,z) values for all the vertices.

~~~
Cheers!
Brett Porter
PortaLib3D : A portable 3D game/demo libary for OpenGL





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS