Skip to content

Instantly share code, notes, and snippets.

@behreajj
Last active November 10, 2021 03:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save behreajj/681933ecbf5b54e7e96ce1c90f37df54 to your computer and use it in GitHub Desktop.
Save behreajj/681933ecbf5b54e7e96ce1c90f37df54 to your computer and use it in GitHub Desktop.
HSL Gray
static float GrayHsl (in Color c)
{
return 0.5f * (Mathf.Max (c.r, c.g, c.b) +
Mathf.Min (c.r, c.g, c.b));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment