Administrator
|
I'm not an expert, but from a quick reading of the Overlay class, it looks like you're supposed to draw 2D stuff into it, then render your OpenGL scene, then call Overlay.drawAll() to draw over your scene. So it seems like it wouldn't save you from having to render your whole scene every frame.
You could try something like this:
- On mouse down, snapshot your complex scene to an offscreen buffer
- While mouse down, draw the offscreen buffer contents instead of your real complex scene
- On mouse move, draw your selection rectangle on top
- On mouse up, restore the unaltered snapshot
But how low is your frame rate while rendering the complex scene? You'd only want to do this sort of snapshotting technique if your app doesn't permit interactive frame rates even with reduced quality.
Usually in apps with hugely complex scenes, I see them do mouse selection and stuff in a wireframe or reduced-fidelity rendering that permits interactive frame rates, then they render the full-fidelity scene only on request.
|