view problem

if have a point say at (0,0,0) that is in view but say there is a wall in front of it and i can not see this point on the screen how do i test for this??

[This message has been edited by jono_123 (edited 11-23-2002).]

If you want to test whether your point is visible straight from your point of view just test value in depth buffer at projected XY coordinates of that point…
Use gluProject(…) for that.
Value in depth buffer equal to projected z-value from gluProject(…) means your point is visible. otherwise - not.

Hope it helps

how do ya get the depth value from the depth buffer?

Use glReadPixels(…) with GL_DEPTH_COMPONENT

Anyway why not to take a look at OpenGL manuals? They’re very useful for beginners.

The redbook: