Greetings to all,
first of all I have to say that I'm new in graphics and also in OpenGL/JOGL! I am writing an application that visualizes 2D graphs using JOGL. However, it feels cumbersome to draw everything from scratch; all I need is basic shapes like circles and squares for the vertices, lines and arrows for the edges and also some text for the labels. I am using Java Swing to build my GUI. I was wondering if there was a JOGL wrapper or a library that would allow me to do this with as little overhead as possible. Does anybody have any useful information? Thank you for your assistance! Ilias |
You might want to check out glg2d https://github.com/brandonborkholder/glg2d/. It does exactly what you want, draw from Swing into JOGL. |
Thanks for your answer!
Indeed GLG2D looks very promising, it might be exactly what I need. To be more specific, I only need to draw vertices, edges, arrows and labels, what do you think? Also, what about interaction (for example, mouse moving shapes around)? Thanks for your assistance! Ilias |
To be more specific, I only need to draw vertices, edges, arrows and labels, what do you think? Also, what about interaction (for example, mouse moving shapes around)? Sounds like you want some kind of scene-graph implementation. I don't know much about those since I haven't worked with them. |
Well, I will definitely try it out!
Great work, thanks! |
Administrator
|
In reply to this post by Brandon Borkholder
On 06/27/2012 03:14 PM, Brandon Borkholder [via jogamp] wrote:
> You might want to check out glg2d https://github.com/brandonborkholder/glg2d/. > It does exactly what you want, draw from Swing into JOGL. > > You may also use our new graph package as shown in our applet test page. Graph is capable of rendering curves (splines so to say) via GPU. <http://forum.jogamp.org/Can-anyone-provide-an-example-of-how-to-use-com-jogamp-graph-curve-opengl-TextRenderer-tp3968662p3988396.html> ~Sven signature.asc (910 bytes) Download Attachment |
Thank you both for the input!
It is not clear to me yet how I would use the graph package to visualize graphs :( I'm not experienced with graphics, maybe I am missing something? So far glg2d seems to be fit for what I want to do, what would I gain with the graph package? Another question - I read that glg2d was to be integrated to jogl, what is the status on this? Also, would it be possible to build glg2d in a platform-independent manner? Right now building requires native jogl libraries... Thanks for your assistance! Ilias |
Administrator
|
On 06/28/2012 11:29 AM, iliasr [via jogamp] wrote:
> Thank you both for the input! > > It is not clear to me yet how I would use the graph package to visualize > graphs :( I'm not experienced with graphics, maybe I am missing something? So > far glg2d seems to be fit for what I want to do, what would I gain with the > graph package? Different API, different technology. Currently, still, graph's API sucks .. sort of - but we work on it :) However, it uses a quite new method of rendering curves on GPUs. GLG2D gives you the opportunity to use your Java2D API but using OpenGL (via JOGL) as it's rendering backend. @Brandon: Correct me if I am wrong. Some day .. we may use graph for GLG2D, yes, why not. But 1st we need to mature graph and check whether we can implement all features required by GLG2D. > > Another question - I read that glg2d was to be integrated to jogl, what is the > status on this? Yes .. thats the plan. Well, integration in a manner that: - we autobuild it - we deploy it .. all in it's own JAR file(s). So many things todo .. so we don't know yet when we accomplish this task. > Also, would it be possible to build glg2d in a > platform-independent manner? Right now building requires native jogl libraries... see above, it needs jogl .. hence .. > > Thanks for your assistance! You are very welcome. ~Sven > > Ilias > signature.asc (910 bytes) Download Attachment |
On Thu, Jun 28, 2012 at 5:45 AM, Sven Gothel [via jogamp] <[hidden email]> wrote:
Correct
I hope to see this, too. I have not investigated the Graph API and functionality, but I'd think a large part of GLG2D could be ported to use it.
|
Administrator
|
Brandon, please don't drop the support of the fixed pipeline. If you use the graph API that heavily relies on shaders, it won't work on machines with bad or no shader support. I remind you that lots of cheap Intel graphics chips have low performance when using PBO and / or shaders and unfortunately lots of consumers have such chips on their laptops.
Julien Gouesse | Personal blog | Website
|
Noted. I've made the library pluggable and the fixed-function pipeline is still in there. It requires GL2, but if I hear people that have use cases for GL2ES1, I'll look into it then. On Jun 29, 2012 4:35 AM, "gouessej [via jogamp]" <[hidden email]> wrote:
Brandon, please don't drop the support of the fixed pipeline. If you use the graph API that heavily relies on shaders, it won't work on machines with bad or no shader support. I remind you that lots of cheap Intel graphics chips have low performance when using PBO and / or shaders and unfortunately lots of consumers have such chips on their laptops. |
Free forum by Nabble | Edit this page |