Last active
November 10, 2021 03:16
-
-
Save behreajj/681933ecbf5b54e7e96ce1c90f37df54 to your computer and use it in GitHub Desktop.
HSL Gray
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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