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

SVG Rotation Transforms are "funny" #9

Open
ipetepete opened this issue Jun 25, 2015 · 1 comment
Open

SVG Rotation Transforms are "funny" #9

ipetepete opened this issue Jun 25, 2015 · 1 comment

Comments

@ipetepete
Copy link

I'm sure this has nothing to do with dynamics.js (which is great btw). I've found that when rotating an svg, if the rotation is a multiple of 360 it won't rotate at all. In some cases, when the rotation is say 270 degrees, the rotation will actually happen in reverse. I'm thinking svgs have some funky polar coordinates , but I haven't found any documentation explaining the issue.

I've gotten around the issue by using css transforms, although I'm not sure this is ideal.

I've illustrated the behavior here:
http://codepen.io/ipetepete/pen/doZqxK

I just wanted to report my findings for others. If anybody knows how to make svg rotation transforms work properly, I'd love to hear how.

@michaelvillar
Copy link
Owner

Yeah I'm not sure. It's the matrix decomposition that's messed up. I should look more into it, there could be some hack around it.

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

2 participants