Hello Vincenzo,

Vincenzo Marafioti wrote:
> Carsten Neumann ha scritto:
>> hm, I don't understand what is happening, if I put the OC query around 
>> mgr->redraw() it works fine, but for the FBO it always returns 0. 
>> Whether the FBO is rendered before or after the main scene does not make 
>> a difference either (I thought perhaps a render target change would 
>> reset the counters).
>>   
> If this is the reason I think I can't solve it on my own, there should 
> be a FBOViewport method that get the number of passed samples. I tried 
> to use also the FBOViewport::getOcclusionQuery() but without any result.

RenderAction::getOcclusionQuery() is part of the machinery that gets 
used when the RenderAction is in occlusion culling mode, it probably 
should not be public in the first place.

> Maybe  some OC query code around
> 
> for (UInt16 fi=0; fi < getMFForegrounds()->size(); fi++)
>                 getForegrounds(fi)->draw(action, this);
> 
> line: 1435 file: OSGFBOViewport.cpp
> 
> could help? I am stuffed in this point with my project...

I've now looked at the OpenGL commands that are issued with bugle and 
there is nothing that looks suspicious to me, so I'm still confused why 
it's not simply working.
One thing you might want to try is hacking the FBOViewport so that the 
begin/end query commands are issued while the FBO is active, that is 
about the only thing I can think of that might cause the samples for the 
FBO to be zero all the time, although I can not find anything about it 
in the spec.

        Cheers,
                Carsten


------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to