Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implemented a luma() function call #591

Closed
wants to merge 1 commit into from
Closed

Implemented a luma() function call #591

wants to merge 1 commit into from

Conversation

qix
Copy link

@qix qix commented Jan 23, 2012

Deciding whether to use white/black text on top of a given background color is much better decided using the backgrounds "luma" rather than "lightness". Luma is a better measure of the intensity of the light, since it differentiates between colors that we do not see as well (30% red, 59% green, 11% blue).

@sanford
Copy link

sanford commented Mar 11, 2012

+1 would love to see this get added

@Synchro
Copy link
Member

Synchro commented Mar 23, 2012

Yes! This would be perfect to use with my #730 contrast function, which does indeed use lightness for this exact purpose.

Edit: I did't see your code attached, duh, sorry.

@Synchro Synchro mentioned this pull request Mar 23, 2012
@lukeapage
Copy link
Member

A different implementation of luma has been added.

@lukeapage lukeapage closed this Aug 12, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants