PDA

View Full Version : P-buffer and VBOs



Arkion
10-04-2005, 05:03 AM
Hi all,

I'm trying to implement P-buffer support in my shadow mapping app for better backwards compatibility. Currently, I'm using EXT_framebuffer_object for off-screen depth rendering and they work perfectly fine.

My problem is that the VBO rendered primitives don't show up in the P-buffer at all - only primitives rendered thru immediate mode functions show up. I've shared the resources between the main window rendering context and P-buffer RC using wglShareLists. Has anyone had any luck getting VBO's to work P-buffers properly?

BTW, I have ATI Radeon 9700 with Catalyst 5.9 drivers.

Jackis
10-04-2005, 06:45 AM
Hello, Arkion.

Hmmm... strange thing! Tell me, why did you create an unique RC for your FBO? The main advantage of FBO against P-buffer extension, is, that you have no need to create another context. And if you don't need to create new context, so, the sharing is not a problem, because you don't need to share any data between context.

Maybe, you use FBO in another manner, than it is proposed to?

Arkion
10-04-2005, 07:21 AM
Hi,



Hmmm... strange thing! Tell me, why did you create an unique RC for your FBO? The main advantage of FBO against P-buffer extension, is, that you have no need to create another context. And if you don't need to create new context, so, the sharing is not a problem, because you don't need to share any data between context.
Sorry, I wasn't perfectly clear on this. What I meant is that I created a separate RC for the P-buffer implementation, not the FBO. I want to replace the FBO's with P-buffers. But P-buffer needs an unique RC because the off-screen buffer width/height could be larger then the main window resolution.

That is to say, I need an additional rendering context and have the VBO's shared between these two contexts.

Zulfiqar Malik
10-04-2005, 08:42 AM
Since P-buffer is a seperate rendering context altogether, therefore you will have to do all the initialization that is usually required for proper rendering like projection matrix, modelview matrix, cullface, etc. etc. Other than that, i can't seem to find an explanation for such behavior as i have used both several times with success.