-
Notifications
You must be signed in to change notification settings - Fork 89
feat: Add leftTranslateByVector2 method to Matrix4 #351
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
base: master
Are you sure you want to change the base?
Conversation
0568f24 to
bdb9df7
Compare
|
@kevmoo updated this one with rebase + changelog entry 🙇 |
|
Would you include more details? I don't know what "left" means here. |
|
@kevmoo this is mostly for consistent with the existing |
|
This is also parallel to #354 btw |
kevmoo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a bit of cleanup to the changelog and we can land this.
Co-authored-by: Kevin Moore <[email protected]>
As a follow-up of #349, we might want to support
leftTranslateByVector2, for the same reasons.Note: there were no tests that I could find for the other broken down methods, so I added some assertions. Please let me know if they should be somewhere else or if we want more exhaustive tests.
Note: I am not implementing an equivalent for the scale method because the default implementation of falling back y and z to
xfelt less intuitive when using aVector2. It would mean that scaling by aVector2 vwould be equivalent to scale byv.x, v.y, v.x, 1.0, which isn't quite as clear as the translation case. But I'd be happy to add the helper if desired.