Class DeferredShaderStateCache

java.lang.Object
foundry.veil.render.wrapper.DeferredShaderStateCache

@Internal public class DeferredShaderStateCache extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.client.renderer.ShaderInstance
    getShader(net.minecraft.client.renderer.ShaderInstance shaderInstance)
    Retrieves the shader that should be used if using defered rendering
    boolean
    setupRenderState(@Nullable net.minecraft.client.renderer.ShaderInstance shaderInstance)
    Sets up the render state for the specified shader instance.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 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