Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Noob question: Draw a quad parallel to the view

Tags:

opengl

lwjgl

ok what I want to do is to draw a quad in the scene that lays on a plane parallel to the view. So it should appear flat.

More in particular, I think I didn't get very well how the mechanism of gluLookAt works in comparison with the functions glTranslate and glRotate:

If I position the view "manually" using the functions glTranslate and glRotate whenever I draw an object its position is relative to the current view. And I understand that this is due to the transformation matrix in the stack.

However, when I use the gluLookAt (that should automatically set the view), the coordinates of the object I want to draw must be "absolute" to be shown properly.

Thanks in advance.

like image 535
Jack Avatar asked Jan 27 '26 15:01

Jack


1 Answers

This tutorial describes how to do billboarding in OpenGL.

like image 187
genpfault Avatar answered Jan 29 '26 09:01

genpfault



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!