Class QuadTransformers

java.lang.Object
net.neoforged.neoforge.client.model.QuadTransformers

public final class QuadTransformers extends Object
A collection of IQuadTransformer implementations.
See Also:
  • Field Details

  • Constructor Details

    • QuadTransformers

      private QuadTransformers()
  • Method Details

    • empty

      public static IQuadTransformer empty()
      Returns a BakedQuad transformer that does nothing.
      Returns:
      a BakedQuad transformer that does nothing
    • applying

      public static IQuadTransformer applying(Transformation transform)
      Returns a new BakedQuad transformer that applies the specified Transformation.
      Returns:
      a new BakedQuad transformer that applies the specified Transformation
    • applyingLightmap

      public static IQuadTransformer applyingLightmap(int packedLight)
      Returns:
      A new BakedQuad transformer that applies the specified packed light value.
    • applyingLightmap

      public static IQuadTransformer applyingLightmap(int blockLight, int skyLight)
      Returns:
      A new BakedQuad transformer that applies the specified block and sky light values.
    • settingEmissivity

      public static IQuadTransformer settingEmissivity(int emissivity)
      Returns:
      A BakedQuad transformer that sets the lightmap to the given emissivity (0-15)
    • settingMaxEmissivity

      public static IQuadTransformer settingMaxEmissivity()
      Returns:
      A BakedQuad transformer that sets the lightmap to its max value
    • applyingColor

      public static IQuadTransformer applyingColor(int color)
      Parameters:
      color - The color in ARGB format.
      Returns:
      A BakedQuad transformer that sets the color to the specified value.
    • applyingColor

      public static IQuadTransformer applyingColor(int red, int green, int blue)
      This method supplies a default alpha value of 255 (no transparency)
      Parameters:
      red - The red value (0-255)
      green - The green value (0-255)
      blue - The blue value (0-255)
      Returns:
      A BakedQuad transformer that sets the color to the specified value.
    • applyingColor

      public static IQuadTransformer applyingColor(int alpha, int red, int green, int blue)
      Parameters:
      alpha - The alpha value (0-255)
      red - The red value (0-255)
      green - The green value (0-255)
      blue - The blue value (0-255)
      Returns:
      A BakedQuad transformer that sets the color to the specified value.
    • toABGR

      public static int toABGR(int argb)
      Converts an ARGB color to an ABGR color, as the commonly used color format is not the format colors end up packed into. This function doubles as its own inverse.
      Parameters:
      color - ARGB color
      Returns:
      ABGR color