Hi Carsten, hi Yvonne

thanks for your answers.
I have a NVIDIA GeForce 7900 GTX.
It supports MRT's, so I guess it supports render targets with diffrent 
bit per fragment.

I'm sorry when I ask a stupid question, but I have never rendered twice 
in OpenSG before.
Maybe you know an example how to do that?


The OpenGL warning disapeared by setting "Width" and "Height" in the 
second pass to concret values:

// second pass: Post-processing (simulate Circle of Confusion)

 beginEditCP(_shl2);
   _shl2->setVertexProgram(_vp_program2);
   _shl2->setFragmentProgram(_fp_program2);
   _shl2->setUniformParameter("Width",512);    // instead of : 
_shl2->setUniformParameter("Width", x);     
   _shl2->setUniformParameter("Height", 512);   // instead of: 
_shl2->setUniformParameter("Height", y);  
   _shl2->setUniformParameter("Tex0", 0);
   _shl2->setUniformParameter("Tex1", 1);
  // _shl2->setUniformParameter("maxCoC", 5.0);
 endEditCP(_shl2);

Thanks,
Greeting,
Ria



Yvonne Jung schrieb:
> Hi,
>
> MRTs are simply not supported in 1.8x, you have to render at least twice, when
> a blur-factor shall also be outputted...
> Concerning the GL error: this often happens in combination with foregrounds,
> but I never have dug deeper into it (though I should have), since it works
> nonetheless.
>
> Bye
> Yvonne
>
> Am So, 6.06.2010, 17:55, schrieb Carsten Neumann:
>   
>>      Hello Ria,
>>
>> On 06.06.2010 05:36, Ria Müller wrote:
>>     
>>> Dirk Reiners schrieb:
>>>       
>>>> On 06/05/2010 04:09 PM, Ria Müller wrote:
>>>>         
>>>>> I try to do a depth of field effect in OpenSG using a two-pass
>>>>> Post-processing Shader.
>>>>> On the first pass the scene is rendered, outputting the color, depth and
>>>>> a blurriness factor (depending on the depth).
>>>>> On the second pass the image from the first pass is filtered with a
>>>>> variable-sized filter kernel to simulate the circle of confusion. The
>>>>> blurriness factor from the first pass controls the size of the filter
>>>>> kernel.
>>>>>
>>>>> For being able to render in the scene to multiple buffers (color in
>>>>> RGBA8 and blurfactor in RGBA16) at one time I need to use multiple
>>>>> Render Targets. Unfortunately I'm very new to OpenSG and using 1.8 I
>>>>> couldn't find any descriptions or examples how to do that.
>>>>> Up to now I create two diffrent textures and attach them to an
>>>>> FBOViewport-Object:
>>>>>           
>> hm, that sounds like the right approach in general. Are you perhaps on
>> hardware that does not support render targets with different bits per
>> fragment (you have 32 for the color target and 64 for the blurfactor
>> target)?
>>
>>     
>>>> sorry, I don't have the time to look into the details of your code right
>>>> now.
>>>> But in general FBO support is much better in OpenSG 2. What you're trying
>>>> to do
>>>> is probably pretty simple based on Carsten's Deferred Shading framework,
>>>> which
>>>> has to do post-processing anyway.
>>>>
>>>> Carsten, can you comment a little bit on this one?
>>>>         
>> sorry for the delay, my graphics card decided to quit service yesterday...
>>
>>     
>>> thank you for your fast answer.
>>> Unfortunately I need to use OpenSG 1.8 because  I use a Stereosystem
>>> which is based on this version.
>>> Nevertheless I am interested in Carsten's Deferred Shading framework.
>>> Maybe I can get some hints from it.
>>>       
>> FWIW, I think a better example in 2.0 is the HDRStage since it has a
>> pretty similar approach, i.e. render the scene to FBO and run a
>> post-processing step over it.
>>
>>     
>>> Does anybody know what the warning " FBO initialize pre OpenGL error:
>>> invalid operation!" means?
>>>       
>> It reports the OpenGL error "Invalid Operation". What exactly causes
>> this errors is unfortunately a bit tricky to tell as the  place where it
>> reports the error is *before* initializing an FBO (so the error does not
>> necessarily have anything to do with the FBO, but is only the place
>> where it is first caught).
>> The easiest way to find out what exactly causes the error is to run the
>> program under an OpenGL debugger.
>>
>>      Cheers,
>>              Carsten
>>
>> ------------------------------------------------------------------------------
>> ThinkGeek and WIRED's GeekDad team up for the Ultimate
>> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
>> lucky parental unit.  See the prize list and enter to win:
>> http://p.sf.net/sfu/thinkgeek-promo
>> _______________________________________________
>> Opensg-users mailing list
>> Opensg-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/opensg-users
>>
>>     
>
>
> ---
> Yvonne Jung
> Fraunhofer-IGD    | Tel.: ++49-6151-155-290
> Fraunhoferstr. 5  | Fax.: ++49-6151-155-196
> 64283 Darmstadt   | email: yvonne.j...@igd.fraunhofer.de
> Germany           | http://www.igd.fhg.de/igd-a4
>
>
> ------------------------------------------------------------------------------
> ThinkGeek and WIRED's GeekDad team up for the Ultimate 
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
> lucky parental unit.  See the prize list and enter to win: 
> http://p.sf.net/sfu/thinkgeek-promo
> _______________________________________________
> Opensg-users mailing list
> Opensg-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/opensg-users
>   


------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Opensg-users mailing list
Opensg-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to