mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-26 09:35:28 +00:00
another approach
This commit is contained in:
parent
94e8855c8c
commit
7edaa50195
@ -997,9 +997,9 @@ void MWShadowTechnique::cull(osgUtil::CullVisitor& cv)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 1. Traverse main scene graph
|
// 1. Traverse main scene graph
|
||||||
cv.pushStateSet( _shadowRecievingPlaceholderStateSet.get() );
|
auto* shadowReceiverStateSet = vdd->getStateSet(cv.getTraversalNumber());
|
||||||
|
shadowReceiverStateSet->clear();
|
||||||
osg::ref_ptr<osgUtil::StateGraph> decoratorStateGraph = cv.getCurrentStateGraph();
|
cv.pushStateSet(shadowReceiverStateSet);
|
||||||
|
|
||||||
cullShadowReceivingScene(&cv);
|
cullShadowReceivingScene(&cv);
|
||||||
|
|
||||||
@ -1426,7 +1426,7 @@ void MWShadowTechnique::cull(osgUtil::CullVisitor& cv)
|
|||||||
|
|
||||||
if (numValidShadows>0)
|
if (numValidShadows>0)
|
||||||
{
|
{
|
||||||
decoratorStateGraph->setStateSet(selectStateSetForRenderingShadow(*vdd, cv.getTraversalNumber()));
|
selectStateSetForRenderingShadow(*vdd, cv.getTraversalNumber());
|
||||||
}
|
}
|
||||||
|
|
||||||
// OSG_NOTICE<<"End of shadow setup Projection matrix "<<*cv.getProjectionMatrix()<<std::endl;
|
// OSG_NOTICE<<"End of shadow setup Projection matrix "<<*cv.getProjectionMatrix()<<std::endl;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user