-
Notifications
You must be signed in to change notification settings - Fork 719
[css-transforms-1] What is the computed value of a in the middle of a layout dependent matrix decomposed interpolation?
#2854
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
From @shans on October 19, 2017 0:6 We definitely can't depend on layout to produce computed styles. I think something like your blend suggestion makes sense. Flagging this for discussion with the Houdini TF. |
From @css-meeting-bot on November 9, 2017 18:42 The Working Group just discussed
The full IRC log of that discussion |
Allow checks which skip a prefix, as needed for proper behavior in TransformOperations::BlendRemainingByUsingMatrixInterpolation(). This method will now only create InterpolatedTransformationOperations which are actually box-size dependent (as originally intended) ans create a matrix otherwise. Add a DCHECK for this property. Note that the interpolation defined in the css-transforms-1/2 specs assume that transform styles are calculated after layout, with matrix interpolation always producing a Matrix3DTransformOperation. As style is calculated before layout, this isn't possible in cases where the inputs to matrix interpolation are layout-dependent, so we have InterpolatedTransformOperation to defer interpolation in these cases. There is a currently CSSWG resolution to spec this behavior and give InterpolatedTransformOperation a defined serialization, having interpolation return a matrix as per the current spec where possible (the inputs of matrix interpolation are layout-independent) and an interpolated operation otherwise (where the current spec is inconsistent). The added DCHECK enforces this behavior. Resolution: w3c/csswg-drafts#2854 This is to prepare for using DependsOnBoxSize for invalidation of compositor animations, enabling acceleration of percent-containing transform. Design Doc: https://docs.google.com/document/d/1zgr5CHRMpvlqodn1e0eM9J3MjL2eEMfAHrHsZUK7gMM/ Bug: 389359 Change-Id: I2302546225ac52f47104d2dd77b02f874d2f6ef8 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2432194 Reviewed-by: Kevin EllisReviewed-by: Ian Vollick Commit-Queue: George Steel Cr-Commit-Position: refs/heads/master@{#813278}
@tabatkins Edits checked in, please look them over and close out the issue if they're acceptable to resolve this issue? |
Yeah, this'll need some edits in Transforms to specify that it's used, but |
From @alancutter on July 6, 2017 5:4
The
syntax enables custom properties to animate like thetransform
property.One quirk of
transform
is that the serialisation procedure requires layout information in order to turn percentages of the element's box dimensions into a matrix.Unfortunately this procedure requires layout information to turn an animation between
translateX(100%)
androtate(45deg)
into a single matrix. There is currently no way of representing such a value in CSS independent of what the layout is. You would need something likeblend(translateX(100%), rotate(45deg), 0.5)
.Here's a more concrete example:
">Should the serialisation of the computed value of
custom properties be the same astransform
and depend on layout computations?Should this layout computation dependency "infect" other custom properties that reference it via
var()
?What happens when we try to serialise a
custom property inside a layout worklet in the middle of layout computation?I don't think depending on layout computation is a good idea here.
I recommend using
:= | blend(, , )
instead (but with a better name) and to serialise it as the original transform functions instead of as a matrix that incorporates layout computations.Copied from original issue: w3c/css-houdini-drafts#425
The text was updated successfully, but these errors were encountered: