Sign in to follow this  

Handling 3D objects

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

This topic is 3558 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this