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

Matrix basis rep #78

Merged
merged 3 commits into from
Mar 22, 2013
Merged

Matrix basis rep #78

merged 3 commits into from
Mar 22, 2013

Conversation

bergey
Copy link
Member

@bergey bergey commented Mar 22, 2013

Adds a function onBasis specialized on R2. There is no ThreeD.Transform module yet, so I defer writing that variant.

Depends on the change in diagrams/diagrams-core#36

See that pull request for caveats about this code.

bergey added 2 commits March 22, 2013 15:19
onBasis helps backends construct a matrix representation
of a Transformation
@@ -308,3 +311,7 @@ instance (V t ~ R2, Transformable t) => Transformable (ScaleInv t) where
rot = rotateAbout l angle
l' = transform tr l
trans = translate (l' .-. l)

onBasis :: Transformation R2 -> ((R2, R2), R2)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add a Haddock comment explaining what onBasis does?

@byorgey
Copy link
Member

byorgey commented Mar 22, 2013

Thanks!

byorgey added a commit that referenced this pull request Mar 22, 2013
@byorgey byorgey merged commit 0b58a5f into diagrams:master Mar 22, 2013
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

Successfully merging this pull request may close these issues.

2 participants