use of org.terasology.rendering.dag.nodes.HazeNode in project Terasology by MovingBlocks.
the class WorldRendererImpl method addSkyNodes.
private void addSkyNodes(RenderGraph renderGraph) {
Node backdropNode = new BackdropNode(context);
renderGraph.addNode(backdropNode, "backdropNode");
FBOConfig intermediateHazeConfig = new FBOConfig(HazeNode.INTERMEDIATE_HAZE_FBO_URI, ONE_16TH_SCALE, FBO.Type.DEFAULT);
FBO intermediateHazeFbo = displayResolutionDependentFBOs.request(intermediateHazeConfig);
HazeNode intermediateHazeNode = new HazeNode(context, displayResolutionDependentFBOs.getGBufferPair().getLastUpdatedFbo(), intermediateHazeFbo);
renderGraph.addNode(intermediateHazeNode, "intermediateHazeNode");
FBOConfig finalHazeConfig = new FBOConfig(HazeNode.FINAL_HAZE_FBO_URI, ONE_32TH_SCALE, FBO.Type.DEFAULT);
FBO finalHazeFbo = displayResolutionDependentFBOs.request(finalHazeConfig);
HazeNode finalHazeNode = new HazeNode(context, intermediateHazeFbo, finalHazeFbo);
renderGraph.addNode(finalHazeNode, "finalHazeNode");
Node lastUpdatedGBufferClearingNode = renderGraph.findNode("engine:lastUpdatedGBufferClearingNode");
renderGraph.connect(lastUpdatedGBufferClearingNode, backdropNode, intermediateHazeNode, finalHazeNode);
}
Aggregations