chroma.js icon indicating copy to clipboard operation
chroma.js copied to clipboard

Adding alpha functionality to bezier interpolation

Open FaithForHumans opened this issue 4 years ago • 1 comments

FaithForHumans avatar Sep 19 '19 19:09 FaithForHumans

Your implementation is wrong for 5 points, those are not the results.

Note in all cases, the alpha and not alpha tests match except the last 2 digits on the Hex values. In your pull request, the 5-point solution does not.

Also you have replaced the n-degree method with a hard-coded 4-degree one, therefore failing for anything greater than that.

See this for a proper implementation of n-degree Bezier: https://github.com/regorxxx/chroma.js/commit/48a86d2163a42c860861d9ad1aff44860a04b276

regorxxx avatar Nov 07 '23 23:11 regorxxx