Class FrameGraphSetupEvent
java.lang.Object
net.neoforged.bus.api.Event
net.neoforged.neoforge.client.event.FrameGraphSetupEvent
public final class FrameGraphSetupEvent
extends net.neoforged.bus.api.Event
Fired when the frame graph is set up at the start of level rendering, right before
the vanilla frame passes are set up.
This event is not cancellable.
This event is fired on the main Forge event bus, only on the logical client.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final com.mojang.blaze3d.framegraph.FrameGraphBuilder
private final net.minecraft.client.Camera
private final net.minecraft.client.DeltaTracker
private boolean
private final net.minecraft.client.renderer.culling.Frustum
private final org.joml.Matrix4f
private final net.minecraft.util.profiling.ProfilerFiller
private final org.joml.Matrix4f
private final com.mojang.blaze3d.resource.RenderTargetDescriptor
private final net.minecraft.client.renderer.LevelTargetBundle
-
Constructor Summary
ConstructorsConstructorDescriptionFrameGraphSetupEvent
(com.mojang.blaze3d.framegraph.FrameGraphBuilder builder, net.minecraft.client.renderer.LevelTargetBundle targets, com.mojang.blaze3d.resource.RenderTargetDescriptor renderTargetDescriptor, net.minecraft.client.renderer.culling.Frustum frustum, net.minecraft.client.Camera camera, org.joml.Matrix4f modelViewMatrix, org.joml.Matrix4f projectionMatrix, net.minecraft.client.DeltaTracker deltaTracker, net.minecraft.util.profiling.ProfilerFiller profiler) -
Method Summary
Modifier and TypeMethodDescriptionvoid
Enables the entity outline post-processing shader regardless of any entities having active outlinesnet.minecraft.client.Camera
Returns the activeCamera
.net.minecraft.client.DeltaTracker
Returns theDeltaTracker
.com.mojang.blaze3d.framegraph.FrameGraphBuilder
Returns theFrameGraphBuilder
used to set up the frame graph.net.minecraft.client.renderer.culling.Frustum
Returns the culling frustum.org.joml.Matrix4f
Returns the model view matrix.net.minecraft.util.profiling.ProfilerFiller
Returns the active profiler.org.joml.Matrix4f
Returns the projection matrix.com.mojang.blaze3d.resource.RenderTargetDescriptor
Returns the render target descriptor to use for creating full-screen render targets.net.minecraft.client.renderer.LevelTargetBundle
Returns the render targets used during level rendering.boolean
Returns whether the entity outline post-processing shader will be enabled regardless of entities using it.
-
Field Details
-
builder
private final com.mojang.blaze3d.framegraph.FrameGraphBuilder builder -
targets
private final net.minecraft.client.renderer.LevelTargetBundle targets -
renderTargetDescriptor
private final com.mojang.blaze3d.resource.RenderTargetDescriptor renderTargetDescriptor -
frustum
private final net.minecraft.client.renderer.culling.Frustum frustum -
camera
private final net.minecraft.client.Camera camera -
modelViewMatrix
private final org.joml.Matrix4f modelViewMatrix -
projectionMatrix
private final org.joml.Matrix4f projectionMatrix -
deltaTracker
private final net.minecraft.client.DeltaTracker deltaTracker -
profiler
private final net.minecraft.util.profiling.ProfilerFiller profiler -
enableOutline
private boolean enableOutline
-
-
Constructor Details
-
FrameGraphSetupEvent
@Internal public FrameGraphSetupEvent(com.mojang.blaze3d.framegraph.FrameGraphBuilder builder, net.minecraft.client.renderer.LevelTargetBundle targets, com.mojang.blaze3d.resource.RenderTargetDescriptor renderTargetDescriptor, net.minecraft.client.renderer.culling.Frustum frustum, net.minecraft.client.Camera camera, org.joml.Matrix4f modelViewMatrix, org.joml.Matrix4f projectionMatrix, net.minecraft.client.DeltaTracker deltaTracker, net.minecraft.util.profiling.ProfilerFiller profiler)
-
-
Method Details
-
getFrameGrapBuilder
public com.mojang.blaze3d.framegraph.FrameGraphBuilder getFrameGrapBuilder()Returns theFrameGraphBuilder
used to set up the frame graph.- Returns:
- the
FrameGraphBuilder
used to set up the frame graph
-
getTargetBundle
public net.minecraft.client.renderer.LevelTargetBundle getTargetBundle()Returns the render targets used during level rendering.- Returns:
- the render targets used during level rendering
-
getRenderTargetDescriptor
public com.mojang.blaze3d.resource.RenderTargetDescriptor getRenderTargetDescriptor()Returns the render target descriptor to use for creating full-screen render targets.- Returns:
- the render target descriptor to use for creating full-screen render targets
-
getFrustum
public net.minecraft.client.renderer.culling.Frustum getFrustum()Returns the culling frustum.- Returns:
- the culling frustum
-
getCamera
public net.minecraft.client.Camera getCamera()Returns the activeCamera
.- Returns:
- the active
Camera
-
getModelViewMatrix
public org.joml.Matrix4f getModelViewMatrix()Returns the model view matrix.- Returns:
- the model view matrix
-
getProjectionMatrix
public org.joml.Matrix4f getProjectionMatrix()Returns the projection matrix.- Returns:
- the projection matrix
-
getDeltaTracker
public net.minecraft.client.DeltaTracker getDeltaTracker()Returns theDeltaTracker
.- Returns:
- the
DeltaTracker
-
getProfiler
public net.minecraft.util.profiling.ProfilerFiller getProfiler()Returns the active profiler.- Returns:
- the active profiler
-
enableOutlineProcessing
public void enableOutlineProcessing()Enables the entity outline post-processing shader regardless of any entities having active outlines -
isOutlineProcessingEnabled
public boolean isOutlineProcessingEnabled()Returns whether the entity outline post-processing shader will be enabled regardless of entities using it.- Returns:
- whether the entity outline post-processing shader will be enabled regardless of entities using it
-