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

add a color name library, display it in color picker #10935

Closed

Conversation

aurelienpierre
Copy link
Member

@aurelienpierre aurelienpierre commented Jan 20, 2022

This has been requested by several color-disabled people who wanted to check the color of surfaces to ensure their validity compared to the rest of the population.

Screenshot_20220120_184116

We split the visible gamut in 15 hues × 4 lightnesses. Colors are identified coarsely. Colors should have L < 100 % meaning they should be reflective.

We also add average skin tones at ~80% confidence for Kurdish, Chinese, Thai, Caucasian, African-American and Mexican people. The skin tones detection needs proper L scaling, which is 44 to 48 % for African and 58 to 64 % for all others. Of course, neutral white-balance is of the essence here. This is not an ethnicity detection so one skin tone can be detected as belonging to more than one ethnicity, given that skin gamuts overlap greatly between ethnicities (see ref 1 below for graphs).

Reference :

  1. XIAO, Kaida, YATES, Julian M., ZARDAWI, Faraedon, et al.
    Characterising the variations in ethnic skin colours: a new calibrated data base for human skin.
    Skin Research and Technology, 2017, vol. 23, no 1, p. 21-29.
    https://onlinelibrary.wiley.com/doi/pdf/10.1111/srt.12295
    Sample : 187 caucasian, 202 chinese, 145 kurdish and 426 thai.

  2. DE RIGAL, Jean, DES MAZIS, Isabelle, DIRIDOLLOU, Stephane, et al.
    The effect of age on skin color and color heterogeneity in four ethnic groups.
    Skin Research and Technology, 2010, vol. 16, no 2, p. 168-178.
    https://pubmed.ncbi.nlm.nih.gov/20456097/
    Sample : 121 african-american, 64 mexican.
    Note : the data have been read on the graph and are inaccurate and std is majorated.
    The original authors have been contacted to get the tabulated, accurate data,
    but the main author is retired, co-authors have changed jobs, and the L'Oréal head of R&D
    did not respond. So the values here are given for what it's worth.

@TurboGit TurboGit added this to the 4.0 milestone Jan 20, 2022
@TurboGit TurboGit added feature: new new features to add scope: UI user interface and interactions labels Jan 20, 2022
@TurboGit TurboGit added documentation-pending a documentation work is required release notes: pending labels Feb 2, 2022
@TurboGit
Copy link
Member

TurboGit commented Feb 2, 2022

Seems like there is an issue with all patches without color (white, shade of grey....). See screen shot, I have selected the white patch, it tells me that it is "violet".

Capture d’écran de 2022-02-02 11-19-25

For the grey above it tells me it is : "deep sky blue", the RGB values are 163, 167, 169.

Copy link
Member

@TurboGit TurboGit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Issues with white/grey patches.

@aurelienpierre
Copy link
Member Author

The thing is we only read hue and lightness. We don't care about chroma. I could probably add a chroma check for low chroma vs. high chroma, but we already have 60 colors in the lib, I'm reluctant to also discretize chroma to end up with 120 or 240 colors to input.

@TurboGit
Copy link
Member

TurboGit commented Feb 2, 2022

I understand, but this is about helping people working with colors by having the right color name written. If for all color without much chroma we issue a wrong and misleading name I think we fail the initial goal :) So I would either:

  • not display a name when there is no chroma detected
  • have the code update to take chroma into account

Or any better idea...

@aurelienpierre
Copy link
Member Author

I think outputing "grey" if chroma < threshold is the easiest way for now.

@TurboGit
Copy link
Member

@aurelienpierre : I've added the "grey" and I have moved the code into a C file avoid all in header. Merged manually.

@TurboGit TurboGit closed this Feb 23, 2022
@elstoc elstoc added documentation-complete needed documentation is merged in dtdocs and removed documentation-pending a documentation work is required labels Apr 27, 2022
@aurelienpierre aurelienpierre deleted the color-names branch December 12, 2022 00:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation-complete needed documentation is merged in dtdocs feature: new new features to add scope: UI user interface and interactions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants