RFR: 8372203: Piecewise linear easing function [v4]
Michael Strauß
mstrauss at openjdk.org
Wed Nov 26 23:04:51 UTC 2025
On Wed, 26 Nov 2025 22:39:25 GMT, Kevin Rushforth <kcr at openjdk.org> wrote:
>> The answer to this question depends on what you mean by "need to be sorted". It's certainly possible to specify control points in any order, but the algorithm won't sort them. Instead, it modifies their input progress values (X coordinate) such that it never decreases. Here's the relevant part of the [specification](https://drafts.csswg.org/css-easing/#the-linear-easing-function):
>>
>>> If any [control point](https://drafts.csswg.org/css-easing/#linear-control-point) has an [input progress value](https://drafts.csswg.org/css-easing/#easing-function-input-progress-value) that is less than the input progress value of any preceding control point, set its input progress value to the largest input progress value of any preceding control point.
>
> Do you think it is worth adding similar language here about what the behavior is if an input progress value is less than any preceding input progress values?
That's a good idea, I've added a paragraph that explains the behavior.
-------------
PR Review Comment: https://git.openjdk.org/jfx/pull/1977#discussion_r2566684888
More information about the openjfx-dev
mailing list