Package com.mojang.blaze3d.systems
Class RenderSystem
java.lang.Object
com.mojang.blaze3d.systems.RenderSystem
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static String
private static boolean
private static double
(package private) static final org.slf4j.Logger
private static int
private static final int
private static org.joml.Matrix4f
private static final org.joml.Matrix4fStack
private static final AtomicLong
private static final AtomicBoolean
private static org.joml.Matrix4f
private static final ConcurrentLinkedQueue
<RenderCall> private static final Tesselator
private static Thread
private static org.joml.Matrix4f
private static VertexSorting
private static ShaderInstance
private static final float[]
private static final float[]
private static float
private static FogShape
private static float
private static float
private static float
private static final org.joml.Vector3f[]
private static float
private static final int[]
private static final RenderSystem.AutoStorageIndexBuffer
private static final RenderSystem.AutoStorageIndexBuffer
private static final RenderSystem.AutoStorageIndexBuffer
private static org.joml.Matrix4f
private static VertexSorting
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static void
private static void
private static void
_setShaderColor
(float pRed, float pGreen, float pBlue, float pAlpha) static void
_setShaderTexture
(int pShaderTexture, int pTextureId) static void
_setShaderTexture
(int pShaderTexture, ResourceLocation pTextureId) static void
activeTexture
(int pTexture) static void
static void
static void
static void
backupGlState
(GlStateBackup state) static void
static void
static void
bindTexture
(int pTexture) static void
bindTextureForSetup
(int pTexture) static void
blendEquation
(int pMode) static void
blendFunc
(int pSourceFactor, int pDestFactor) static void
blendFunc
(GlStateManager.SourceFactor pSourceFactor, GlStateManager.DestFactor pDestFactor) static void
blendFuncSeparate
(int pSourceFactor, int pDestFactor, int pSourceFactorAlpha, int pDestFactorAlpha) static void
blendFuncSeparate
(GlStateManager.SourceFactor pSourceFactor, GlStateManager.DestFactor pDestFactor, GlStateManager.SourceFactor pSourceFactorAlpha, GlStateManager.DestFactor pDestFactorAlpha) static void
clear
(int pMask, boolean pCheckError) static void
clearColor
(float pRed, float pGreen, float pBlue, float pAlpha) static void
clearDepth
(double pDepth) static void
clearStencil
(int pIndex) static void
colorMask
(boolean pRed, boolean pGreen, boolean pBlue, boolean pAlpha) private static IllegalStateException
static void
static void
deleteTexture
(int pTexture) static void
depthFunc
(int pDepthFunc) static void
depthMask
(boolean pFlag) static void
static void
static void
static void
static void
static void
static void
drawElements
(int pMode, int pCount, int pType) static void
static void
static void
static void
static void
static void
enableScissor
(int pX, int pY, int pWidth, int pHeight) static void
static void
flipFrame
(long pWindowId) static String
static String
static String
static org.joml.Matrix4f
static org.joml.Matrix4fStack
static org.joml.Matrix4f
getSequentialBuffer
(VertexFormat.Mode pFormatMode) static ShaderInstance
static float[]
static float[]
static float
static FogShape
static float
static float
static float
static float
static int
getShaderTexture
(int pShaderTexture) static void
static org.joml.Matrix4f
static VertexSorting
static void
glBindBuffer
(int pTarget, int pBuffer) static void
glBindVertexArray
(int pArray) static void
glBufferData
(int pTarget, ByteBuffer pData, int pUsage) static void
glDeleteBuffers
(int pBuffer) static void
glDeleteVertexArrays
(int pArray) static void
glGenBuffers
(Consumer<Integer> pBufferIdConsumer) static void
glGenVertexArrays
(Consumer<Integer> pArrayObjectIdConsumer) static void
glUniform1
(int pLocation, FloatBuffer pValue) static void
glUniform1
(int pLocation, IntBuffer pValue) static void
glUniform1i
(int pLocation, int pValue) static void
glUniform2
(int pLocation, FloatBuffer pValue) static void
glUniform2
(int pLocation, IntBuffer pValue) static void
glUniform3
(int pLocation, FloatBuffer pValue) static void
glUniform3
(int pLocation, IntBuffer pValue) static void
glUniform4
(int pLocation, FloatBuffer pValue) static void
glUniform4
(int pLocation, IntBuffer pValue) static void
glUniformMatrix2
(int pLocation, boolean pTranspose, FloatBuffer pValue) static void
glUniformMatrix3
(int pLocation, boolean pTranspose, FloatBuffer pValue) static void
glUniformMatrix4
(int pLocation, boolean pTranspose, FloatBuffer pValue) static TimeSource.NanoTimeSource
static void
initRenderer
(int pDebugVerbosity, boolean pSynchronous) static void
static boolean
static boolean
static boolean
static void
limitDisplayFPS
(int pFrameRateLimit) static void
lineWidth
(float pShaderLineWidth) static void
static int
static void
pixelStore
(int pParameterName, int pParameter) private static void
static void
polygonMode
(int pFace, int pMode) static void
polygonOffset
(float pFactor, float pUnits) static void
readPixels
(int pX, int pY, int pWidth, int pHeight, int pFormat, int pType, ByteBuffer pPixels) static void
recordRenderCall
(RenderCall pRenderCall) static void
renderCrosshair
(int pLineLength) static Tesselator
static void
static void
static void
restoreGlState
(GlStateBackup state) static void
static void
runAsFancy
(Runnable pFancyRunnable) Deprecated.static void
setErrorCallback
(org.lwjgl.glfw.GLFWErrorCallbackI p_69901_) static void
setProjectionMatrix
(org.joml.Matrix4f p_277884_, VertexSorting p_277702_) static void
setShader
(Supplier<ShaderInstance> pShaderSupplier) static void
setShaderColor
(float pRed, float pGreen, float pBlue, float pAlpha) static void
setShaderFogColor
(float pRed, float pGreen, float pBlue) static void
setShaderFogColor
(float pRed, float pGreen, float pBlue, float pAlpha) static void
setShaderFogEnd
(float pShaderFogEnd) static void
setShaderFogShape
(FogShape pShaderFogShape) static void
setShaderFogStart
(float pShaderFogStart) static void
setShaderGameTime
(long pTickTime, float pPartialTicks) static void
setShaderGlintAlpha
(double pShaderGlintAlpha) static void
setShaderGlintAlpha
(float pShaderGlintAlpha) static void
setShaderLights
(org.joml.Vector3f p_254155_, org.joml.Vector3f p_254006_) static void
setShaderTexture
(int pShaderTexture, int pTextureId) static void
setShaderTexture
(int pShaderTexture, ResourceLocation pTextureId) static void
setTextureMatrix
(org.joml.Matrix4f p_254081_) static void
setupDefaultState
(int pX, int pY, int pWidth, int pHeight) static void
setupGui3DDiffuseLighting
(org.joml.Vector3f p_253859_, org.joml.Vector3f p_253890_) static void
setupGuiFlatDiffuseLighting
(org.joml.Vector3f p_254419_, org.joml.Vector3f p_254483_) static void
setupLevelDiffuseLighting
(org.joml.Vector3f p_254489_, org.joml.Vector3f p_254541_) static void
setupOverlayColor
(int pTextureId, int pColor) static void
setupShaderLights
(ShaderInstance pInstance) static void
stencilFunc
(int pFunc, int pRef, int pMask) static void
stencilMask
(int pMask) static void
stencilOp
(int pSFail, int pDpFail, int pDpPass) static void
static void
texParameter
(int pTarget, int pParameterName, int pParameter) static void
viewport
(int pX, int pY, int pWidth, int pHeight)
-
Field Details
-
LOGGER
static final org.slf4j.Logger LOGGER -
recordingQueue
-
RENDER_THREAD_TESSELATOR
-
MINIMUM_ATLAS_TEXTURE_SIZE
private static final int MINIMUM_ATLAS_TEXTURE_SIZE- See Also:
-
renderThread
-
MAX_SUPPORTED_TEXTURE_SIZE
private static int MAX_SUPPORTED_TEXTURE_SIZE -
isInInit
private static boolean isInInit -
lastDrawTime
private static double lastDrawTime -
projectionMatrix
private static org.joml.Matrix4f projectionMatrix -
savedProjectionMatrix
private static org.joml.Matrix4f savedProjectionMatrix -
vertexSorting
-
savedVertexSorting
-
modelViewStack
private static final org.joml.Matrix4fStack modelViewStack -
modelViewMatrix
private static org.joml.Matrix4f modelViewMatrix -
textureMatrix
private static org.joml.Matrix4f textureMatrix -
shaderTextures
private static final int[] shaderTextures -
shaderColor
private static final float[] shaderColor -
shaderGlintAlpha
private static float shaderGlintAlpha -
shaderFogStart
private static float shaderFogStart -
shaderFogEnd
private static float shaderFogEnd -
shaderFogColor
private static final float[] shaderFogColor -
shaderFogShape
-
shaderLightDirections
private static final org.joml.Vector3f[] shaderLightDirections -
shaderGameTime
private static float shaderGameTime -
shaderLineWidth
private static float shaderLineWidth -
apiDescription
-
shader
-
pollEventsWaitStart
-
pollingEvents
-
-
Constructor Details
-
RenderSystem
public RenderSystem()
-
-
Method Details
-
initRenderThread
public static void initRenderThread() -
isOnRenderThread
public static boolean isOnRenderThread() -
isOnRenderThreadOrInit
public static boolean isOnRenderThreadOrInit() -
assertOnRenderThreadOrInit
public static void assertOnRenderThreadOrInit() -
assertOnRenderThread
public static void assertOnRenderThread() -
constructThreadException
-
recordRenderCall
-
pollEvents
private static void pollEvents() -
isFrozenAtPollEvents
public static boolean isFrozenAtPollEvents() -
flipFrame
public static void flipFrame(long pWindowId) -
replayQueue
public static void replayQueue() -
limitDisplayFPS
public static void limitDisplayFPS(int pFrameRateLimit) -
disableDepthTest
public static void disableDepthTest() -
enableDepthTest
public static void enableDepthTest() -
enableScissor
public static void enableScissor(int pX, int pY, int pWidth, int pHeight) -
disableScissor
public static void disableScissor() -
depthFunc
public static void depthFunc(int pDepthFunc) -
depthMask
public static void depthMask(boolean pFlag) -
enableBlend
public static void enableBlend() -
disableBlend
public static void disableBlend() -
blendFunc
public static void blendFunc(GlStateManager.SourceFactor pSourceFactor, GlStateManager.DestFactor pDestFactor) -
blendFunc
public static void blendFunc(int pSourceFactor, int pDestFactor) -
blendFuncSeparate
public static void blendFuncSeparate(GlStateManager.SourceFactor pSourceFactor, GlStateManager.DestFactor pDestFactor, GlStateManager.SourceFactor pSourceFactorAlpha, GlStateManager.DestFactor pDestFactorAlpha) -
blendFuncSeparate
public static void blendFuncSeparate(int pSourceFactor, int pDestFactor, int pSourceFactorAlpha, int pDestFactorAlpha) -
blendEquation
public static void blendEquation(int pMode) -
enableCull
public static void enableCull() -
disableCull
public static void disableCull() -
polygonMode
public static void polygonMode(int pFace, int pMode) -
enablePolygonOffset
public static void enablePolygonOffset() -
disablePolygonOffset
public static void disablePolygonOffset() -
polygonOffset
public static void polygonOffset(float pFactor, float pUnits) -
enableColorLogicOp
public static void enableColorLogicOp() -
disableColorLogicOp
public static void disableColorLogicOp() -
logicOp
-
activeTexture
public static void activeTexture(int pTexture) -
texParameter
public static void texParameter(int pTarget, int pParameterName, int pParameter) -
deleteTexture
public static void deleteTexture(int pTexture) -
bindTextureForSetup
public static void bindTextureForSetup(int pTexture) -
bindTexture
public static void bindTexture(int pTexture) -
viewport
public static void viewport(int pX, int pY, int pWidth, int pHeight) -
colorMask
public static void colorMask(boolean pRed, boolean pGreen, boolean pBlue, boolean pAlpha) -
stencilFunc
public static void stencilFunc(int pFunc, int pRef, int pMask) -
stencilMask
public static void stencilMask(int pMask) -
stencilOp
public static void stencilOp(int pSFail, int pDpFail, int pDpPass) -
clearDepth
public static void clearDepth(double pDepth) -
clearColor
public static void clearColor(float pRed, float pGreen, float pBlue, float pAlpha) -
clearStencil
public static void clearStencil(int pIndex) -
clear
public static void clear(int pMask, boolean pCheckError) -
setShaderFogStart
public static void setShaderFogStart(float pShaderFogStart) -
getShaderFogStart
public static float getShaderFogStart() -
setShaderGlintAlpha
public static void setShaderGlintAlpha(double pShaderGlintAlpha) -
setShaderGlintAlpha
public static void setShaderGlintAlpha(float pShaderGlintAlpha) -
getShaderGlintAlpha
public static float getShaderGlintAlpha() -
setShaderFogEnd
public static void setShaderFogEnd(float pShaderFogEnd) -
getShaderFogEnd
public static float getShaderFogEnd() -
setShaderFogColor
public static void setShaderFogColor(float pRed, float pGreen, float pBlue, float pAlpha) -
setShaderFogColor
public static void setShaderFogColor(float pRed, float pGreen, float pBlue) -
getShaderFogColor
public static float[] getShaderFogColor() -
setShaderFogShape
-
getShaderFogShape
-
setShaderLights
public static void setShaderLights(org.joml.Vector3f p_254155_, org.joml.Vector3f p_254006_) -
setupShaderLights
-
setShaderColor
public static void setShaderColor(float pRed, float pGreen, float pBlue, float pAlpha) -
_setShaderColor
private static void _setShaderColor(float pRed, float pGreen, float pBlue, float pAlpha) -
getShaderColor
public static float[] getShaderColor() -
drawElements
public static void drawElements(int pMode, int pCount, int pType) -
lineWidth
public static void lineWidth(float pShaderLineWidth) -
getShaderLineWidth
public static float getShaderLineWidth() -
pixelStore
public static void pixelStore(int pParameterName, int pParameter) -
readPixels
public static void readPixels(int pX, int pY, int pWidth, int pHeight, int pFormat, int pType, ByteBuffer pPixels) -
getString
-
getBackendDescription
-
getApiDescription
-
initBackendSystem
-
initRenderer
public static void initRenderer(int pDebugVerbosity, boolean pSynchronous) -
setErrorCallback
public static void setErrorCallback(org.lwjgl.glfw.GLFWErrorCallbackI p_69901_) -
renderCrosshair
public static void renderCrosshair(int pLineLength) -
getCapsString
-
setupDefaultState
public static void setupDefaultState(int pX, int pY, int pWidth, int pHeight) -
maxSupportedTextureSize
public static int maxSupportedTextureSize() -
glBindBuffer
public static void glBindBuffer(int pTarget, int pBuffer) -
glBindVertexArray
public static void glBindVertexArray(int pArray) -
glBufferData
-
glDeleteBuffers
public static void glDeleteBuffers(int pBuffer) -
glDeleteVertexArrays
public static void glDeleteVertexArrays(int pArray) -
glUniform1i
public static void glUniform1i(int pLocation, int pValue) -
glUniform1
-
glUniform2
-
glUniform3
-
glUniform4
-
glUniform1
-
glUniform2
-
glUniform3
-
glUniform4
-
glUniformMatrix2
-
glUniformMatrix3
-
glUniformMatrix4
-
setupOverlayColor
public static void setupOverlayColor(int pTextureId, int pColor) -
teardownOverlayColor
public static void teardownOverlayColor() -
setupLevelDiffuseLighting
public static void setupLevelDiffuseLighting(org.joml.Vector3f p_254489_, org.joml.Vector3f p_254541_) -
setupGuiFlatDiffuseLighting
public static void setupGuiFlatDiffuseLighting(org.joml.Vector3f p_254419_, org.joml.Vector3f p_254483_) -
setupGui3DDiffuseLighting
public static void setupGui3DDiffuseLighting(org.joml.Vector3f p_253859_, org.joml.Vector3f p_253890_) -
beginInitialization
public static void beginInitialization() -
finishInitialization
public static void finishInitialization() -
glGenBuffers
-
glGenVertexArrays
-
renderThreadTesselator
-
defaultBlendFunc
public static void defaultBlendFunc() -
runAsFancy
Deprecated. -
setShader
-
getShader
-
setShaderTexture
-
_setShaderTexture
-
setShaderTexture
public static void setShaderTexture(int pShaderTexture, int pTextureId) -
_setShaderTexture
public static void _setShaderTexture(int pShaderTexture, int pTextureId) -
getShaderTexture
public static int getShaderTexture(int pShaderTexture) -
setProjectionMatrix
-
setTextureMatrix
public static void setTextureMatrix(org.joml.Matrix4f p_254081_) -
resetTextureMatrix
public static void resetTextureMatrix() -
applyModelViewMatrix
public static void applyModelViewMatrix() -
backupProjectionMatrix
public static void backupProjectionMatrix() -
_backupProjectionMatrix
private static void _backupProjectionMatrix() -
restoreProjectionMatrix
public static void restoreProjectionMatrix() -
_restoreProjectionMatrix
private static void _restoreProjectionMatrix() -
getProjectionMatrix
public static org.joml.Matrix4f getProjectionMatrix() -
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) -
setShaderGameTime
public static void setShaderGameTime(long pTickTime, float pPartialTicks) -
getShaderGameTime
public static float getShaderGameTime() -
getVertexSorting
-
backupGlState
-
restoreGlState
-