-
Bug
-
Resolution: Not an Issue
-
P3
-
8
This code in ViewPainter can cause the scene to be rendered multiple times:
for (int i = 0; i < dirtyRegionContainer.size(); i++) {
// <snipped>
// Disable occlusion culling if depth buffer is enabled for the scene.
if (sceneState.getScene().getDepthBuffer()) {
doPaint(g, null);
} else {
doPaint(g, root.getRenderRoot(NODE_PATH, dirtyRegion, i, tx, projTx));
NODE_PATH.clear();
}
}
}
The line doPaint(g, null) should never be called more than once in ViewPainter. The check for getDepthBuffer() can be made once, outside the for loop.
for (int i = 0; i < dirtyRegionContainer.size(); i++) {
// <snipped>
// Disable occlusion culling if depth buffer is enabled for the scene.
if (sceneState.getScene().getDepthBuffer()) {
doPaint(g, null);
} else {
doPaint(g, root.getRenderRoot(NODE_PATH, dirtyRegion, i, tx, projTx));
NODE_PATH.clear();
}
}
}
The line doPaint(g, null) should never be called more than once in ViewPainter. The check for getDepthBuffer() can be made once, outside the for loop.
- relates to
-
JDK-8103124 Add better diagnostic and debug tools for dirty regions, culling, and overdraw
-
- Resolved
-