Jump to content
  • Advertisement
Sign in to follow this  
afsajghfd

Handling 3D objects

This topic is 3771 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

Hi, I'm working with some 3D objects (box, cylinder) and i would like to emulate the object handle like most of graphics software, so when i do click on one object appears four or six points to stretch or translate the selected object ex: http://img215.imageshack.us/img215/5261/asideroiq5.jpg if there are some technique to find and implement i'm using vb.net and dx9 but help in any other languaje are welcome too :) thanks in advance

Share this post


Link to post
Share on other sites
Advertisement
I'd start simple. First, draw your lines when a user clicks/un clicks on the screen.

1) If User Clicks, start point = x,y;
2) OnMouseMove, endpoint = current mouse x,y;
3) When User lets go, you now have start x,y & end x,y;
4) project those as rays into your 3d scene.
5) Test geometry against that frustum and see if they are within over 50%
6) if so, store it has selected!

Jeff.

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.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!