Comments (9)
Also waiting for the answer.
What C=100 means i your app? Do you make any normalization?
from iwanthue.
I am not really sure here, frankly. I have found in the wild at least 3 different bounds for the C parameter: 100, 134 and 180. So if someone wants to investigate a little bit to understand whether iwanthue implementation is correct or not, I'll be grateful.
from iwanthue.
I have looked at a code a long time ago and what I can say is:
- I don't recall that there is any normalization occuring for C. It is just the C range selector which is configured for a [0,100] range whereas it should be [0,~134].
- else the implementation seems correct to me
from iwanthue.
@emmanuel-ichbiah @michkowalczuk I have edited the range picker on the website to accept max chroma 134. Can you tell me whether this feels right, in which case I will also fix the color validation code in the npm package.
from iwanthue.
@emmanuel-ichbiah @michkowalczuk I have edited the range picker on the website to accept max chroma 134. Can you tell me whether this feels right, in which case I will also fix the color validation code in the npm package.
Seems perfect to me! Thank you!
from iwanthue.
Thanks @emmanuel-ichbiah. I cannot find any validation problem to accept cmax = 134 in the code of the npm package so I think I will leave it at that. Of course the all
preset is a bit misleading because its cmax is set to 100 but you can override it and I feel it will annoy people if I change it without forcing a breaking change.
from iwanthue.
I have looked at a code a long time ago and what I can say is:
- I don't recall that there is any normalization occuring for C. It is just the C range selector which is configured for a [0,100] range whereas it should be [0,~134].
- else the implementation seems correct to me
It's not such a simple thing...
Chroma maximum value depends on combination of Hue and Luminance , as you can find here and here.
There is no perfect solution here. The most correct solution seems to be that when selecting colors, it checks whether it is possible to convert the color to RGB for a given combination of l,c,h. You can read about color clamping for example here and here.
from iwanthue.
«Chroma maximum value depends on combination of Hue and Luminance»
I perfectly know this.
But if you restrain the C selector to a 0 - 100 range you, depending on your H and L range selection you will NOT get all possible colors for that H and L ranges.
Overall I agree that there are not many colors with a C > 100 but nevertheless the former implementation was misleading. It gave the impression that there were NONE.
from iwanthue.
former
It's just a theoretical considerations ;-) Regardless of what the Chroma value is the theoretical upper limit, iWantHue is a great tool. I appreciate your work!
from iwanthue.
Related Issues (20)
- build palette around pre-selected colours? HOT 1
- Theory page JavaScript seems to get stuck in a loop
- Getting many visually distinct colors with the same saturation and lightness is hard
- Edit manipulates wrong colour after ordering them
- Sort by multiple keys
- Not working at all on os/x sierra (chrome or safari) ? HOT 2
- Are we still maintained HOT 3
- Theory page seems to cause browser hang HOT 2
- "I Want Hue" online tool "diff" mode bug
- We really need to create a npm package for this
- Add presets & filters to npm package
- Check bugfix for diffSort
- NaN bug in Protanope distance calculations for RGB color 9549d0
- Recreating same palette again with same parameters - what is the seed for palette? HOT 5
- Suggestion: Add "Steps" and "Ultra Precision" to GUI
- Locks position not changed after changing sorting
- Add HSL values to each color.
- Suggestion: Incorporate background color and WCAG contrast annotations. HOT 1
- Accompanying paper HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from iwanthue.