drawScene for all events?
Posted by The.Scotsman on May 16, 2012; 9:39pm
URL: https://forum.jogamp.org/drawScene-for-all-events-tp3998011.html
Hi everybody.
Sorry in advance if I'm asking a question that's already been answered.
Couldn't figure out proper search terms.
Like most people just getting started with JOGL, I've been working with the demos.
Specifically, the HDR demo that loads and displays an OBJ file.
I've successfully extended this to load an X3D file. Works great - with small X3D's.
However, the X3D file that I intend to eventually load is about 1.5GB in size.
Loaded into memory as an XML Document, it's more like 3GB.
In all the examples I've seen, display() is called for every change (or if there's an Animator, every frame.)
And all the example display() methods call drawScene() to load the content.
Since it's taking about 5 seconds to load the content of my 1.5GB X3D (from document to GL2), it's hard to see how this paradigm can work. (1.5GB x 60FPS = 90GB/S !!!)
It seems like there must be a way to, for example, change the viewport width/height, without reloading the content each time. Same with rotation/zoom via UserSceneInteraction.
A simple example (I'm a simple guy...) would be highly appreciated.
If that's just not how OpenGL works (i.e. always requires top down scene building), are there some strategies to improve performance?
Thanks.