Package foundry.veil.render.wrapper
Class DeferredShaderStateCache
java.lang.Object
foundry.veil.render.wrapper.DeferredShaderStateCache
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.client.renderer.ShaderInstancegetShader(net.minecraft.client.renderer.ShaderInstance shaderInstance) Retrieves the shader that should be used if using defered renderingbooleansetupRenderState(@Nullable net.minecraft.client.renderer.ShaderInstance shaderInstance) Sets up the render state for the specified shader instance.
-
Constructor Details
-
DeferredShaderStateCache
public DeferredShaderStateCache()
-
-
Method Details
-
setupRenderState
public boolean setupRenderState(@Nullable @Nullable net.minecraft.client.renderer.ShaderInstance shaderInstance) Sets up the render state for the specified shader instance.- Parameters:
shaderInstance- The shader to set the render state for- Returns:
- Whether the state was handled and set
-
getShader
@Contract("null -> null") public net.minecraft.client.renderer.ShaderInstance getShader(net.minecraft.client.renderer.ShaderInstance shaderInstance) Retrieves the shader that should be used if using defered rendering- Parameters:
shaderInstance- The shader to get the render state for- Returns:
- The shader to use
-