Handling 3D objects

Started by
1 comment, last by afsajghfd 16 years, 1 month ago
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
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.
thanks

This topic is closed to new replies.

Advertisement