Package com.mojang.blaze3d.systems
Class RenderSystem
java.lang.Object
com.mojang.blaze3d.systems.RenderSystem
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
(package private) static final record
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static String
private static GpuDevice
private static DynamicUniforms
private static GpuBuffer
private static double
(package private) static final org.slf4j.Logger
static final int
private static final org.joml.Vector3f
private static final org.joml.Matrix4fStack
static GpuTextureView
static GpuTextureView
private static final ArrayListDeque
<RenderSystem.GpuAsyncTask> private static final PipelineModifierStack
private static final AtomicLong
private static final AtomicBoolean
static final int
private static GpuBufferSlice
private static ProjectionType
private static GpuBuffer
private static Thread
private static GpuBufferSlice
private static ProjectionType
private static ScissorState
private static GpuBufferSlice
private static GpuBufferSlice
private static float
private static final GpuTextureView[]
private static final RenderSystem.AutoStorageIndexBuffer
private static final RenderSystem.AutoStorageIndexBuffer
private static final RenderSystem.AutoStorageIndexBuffer
static StencilTest
static final int
private static org.joml.Matrix4f
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic RenderPipeline
applyPipelineModifiers
(RenderPipeline pipeline) static void
static void
static void
bindDefaultUniforms
(RenderPass pRenderPass) private static IllegalStateException
static void
static void
static void
enableScissorForRenderTypeDraws
(int pX, int pY, int pWidth, int pHeight) static void
enableStencil
(StencilTest stencilTest) static void
static void
static void
flipFrame
(long pWindow, TracyFrameCapture pTracyFrameCapture) static String
static String
static GpuDevice
static DynamicUniforms
static GpuBuffer
static org.joml.Vector3f
static org.joml.Matrix4f
static org.joml.Matrix4fStack
static GpuBufferSlice
static ProjectionType
static GpuBuffer
static ScissorState
getSequentialBuffer
(VertexFormat.Mode pFormatMode) static GpuBufferSlice
static GpuBufferSlice
static float
static GpuTextureView
getShaderTexture
(int pId) static org.joml.Matrix4f
static TimeSource.NanoTimeSource
static void
initRenderer
(long pWindow, int pGlDebugVerbosity, boolean pSynchronous, BiFunction<ResourceLocation, ShaderType, String> pDefaultShaderSource, boolean pRenderDebugLabels) static void
static boolean
static boolean
static void
limitDisplayFPS
(int pFrameRateLimit) static void
lineWidth
(float pShaderLineWidth) private static void
static void
Neo: Pop the lastPipelineModifier
off the modifier stackstatic void
pushPipelineModifier
(ResourceKey<PipelineModifier> modifier) Neo: Push the providedPipelineModifier
to be applied to subsequent rendering.static void
queueFencedTask
(Runnable pTask) static void
renderWithPipelineModifier
(ResourceKey<PipelineModifier> modifier, Runnable renderTask) Neo: Run the providedRunnable
with the providedPipelineModifier
applied to the pipelines used by the rendering done in theRunnable
static void
static void
static void
static void
setErrorCallback
(org.lwjgl.glfw.GLFWErrorCallbackI p_69901_) static void
setGlobalSettingsUniform
(GpuBuffer pGlobalSettingsUniform) static void
setModelOffset
(float pX, float pY, float pZ) static void
setProjectionMatrix
(GpuBufferSlice pProjectionMatrixBuffer, ProjectionType pProjectionType) static void
setShaderFog
(GpuBufferSlice pShaderFog) static void
setShaderLights
(GpuBufferSlice pShaderLights) static void
setShaderTexture
(int pTextureId, GpuTextureView pTexture) static void
setTextureMatrix
(org.joml.Matrix4f p_254081_) static void
static void
setupOverlayColor
(GpuTextureView pTexture) static void
static GpuDevice
-
Field Details
-
LOGGER
static final org.slf4j.Logger LOGGER -
MINIMUM_ATLAS_TEXTURE_SIZE
public static final int MINIMUM_ATLAS_TEXTURE_SIZE- See Also:
-
PROJECTION_MATRIX_UBO_SIZE
public static final int PROJECTION_MATRIX_UBO_SIZE -
renderThread
-
DEVICE
-
lastDrawTime
private static double lastDrawTime -
projectionType
-
savedProjectionType
-
modelViewStack
private static final org.joml.Matrix4fStack modelViewStack -
textureMatrix
private static org.joml.Matrix4f textureMatrix -
TEXTURE_COUNT
public static final int TEXTURE_COUNT- See Also:
-
shaderTextures
-
shaderFog
-
shaderLightDirections
-
projectionMatrixBuffer
-
savedProjectionMatrixBuffer
-
modelOffset
private static final org.joml.Vector3f modelOffset -
shaderLineWidth
private static float shaderLineWidth -
apiDescription
-
pollEventsWaitStart
-
pollingEvents
-
QUAD_VERTEX_BUFFER
-
PENDING_FENCES
-
outputColorTextureOverride
-
outputDepthTextureOverride
-
globalSettingsUniform
-
dynamicUniforms
-
scissorStateForRenderTypeDraws
-
STENCIL_TEST
-
PIPELINE_MODIFIERS
-
-
Constructor Details
-
RenderSystem
public RenderSystem()
-
-
Method Details
-
initRenderThread
public static void initRenderThread() -
isOnRenderThread
public static boolean isOnRenderThread() -
assertOnRenderThread
public static void assertOnRenderThread() -
constructThreadException
-
pollEvents
private static void pollEvents() -
isFrozenAtPollEvents
public static boolean isFrozenAtPollEvents() -
flipFrame
-
limitDisplayFPS
public static void limitDisplayFPS(int pFrameRateLimit) -
setShaderFog
-
getShaderFog
-
setShaderLights
-
getShaderLights
-
lineWidth
public static void lineWidth(float pShaderLineWidth) -
getShaderLineWidth
public static float getShaderLineWidth() -
enableScissorForRenderTypeDraws
public static void enableScissorForRenderTypeDraws(int pX, int pY, int pWidth, int pHeight) -
disableScissorForRenderTypeDraws
public static void disableScissorForRenderTypeDraws() -
getScissorStateForRenderTypeDraws
-
enableStencil
-
disableStencil
public static void disableStencil() -
getBackendDescription
-
getApiDescription
-
initBackendSystem
-
initRenderer
public static void initRenderer(long pWindow, int pGlDebugVerbosity, boolean pSynchronous, BiFunction<ResourceLocation, ShaderType, String> pDefaultShaderSource, boolean pRenderDebugLabels) -
setErrorCallback
public static void setErrorCallback(org.lwjgl.glfw.GLFWErrorCallbackI p_69901_) -
setupDefaultState
public static void setupDefaultState() -
setupOverlayColor
-
teardownOverlayColor
public static void teardownOverlayColor() -
setShaderTexture
-
getShaderTexture
-
setProjectionMatrix
public static void setProjectionMatrix(GpuBufferSlice pProjectionMatrixBuffer, ProjectionType pProjectionType) -
setTextureMatrix
public static void setTextureMatrix(org.joml.Matrix4f p_254081_) -
resetTextureMatrix
public static void resetTextureMatrix() -
backupProjectionMatrix
public static void backupProjectionMatrix() -
restoreProjectionMatrix
public static void restoreProjectionMatrix() -
getProjectionMatrixBuffer
-
getModelViewMatrix
public static org.joml.Matrix4f getModelViewMatrix() -
getModelViewStack
public static org.joml.Matrix4fStack getModelViewStack() -
getTextureMatrix
public static org.joml.Matrix4f getTextureMatrix() -
getSequentialBuffer
public static RenderSystem.AutoStorageIndexBuffer getSequentialBuffer(VertexFormat.Mode pFormatMode) -
setGlobalSettingsUniform
-
getGlobalSettingsUniform
-
getProjectionType
-
getQuadVertexBuffer
-
setModelOffset
public static void setModelOffset(float pX, float pY, float pZ) -
resetModelOffset
public static void resetModelOffset() -
getModelOffset
public static org.joml.Vector3f getModelOffset() -
queueFencedTask
-
executePendingTasks
public static void executePendingTasks() -
getDevice
-
tryGetDevice
-
getDynamicUniforms
-
bindDefaultUniforms
-
pushPipelineModifier
Neo: Push the providedPipelineModifier
to be applied to subsequent rendering.Must be paired with a corresponding
popPipelineModifier()
call after flushing the used buffers -
popPipelineModifier
public static void popPipelineModifier()Neo: Pop the lastPipelineModifier
off the modifier stack -
renderWithPipelineModifier
public static void renderWithPipelineModifier(ResourceKey<PipelineModifier> modifier, Runnable renderTask) Neo: Run the providedRunnable
with the providedPipelineModifier
applied to the pipelines used by the rendering done in theRunnable
-
applyPipelineModifiers
-
ensurePipelineModifiersEmpty
@Internal public static void ensurePipelineModifiersEmpty()
-