W3C home > Mailing lists > Public > public-css-archive@w3.org > April 2019

Re: [csswg-drafts] [css-easing-2] Complex easing/timing functions (#229)

From: VisibleCode via GitHub <sysbot+gh@w3.org>
Date: Mon, 29 Apr 2019 00:18:18 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-487427621-1556497097-sysbot+gh@w3.org>
That sort of normalization is pretty rough to pull off in a robust/understandable/easy to implement way.

The big issue we're up against here is that cubic beziers (and SVG paths) aren't really suited for defining easing functions, because they treat x and y _independently_.

This is good for drawing 2d shapes that are supposed to be able to overlap themselves in arbitrary ways. But for reasons that are pretty obvious above this is super awkward for applications where y is supposed to _depend_ on x, like for easing functions.

Honestly the ideal tool for this is something like a cubic hermite spline. Apart from being about as simple as you can get from an implementation perspective, they're friendlier to hand authoring than beziers are going to be. You'd just need to supplement them with a way to indicate instantaneous jumps in position/speed.

GitHub Notification of comment by visiblecode
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/229#issuecomment-487427621 using your GitHub account
Received on Monday, 29 April 2019 00:18:20 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:46 UTC