mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-21 06:39:42 +00:00
Fix bounds calculation for addLight to a transform node
This commit is contained in:
parent
93cc08a09c
commit
e1c7165bfb
1 changed files with 3 additions and 1 deletions
|
@ -55,7 +55,9 @@ namespace SceneUtil
|
|||
{
|
||||
osg::ComputeBoundsVisitor computeBound;
|
||||
computeBound.setTraversalMask(~partsysMask);
|
||||
node->accept(computeBound);
|
||||
// We want the bounds of all children of the node, ignoring the node's local transformation
|
||||
// So do a traverse(), not accept()
|
||||
computeBound.traverse(*node);
|
||||
|
||||
// PositionAttitudeTransform seems to be slightly faster than MatrixTransform
|
||||
osg::ref_ptr<SceneUtil::PositionAttitudeTransform> trans(new SceneUtil::PositionAttitudeTransform);
|
||||
|
|
Loading…
Reference in a new issue