PDA

View Full Version : pBuffer's double buffering approach



him_me2
12-14-2009, 04:56 AM
Hi all,

I am using pbuffer in my application (No FBO support) for offscreeen rendering.

Initially while describing pixel format for pBuffer i set the
double buffer flag to false and also i was not using "WGL_ACCELERATION_ARB" flag earlier.


int pf_attr[] =
{
WGL_SUPPORT_OPENGL_ARB, TRUE, // P-buffer will be used with OpenGL
WGL_DRAW_TO_PBUFFER_ARB, TRUE, // Enable render to p-buffer
WGL_RED_BITS_ARB, 8, // At least 8 bits for RED channel
WGL_GREEN_BITS_ARB, 8, // At least 8 bits for GREEN channel
WGL_BLUE_BITS_ARB, 8, // At least 8 bits for BLUE channel
WGL_ALPHA_BITS_ARB, 8, // At least 8 bits for ALPHA channel
WGL_DEPTH_BITS_ARB, 0, // At least 16 bits for depth buffer
WGL_STENCIL_BITS_ARB, 8,

WGL_ACCELERATION_ARB, WGL_FULL_ACCELERATION_ARB,

WGL_DOUBLE_BUFFER_ARB, TRUE,
0 // Zero terminates the list
};




Now i am getting the double buffer by setting it to TRUE as shown above and also i'm also setting the acceleration to FULL as shown above.

But after doing it i'm not seeing any performance improvement. And i want to know that is that any measurable performance gain with the double buffer approach with pBuffer. I know that it cannot give performance like the onscreen window rendering approach, but will there be any advantage with this approach?

if there is any performance gain,then what is the method to avail this feature in pBuffer?

Thanks