|
|
OpenGL GUI
I'm creating a OpenGL library that should be able to handle complex 2D
GUI's. The GUI will be rendered on top of a 3D scene, which obviously
would be repainted each frame. It would be nice if the GUI could be
alpha transparent. I want to minimize the number of OpenGL calls
performed each frame, so optimally only the parts that changed in the
GUI should be repainted. This is a common optimization in all GUI
libraries. How can I do this with OpenGL? Would using a pixel buffer
solve the problem? Is there a way clear only the 3D scene each frame
(for example clear everything where z > 1)?
Thanks in advance!
/Jesper Nordenberg
|
|
0
|
|
|
|
Reply
|
megagurka
|
12/16/2004 8:02:48 PM |
|
As allways in life, you can choose different approaches.
using the stencil buffer to keep some part of the screen untouched
(space-ship cockpit, or you GUI) is a common practice.
OpenGL supports different viewports. Assuming you have a menu at the top
(or left, or right, or bottom), you can use two viewports, one for the GUI
and the other for the 3d-scenery (glViewport).
But keep in mind, when using glClearBuffer the whole buffer is cleared
regardless of you viewport settings.
If you want a transparent GUI menu on top of a 3d scenery (common speaking:
a HUD - head up display), then you can't take advantage of viewports or
stencil buffers. But rendering the GUI into a texture and use glSubTexture
to replace only parts of your GUI is the best practice.
google for the mention topics, if you have any further questions, don't
hesitate to ask again.
regards,
godfired
Jesper Nordenberg wrote:
> I'm creating a OpenGL library that should be able to handle complex 2D
> GUI's. The GUI will be rendered on top of a 3D scene, which obviously
> would be repainted each frame. It would be nice if the GUI could be
> alpha transparent. I want to minimize the number of OpenGL calls
> performed each frame, so optimally only the parts that changed in the
> GUI should be repainted. This is a common optimization in all GUI
> libraries. How can I do this with OpenGL? Would using a pixel buffer
> solve the problem? Is there a way clear only the 3D scene each frame
> (for example clear everything where z > 1)?
>
> Thanks in advance!
>
> /Jesper Nordenberg
_______________________________
remove the _ for reply.
|
|
0
|
|
|
|
Reply
|
Gottfried
|
12/17/2004 3:04:18 PM
|
|
|
1 Replies
187 Views
(page loaded in 0.041 seconds)
Similiar Articles: GUI keyboard input when zoom in selected - comp.soft-sys.matlab ...opengl + zoom - comp.graphics.api.opengl GUI keyboard input when zoom in ... Graphical Input - comp.soft-sys.matlab Use a JTextField graphical user interface ... mouse to ... GUI colors Linux - comp.soft-sys.matlabFull Screen problems in Linux Ubuntu - comp.graphics.api.opengl ... GUI colors Linux - comp.soft-sys.matlab... graphical user interface of the MATLAB desktop on Linux ... GLUT - F1 Key / function keys not captured by App - GLUT_KEY_F1 ...Hi, This question is not exactly about openGL, but about GLUT. Sorry if this is ... Glut disadvantage... - comp.graphics.api.opengl gui keyboard function - comp.soft-sys ... WANTED: OpenGL 2D plotting library - comp.graphics.api.opengl ...Re: OpenGL GUI / Plotting / Graphing Library Re: OpenGL GUI / Plotting / Graphing Library - RUBY . This is a ... WANTED: OpenGL 2D plotting library OpenGL without window system? - comp.graphics.api.opengl ...Hey guys, This isn't a 100% OpenGL question but I'll limit this to the appropriate ... back through it and at one point in there I was interested in writing my own GUI ... translucent windows - comp.graphics.api.openglHow to clear JPanel? - comp.lang.java.gui translucent windows - comp.graphics.api.opengl Background image on GLDrawable? - comp.graphics.api.opengl ..... lang.java.gui How ... Glut disadvantage... - comp.graphics.api.openglAlso, a lot of books, tutorials ... still use GLUT. So go for it. Later on, when you learn enough about OpenGL, you can switch to another GUI toolkit. Positioning the model into the scene with mouse - comp.graphics ...Since you are an expert of opengl, what if I send you the files to compile ? ... -- Bye, Colossus Mizio, a proxy scanner tool with GUI for Linux http://mizio ... wglMakeCurrent in an object-oriented environment - comp.graphics ...The only option I see is to spawn a thread for OpenGL and pass it tokens ... multi-window, multi-threaded animated 3D graphics programming in OpenGL with programmable GUI on ... Background image on GLDrawable? - comp.graphics.api.opengl ...How to clear JPanel? - comp.lang.java.gui Background image on GLDrawable? - comp.graphics.api.opengl ... How to clear JPanel? - comp.lang.java.gui... pictures on GUI ... OpenGL GUI Application - Song Ho AhnOpenGL Windows GUI Application. This article is about a MVC (Model-View-Controller) framework to create OpenGL GUI applications on Windows platform. OpenGL GUI: Tutorial #1 - Welcome to Ionware ProductionsOpenGL Tutorials, Demos, Games and More... ... Kindly hosted by . GUI Tutorial : Part #1. Welcome to the first tutorial in GUI series. 7/10/2012 7:22:45 AM
|
|
|
|
|
|
|
|
|