• Advertisement

Archived

This topic is now archived and is closed to further replies.

Cross hair

This topic is 6248 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, With the lesson 22 or 23, we can use the mouse. How can i do to display a cross hair like in Half-Life ? Thanks in advance. dylan.leyder@ibelgique.com

Share this post


Link to post
Share on other sites
Advertisement
You''ll need to impliments some billboarding routine, then just map a sem-transparent texture where you want the crosshair to be. By semi-transparent I mean only one color (usually black) has an alpha of 0 and all other values are 1.

HHSDrum@yahoo.com www.polarisoft.n3.net

Share this post


Link to post
Share on other sites
i wouldnt use billboards

just 2 viewmatrices eg
gluPerspective(...)
draw 3d stuff and world.

glOrtho(..)
draw HUD and 2d stuff like the crosshairs

http://members.xoom.com/myBollux

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Why not use :

glRasterPos2f(..);
//print Cross hair

glTranslatef(..);
//draw 3d world



This should work just fine...

Share this post


Link to post
Share on other sites

  • Advertisement