Plans for future development
Hi, this library was pointed out to me while I am looking into [rewriting the color modules of p5.js](https://github.com/processing/p5.js/issues/7018) which the initial plan is to use color.js as a backing dependency, however what you have implemented here is really exciting and I am looking into using this instead of color.js.
There are several things that we need for p5.js that are not currently supported and I would like to know what your thoughts are in terms of implementing them in @texel/color, whether they are not planned to be supported or something that @texel/color would like to have. I may have some misunderstanding around colors so do point out if anything don't make sense here.
* It seems CIE colors are not supported by design however the CSS spec's `lab()` and `lch()` functions are both in CIE color space which we like to support if possible. If the intention is to not support CIE colors at all then it leads to the next item.
* Is there plan to have support for user extending @texel/color to provide custom defined color spaces? Or is that already supported in some way?
* Is there plan to support color interpolation such as the one [color.js have](https://colorjs.io/docs/interpolation) that can perform interpolation in specific color space?
* Serialization and deserialization support I can see are still WIP but is the intention to not support most/all of CSS specs? eg. for deserialization both `rgb(0, 128, 255)` and `rgb(0 128 255)` are valid and supported CSS strings but only the former works, color words such as `green` also does not work, alpha deserialization also does not work; for serialization, `hsl` seems to be serialized into a `color(okhsl)` string instead which have less support in CSS than the native `hsl()` function.
Depending on what the plan for this project is, p5.js can possibly help with providing some implementation support to implement some of the above since if we were to use @texel/color as the backing dependency of our color module, we will need to implement them anyway so I feel it's much better to do it here instead.
Really look forward to see what comes for the rest of the project!
2 条评论