jogamp
›
jogl
Search
everywhere
only in this topic
Advanced Search
Multiple OpenGL canvas in Swing application
Classic
List
Threaded
♦
♦
Locked
4 messages
juankprada
Reply
|
Threaded
Open this post in threaded view
♦
♦
|
Multiple OpenGL canvas in Swing application
Hi, I am making a Swing application that will eventually have more than one OpenGL widget (canvas), each with different sizes. Is that even possible to show all of the openGL widgets at the same time? each with its own FPSAnimator ?
gouessej
Reply
|
Threaded
Open this post in threaded view
♦
♦
|
Re: Multiple OpenGL canvas in Swing application
Administrator
Hi
You can do that but if you want them to share the same OpenGL resources, you'll have to use a shared context.
Julien Gouesse |
Personal blog
|
Website
juankprada
Reply
|
Threaded
Open this post in threaded view
♦
♦
|
Re: Multiple OpenGL canvas in Swing application
That would be done with the context.makeCurrent() and context.release() methods right?. Seems like not that difficult to do.
thanks for the answer. Now I can proceed safetly
gouessej
Reply
|
Threaded
Open this post in threaded view
♦
♦
|
Re: Multiple OpenGL canvas in Swing application
Administrator
Actually, no. You can use this method:
http://jogamp.org/deployment/jogamp-next/javadoc/jogl/javadoc/javax/media/opengl/awt/GLCanvas.html#setSharedContext(javax.media.opengl.GLContext)
Julien Gouesse |
Personal blog
|
Website
Free forum by Nabble
Edit this page