Class ColorTypes.ARGB32

Enclosing class:
ColorTypes

public static final class ColorTypes.ARGB32 extends IntColorType.BlendingIntColorType
Colors encoded with the least significant 32 bits representing 4 8-bit channels: alpha, red, green, and blue.
  • Method Details

    • red

      @Contract(pure=true) public int red(int color)
    • green

      @Contract(pure=true) public int green(int color)
    • blue

      @Contract(pure=true) public int blue(int color)
    • toARGB32

      public int toARGB32(int color)
      Specified by:
      toARGB32 in class IntColorType
      Returns:
      the color, encoded as ColorTypes.ARGB32
    • fromARGB32

      public int fromARGB32(int color)
      Specified by:
      fromARGB32 in class IntColorType
      Returns:
      the provided ColorTypes.ARGB32 color, encoded as this color type
    • distance

      public double distance(int color1, int color2)
      Returns:
      the Euclidean distance between two colors in ARGB32 format, ignoring alpha