-
Notifications
You must be signed in to change notification settings - Fork 426
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
Oddities when using clipRect + scale. #2301
Comments
FWIW, uncommenting just I'd like to establish better terms than "behave strangely". I assume the bug here is that clipRect's position is scaled by the sprites scale. and the desired behavior is that if a sprite's position moves down and right by 10px, and the clipRect position goes up and left, the drawn rect should stay in the same screen position. Is that right? I think I know how to fix this |
So ive noticed some strange things happening when using clip rects and scales, here is the test app (source code below) working:
And here is the same test when the
_scale
var is set to 3:Whats even more strange is that its possible to "fix" the app by uncommenting the lines in the test app below, which, honestly, doesnt make any sense to me as you have to have both of the lines, and i would have thought that one would have been enough...
Cheers,
Ian
Code snippet reproducing the issue:
Observed behavior:
When increasing the scale the clipping seems to behave strangely.
Expected behavior:
Clipping to be consistent regardless of scale.
The text was updated successfully, but these errors were encountered: