Hi, Dario, LispSM is setup by default to cast shadows using light space backfacing polygons. That approach works well if models are closed and build with face culling in mind. If your model does not utilize cull faces (and your truck looks like that case), all front polygons will cast shadows. So the artifact you see is false self shadowing on front polygons. To work around that you will have to switch the sign of polygon offset factors and maybe further tweak polygon offset factors magnitude if your field of view gets big. You will find current polygon offset values in StandardShadowMap setup code. There is a method to set new polygon offset for the technique.
PS: I highly recommend reading some papers on principles of ShadowMaping. There is a Mark Kilkgard presentation on the web that explains many of the problems. Cheers, Wojtek Lewandowski 2012/8/28 Dario Minieri <[email protected]> > Hi! > > Nice to hear for the new your technique, I will try today checking the > svn. Is a ShadowMap tech, so the shaders are the same of > StandardShadowMap.cpp file? > > Meantime, I attach a debug shadow snapshot with CAST and NOCAST setted on > terrain. I'm not sure to understand well the result...the artifacts are the > same in both cases, but the depth calculation seems to be different to > me...You can see some specific stuffs? > > Thanks again for your suggestions. > > Best regards > > > robertosfield wrote: > > Hi Dario, > > > > On 27 August 2012 17:13, Dario Minieri <> wrote: > > > > > I've tried to use the CASTS_SHADOW_TRAVERSAL_MASK on my terrain but > the final result is pretty the same. > > > > > > Code: > > > GfxTerr->setNodeMask(m_GfxTerr->getNodeMask() & > ~CASTS_SHADOW_TRAVERSAL_MASK); > > > > > > > Run the debug shadow view to see if it's taking into account the terrain. > > > > Or... just try the ViewDependentShadowMap technique that now is > > available in svn/trunk. This new technique is more robust than LispSM > > and offers similar functionality w.r.t projections. It may or may not > > solve your problem, but as I'm the author of this particular technique > > I have a better chance of understand and helping address the issues. > > I'm not the author or or the implementator the OSG's LispSM technique > > so am a bit of disadvantage here. > > > > Robert. > > _______________________________________________ > > osg-users mailing list > > > > > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > > > ------------------ > > Post generated by Mail2Forum > > > ------------------ > Read this topic online here: > http://forum.openscenegraph.org/viewtopic.php?p=49608#49608 > > > > > _______________________________________________ > 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

