add SurfaceCapabilities to PixelsContext#424
Conversation
parasyte
left a comment
There was a problem hiding this comment.
Thank you for the contribution!
|
It looks like this will technically allow the developer to "fix up" Another option is to do the obvious thing when creating the surface: If the chosen |
|
That makes sense. I added another commit to this PR which handles this and clarifies the language in the PixelsBuilder::present_mode to be an 'optimistic setter' rather than providing any guarantees about the state once the surface is actually built. Also, I used AutoVsync as the default case since it's always supported (wgpu docs) and is what's currently set by Pixels anyway. |
|
Sorry for the delay. I’m returning home from vacation right now. The change looks good and I’ll get this merged as I find time. |
Small change to expose the SurfaceCapabilities struct used when building the Pixels instance through the PixelsContext.
This should allow conditionally setting wgpu PresentMode based on the available options for the Pixels surface (Issue #423).