I am new in this forum and I apollogize if there is any other forum open on this subject that I have not been able to discover.
I have a problem with triple buffering mode enabled. Well, a few problems, and I am frustrated not to find any relevant documentation to solve my problems.
We develop an application that updates portions of the view to get a fast animation of some processes that are calculated on a pixel base. During the animation a big portion of the image is not changed and we try to avoid regenerating the entire frame.
My first question is how triple buffering is actually implemented.
I have noted that when triple buffering is enabled, pixel formats based on SWAP_COPY do not work, even if the entire BACK buffer is copied to the FRONT buffer. Animation gets lots of artifacts near the limits of every update. That makes sense if the render bufffer and the FRONT buffer are phisically exchanged after the SwapBuffers() call.
The only reliable way I’ve got it working is in SWAP_EXCHANGE mode, saving the entire bitmap contents before the SwapBuffers() call and then restoring it back.
Where can some decent documentation be found relative to how triple buffering copies/exchanges buffers ? What SWAP_EXCHANGE vs. SWAP_COPY Matters to this ???
The second thing is how can we detect that triple buffering is enabled, and how turn it on/off ?
Third is how save/restore the BACK buffer without using the glDrawBuffers. The thing is how to avoid all the 3D operations and jsut copy buffer colors and depths.
I understand that these issues are not common to gaming programmers because they entirely rebuild every frame. But I can’t imagine I am the only one concerned about pixel-based operations that involve small areas in the view.
Thanks in advance