a 3d vertex fed in GL, how do you get screen 2d coord?

There MUST be a way to do this. Does anyone know how you can do selection like Homeworld did? I can’t figure out how to select ships in 3d in space. I can’t use selection buffer because they can click and drag and selection buffer works only for single clicking.

I think to get 2d coords you can use
gluProject() or gluUnproject() but I can’t remember which

there is an example on how to do this in the
redbook

You can use the selection buffer.

Record where you start the click and where the click ends (this will leave you with a rectangle) then set the gluPickMatrix to the proper coordinates and size.

Paul.