|
|
|
@ -114,6 +114,16 @@ public class Node extends Spatial implements Savable { |
|
|
|
|
|
|
|
|
|
child.setLightListRefresh(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
Spatial p = parent; |
|
|
|
|
while (p != null) { |
|
|
|
|
if (p.refreshFlags != 0) { |
|
|
|
|
return; //any refresh flag is sufficient, as each propagates to the root Node
|
|
|
|
|
} |
|
|
|
|
p.refreshFlags |= RF_CHILD_LIGHTLIST; |
|
|
|
|
p = p.parent; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@ -154,6 +164,9 @@ public class Node extends Spatial implements Savable { |
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
public void updateGeometricState(){ |
|
|
|
|
boolean somethingToRefresh = (refreshFlags != 0); |
|
|
|
|
if (!somethingToRefresh) return; |
|
|
|
|
|
|
|
|
|
if ((refreshFlags & RF_LIGHTLIST) != 0){ |
|
|
|
|
updateWorldLightList(); |
|
|
|
|
} |
|
|
|
@ -170,6 +183,7 @@ public class Node extends Spatial implements Savable { |
|
|
|
|
// a round-trip later on.
|
|
|
|
|
// NOTE 9/19/09
|
|
|
|
|
// Although it does save a round trip,
|
|
|
|
|
refreshFlags &= ~RF_CHILD_LIGHTLIST; |
|
|
|
|
for (Spatial child : children.getArray()) { |
|
|
|
|
child.updateGeometricState(); |
|
|
|
|
} |
|
|
|
@ -638,5 +652,4 @@ public class Node extends Spatial implements Savable { |
|
|
|
|
protected void breadthFirstTraversal(SceneGraphVisitor visitor, Queue<Spatial> queue) { |
|
|
|
|
queue.addAll(children); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|