[osg-users] osgShadow 3.6.3
OpenSceneGraph Users
osg-users at lists.openscenegraph.org
Tue Feb 18 04:55:32 PST 2020
Hi,
We are trying to test the shadows using OSG, We have multiple lights, but
for now we are playing with only one light, a point source light type. We
are some weird effects, the shadows are cut, a mirror scene as shadow
behind the light. See the video.
https://www.youtube.com/watch?v=hyFBX0jGjaw
osg::ref_ptr<osgShadow::ShadowedScene> shadowedScene = new
osgShadow::ShadowedScene;
shadowedScene->getShadowSettings()->setLightNum(1);
shadowedScene->setReceivesShadowTraversalMask(GetShadowNodeMask());
shadowedScene->setCastsShadowTraversalMask(GetShadowNodeMask());
osg::ref_ptr<osgShadow::SoftShadowMap> st = new osgShadow::SoftShadowMap;
st->clearShaderList();
st->setAmbientBias(osg::Vec2(0.5,1.0 - 0.5));
shadowedScene->setShadowTechnique(st.get());
view->addChild(shadowedScene);
shadowedScene->addChild(scene);
// Set the Scene Data
mViewer->setSceneData(view);
Any points that you may have, might help us.
Does osgShadow supports multiple lights?
Greetings,
Catalin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20200218/6f034770/attachment.html>
More information about the osg-users
mailing list