Skip to content
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

[css-transforms-2]Perspective projection matrix seems wrong in the spec #234

Closed
EcutDavid opened this issue Nov 28, 2017 · 1 comment
Closed

Comments

@EcutDavid
Copy link

Hi, thanks for the great work!

image

At https://drafts.csswg.org/css-transforms-2/#PerspectiveDefined
Giving that the order of matrix is [m11 m21 m31 m41 m12 ...]
And he perspective matrix is [1 0 0 0 0 1 0 0 0 0 1 0 0 0 -1/d 1]

I think this matrix will transform a vector [x, y, z, 1] to [x, y, z - (1 / d), 1] instead of [x, y, z, 1 - (z / d)]
So, the "-1 / d" should be placed at m43 instead of m34.

@EcutDavid EcutDavid changed the title Perspective projection matrix seems wrong in the css-transforms-2 doc [css-transforms-2]Perspective projection matrix seems wrong in the spec Nov 28, 2017
@EcutDavid
Copy link
Author

Sorry, my mistake

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant