# Anyone know how to implement this concept?

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

## Recommended Posts

Lets say you have a model with your standard ZPR (zoom pan rotate) and there is a point on that model you want to track such that there appears a 2-d reticle around it no matter what angle you view the model at (occlusion wanted, but not what I'm having problem with at this point). How would you implement this? Given you know the vertex and the viewing matrix? It's such an easy concept, but I'm having a hard time concentrating enough to remember what I have to do.

##### Share on other sites
In answering my own question, there is a glu function called gluProject which offers many of the requirements of tracking between the 3d and 2d pane.

http://www.opengl.org/documentation/specs/man_pages/hardcopy/GL/html/glu/project.html

##### Share on other sites
Quote:
 Original post by hiS_oWnHow would you implement this? Given you know the vertex and the viewing matrix? It's such an easy concept, but I'm having a hard time concentrating enough to remember what I have to do.
You need the model and projection matrices as well. Just multiply your 3d point by the ModelViewProjection matrix, and you get a 2d point in view/clip coordinates - the gluProject function will do this for you.

You can also do this with a billboard. Extract the up and right vectors from the ModelView matrix, and use them to orient a billboard centered on the point. This approach will get you occlusion as well, although the reticule will become smaller with distance.

1. 1
Rutin
25
2. 2
3. 3
4. 4
JoeJ
18
5. 5

• 14
• 14
• 11
• 11
• 9
• ### Forum Statistics

• Total Topics
631757
• Total Posts
3002141
×