-
Notifications
You must be signed in to change notification settings - Fork 69
Remove DamageOutOfRange error
#314
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
551b385 to
ab88d81
Compare
Maybe explicitly linking this portion of the documentation:
|
ab88d81 to
65b9295
Compare
Damage that fall outside the surface is ignored.
eb25983 to
2d736ea
Compare
Makes it clearer what we're actually doing with the damage rectangles.
2d736ea to
e554904
Compare
|
I'm not sure about other platforms, but this is definitely reasonable enough on Wayland. 👍 Using a |
|
As I understand it, (Not that we would be using it, I'm pretty sure that damage tracking is only inside AppKit and/or Core Animation itself, the compositor doesn't know about it, so it won't matter once we start using |
There is a very natural thing to do if we receive a damage rectangle outside supported bounds: Clamp it to be inside. This is also what's done by Wayland IIUC, and probably on other platforms as well, so let's do it in Softbuffer as well, and avoid the needless error case.
This also allows us to make
presentforward directly topresent_with_damage, which is a nice internal simplification.Finally, this exposed latent bugs with out-of-bounds damage regions on Windows, Web and X11, I've fixed those as well.
Tested on:
AndroidDoesn't use damageCoreGraphicsDoesn't use damageOrbitalDoesn't use damage