I did not use osgPPU but it seems like it's ideal for the job! I don't want
to think about how much time I've could have saved by using it..

There is however the question of how to apply the result. Ambient occlusion
should of course only apply to ambient part of the light model.
Something like (1-AO) * AmbientColour

This is pretty straightforward to do if you use deferred rendering, if you
use a forward rendering it is a bit trickier.
I see two possibillities:
1. Use the AO-texture as input to the shader used in forward rendering. In
this case you must calculate texture coordinate for each  shaded
pixel(calculate per vertex and use the interpolator).

2. Deferr the ambient lighting part of the lighting equation.
    Write the result of diffuse and specular to a render target and ambient
color to another RT
    Multiply the ambient-RT with the result of the AO-pass and add this to
the Specular-Diffuse-Rendertarget

 If anyone got a another solution I would be very interrested in hearing
about it.

Best regards,
Andreas

2008/2/25, Art Tevs <[EMAIL PROTECTED]>:
>
> Hi Adrian,
>
> I do not think that a nodekit just for this purpose is
> usefull or needed.
>
> This kind of screen space algorithms can be perfectly
> described by the osgPPU. I really like this kind of
> effects and it seems that it is very straight forward
> to implement. I will try to create a .ppu file which
> can be easyly used with osgPPU to apply the SSAO onto
> your currently bounded camera (the same way as it is
> shown in the example of osgPPU for the blurring or
> hdr).
>
> The osgPPU will be released as developer/stable
> release soon, since I now get little bit more time to
> fight the last bugs away ;-)
>
>
> Best regards,
> Art
>
>
>
>
> --- "Adrian Egli OpenSceneGraph (3D)"
> <[EMAIL PROTECTED]> schrieb:
>
>
> > Hi Andreas,
> >
> > may you would be able to implement an opensource
> > nodekit for openscenegraph,
> > like osgShadow. This would be greate to get,
> > implementing twice similar
> > things are not so funny. if you would be able to add
> > Inigo algorithm this
> > would be really greate.
> >
> > /adrian
> >
> > 2008/2/25, Andreas Lindmark
> > <[EMAIL PROTECTED]>:
> > >
> > > Funny you should ask. :)
> > > Im currently doing a master thesis about ambient
> > occlusion, and I've
> > > implemented a type of screen space ambient
> > occlusion in OSG and GLSL. It is
> > > similar to the one you linked to but differs in
> > some important areas. My
> > > version is slower but I've been able to remove
> > almost all self-shadowing and
> > > it considers the distance between the shaded pixel
> > and the sampled pixel in
> > > eye space and not the only the difference in
> > depth.
> > > Im in the process of writing the report (in
> > English) and cleaning up the
> > > code but when this is done i can make it public if
> > anyone is interested.
> > > I have not tried to implement IƱigo's SSAO-method
> > in OSG but im confident
> > > that it should be fairly easy to do and it would
> > be significantly faster
> > > than my method.
> > >
> > > /Andreas Lindmark
> > >
> > > 2008/2/25, Adrian Egli OpenSceneGraph (3D)
> > <[EMAIL PROTECTED]>:
> > > >
> > > >
> > > > Hi all
> > > >
> > > > did someone still implemented this SSAO in OSG,
> > any demo?
> > > >
> > > >
> >
> http://rgba.scenesp.org/iq/computer/articles/ssao/ssao.htm
> > > > --
> > > > ********************************************
> > > > Adrian Egli
> > > > _______________________________________________
> > > > osg-users mailing list
> > > > [email protected]
> > > >
> > > >
> >
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> > > >
> > > >
> > >
> > > _______________________________________________
> > > osg-users mailing list
> > > [email protected]
> > >
> >
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> > >
> > >
> >
> >
> > --
> > ********************************************
> > Adrian Egli
> > > _______________________________________________
> > osg-users mailing list
> > [email protected]
> >
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> >
>
>
>
>
>       Lesen Sie Ihre E-Mails auf dem Handy.
> www.yahoo.de/go
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to