Record Class RenderPipeline.Snippet

java.lang.Object
java.lang.Record
com.mojang.blaze3d.pipeline.RenderPipeline.Snippet
Enclosing class:
RenderPipeline

public static record RenderPipeline.Snippet(Optional<ResourceLocation> vertexShader, Optional<ResourceLocation> fragmentShader, Optional<ShaderDefines> shaderDefines, Optional<List<String>> samplers, Optional<List<RenderPipeline.UniformDescription>> uniforms, Optional<BlendFunction> blendFunction, Optional<DepthTestFunction> depthTestFunction, Optional<PolygonMode> polygonMode, Optional<Boolean> cull, Optional<Boolean> writeColor, Optional<Boolean> writeAlpha, Optional<Boolean> writeDepth, Optional<LogicOp> colorLogic, Optional<VertexFormat> vertexFormat, Optional<VertexFormat.Mode> vertexFormatMode) extends Record
  • Field Details

    • vertexShader

      private final Optional<ResourceLocation> vertexShader
      The field for the vertexShader record component.
    • fragmentShader

      private final Optional<ResourceLocation> fragmentShader
      The field for the fragmentShader record component.
    • shaderDefines

      private final Optional<ShaderDefines> shaderDefines
      The field for the shaderDefines record component.
    • samplers

      private final Optional<List<String>> samplers
      The field for the samplers record component.
    • uniforms

      The field for the uniforms record component.
    • blendFunction

      private final Optional<BlendFunction> blendFunction
      The field for the blendFunction record component.
    • depthTestFunction

      private final Optional<DepthTestFunction> depthTestFunction
      The field for the depthTestFunction record component.
    • polygonMode

      private final Optional<PolygonMode> polygonMode
      The field for the polygonMode record component.
    • cull

      private final Optional<Boolean> cull
      The field for the cull record component.
    • writeColor

      private final Optional<Boolean> writeColor
      The field for the writeColor record component.
    • writeAlpha

      private final Optional<Boolean> writeAlpha
      The field for the writeAlpha record component.
    • writeDepth

      private final Optional<Boolean> writeDepth
      The field for the writeDepth record component.
    • colorLogic

      private final Optional<LogicOp> colorLogic
      The field for the colorLogic record component.
    • vertexFormat

      private final Optional<VertexFormat> vertexFormat
      The field for the vertexFormat record component.
    • vertexFormatMode

      private final Optional<VertexFormat.Mode> vertexFormatMode
      The field for the vertexFormatMode record component.
  • Constructor Details

  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • vertexShader

      public Optional<ResourceLocation> vertexShader()
      Returns the value of the vertexShader record component.
      Returns:
      the value of the vertexShader record component
    • fragmentShader

      public Optional<ResourceLocation> fragmentShader()
      Returns the value of the fragmentShader record component.
      Returns:
      the value of the fragmentShader record component
    • shaderDefines

      public Optional<ShaderDefines> shaderDefines()
      Returns the value of the shaderDefines record component.
      Returns:
      the value of the shaderDefines record component
    • samplers

      public Optional<List<String>> samplers()
      Returns the value of the samplers record component.
      Returns:
      the value of the samplers record component
    • uniforms

      Returns the value of the uniforms record component.
      Returns:
      the value of the uniforms record component
    • blendFunction

      public Optional<BlendFunction> blendFunction()
      Returns the value of the blendFunction record component.
      Returns:
      the value of the blendFunction record component
    • depthTestFunction

      public Optional<DepthTestFunction> depthTestFunction()
      Returns the value of the depthTestFunction record component.
      Returns:
      the value of the depthTestFunction record component
    • polygonMode

      public Optional<PolygonMode> polygonMode()
      Returns the value of the polygonMode record component.
      Returns:
      the value of the polygonMode record component
    • cull

      public Optional<Boolean> cull()
      Returns the value of the cull record component.
      Returns:
      the value of the cull record component
    • writeColor

      public Optional<Boolean> writeColor()
      Returns the value of the writeColor record component.
      Returns:
      the value of the writeColor record component
    • writeAlpha

      public Optional<Boolean> writeAlpha()
      Returns the value of the writeAlpha record component.
      Returns:
      the value of the writeAlpha record component
    • writeDepth

      public Optional<Boolean> writeDepth()
      Returns the value of the writeDepth record component.
      Returns:
      the value of the writeDepth record component
    • colorLogic

      public Optional<LogicOp> colorLogic()
      Returns the value of the colorLogic record component.
      Returns:
      the value of the colorLogic record component
    • vertexFormat

      public Optional<VertexFormat> vertexFormat()
      Returns the value of the vertexFormat record component.
      Returns:
      the value of the vertexFormat record component
    • vertexFormatMode

      public Optional<VertexFormat.Mode> vertexFormatMode()
      Returns the value of the vertexFormatMode record component.
      Returns:
      the value of the vertexFormatMode record component