public Color RandomSaturated(Color rgbColor) { float myH, myS, myV; ColorConvert.RGBToHSV(rgbColor, out myH, out myS, out myV); Color returnColor = ColorConvert.HSVToRGB(myH, Random.Range(.5f, 1f), Random.Range(.5f, 1f)); return(returnColor); }
public Color Desaturate(Color rgbColor, float saturation) { float myH, myS, myV; ColorConvert.RGBToHSV(rgbColor, out myH, out myS, out myV); Color returnColor = ColorConvert.HSVToRGB(myH, myS * saturation, myV); return(returnColor); }
public Color GoldenRatioColor(Color rgbColor) { float myH, myS, myV; ColorConvert.RGBToHSV(rgbColor, out myH, out myS, out myV); float goldH = myH + 0.618033988749895f; goldH = (goldH % 1f); Color returnColor = ColorConvert.HSVToRGB(goldH, myS, myV); return(returnColor); }