Skip to content

[css-transforms-2] clamping of perspective() function should affect resolved value of transform #6346

Closed
@dbaron

Description

@dbaron

Like #6320, this is a followup to the resolution in #413. It also depends on #4869 since the relevant piece of the spec isn't in great shape.

In #413 the group resolved that values less than 1px in the perspective() transform function should be clamped to a minimum of 1px. It was described there as a "render time clamp".

However, the resolved value of transform is (interoperably, I think) a matrix() or matrix3d() value. If perspective(0) is put in the matrix without the clamping, we'd need to figure out how to represent infinity in the matrix. While there are, in theory, ways we could do this (like calc(-1/0), it's not clear that those ways are actually reliably supported across engines. It seems both easier and more useful to produce the matrix that would actually be used at render time, but applying the clamping when producing the resolved value.

So I'd like to propose that the clamping of perspective() also apply to the resolved value.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions