View Full Version : Refresh just a part of the scene

01-26-2002, 08:09 AM
I want to refresh just a part of the scene to speed-up the drawing. Is there any opengl function for doing this? Many thanks.

01-26-2002, 01:06 PM
Write your own routine to clear the screen...ie, don't use glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
(or whatever flags you use)

01-28-2002, 12:28 AM
Speeding up rendering is a complex topic.
You need to know exactly what your bottleneck is first, then you'll need to decide how to improve that.
Do you mean part of the window or part of the geometry?
Part of the window does work with glScissor() and glEnable(GL_SCISSOR_TEST) to specify the area you want to clear and refresh. (glScissor() is one of the few calls which affect glClear.)
Your app needs to be fillrate bound to take advantage of that.
For partial geometry updates you can establish a backing storage with the buffer region extension(s) which allow to save and restore the buffer data which is not changing. Search the forum on that.