static @NotNull HSVLike fromRGB(@Range(from = 0x0, to = 0xff) final int red, @Range(from = 0x0, to = 0xff) final int green, @Range(from = 0x0, to = 0xff) final int blue) {
    final float r = red / 255.0f;
    final float g = green / 255.0f;
    final float b = blue / 255.0f;

    final float min = Math.min(r, Math.min(g, b));
    final float max = Math.max(r, Math.max(g, b)); // v
    final float delta = max - min;

    final float s;
    if (max != 0) {
      s = delta / max; // s
    } else {
      // r = g = b = 0
      s = 0;
    }
    if (s == 0) { // s = 0, h is undefined
      return new HSVLikeImpl(0, s, max);
    }

    float h;
    if (r == max) {
      h = (g - b) / delta; // between yellow & magenta
    } else if (g == max) {
      h = 2 + (b - r) / delta; // between cyan & yellow
    } else {
      h = 4 + (r - g) / delta; // between magenta & cyan
    }
    h *= 60; // degrees
    if (h < 0) {
      h += 360;
    }

    return new HSVLikeImpl(h / 360.0f, s, max);
  }
Creates a new HSVLike from the given red, green, and blue color components.

@param red red color component
@param green green color component
@param blue blue color component
@return a new HSVLike
@since 4.6.0
api/src/main/java/net/kyori/adventure/util/HSVLike.java