Commit graph

14 commits

Author SHA1 Message Date
Emil Loer
b72055d122
Disable CALayer fade action when setting buffers
This commit fixes a bug in the Core Graphics backend that causes a new
buffer not be shown immediately but instead use a quarter second fade
transition. This happens because the CALayer has a default action
associated with a change in the layer contents.

The problem was mitigated by wrapping the contents change in a
transaction and disabling all actions for the duration of this
transaction.
2023-01-05 22:17:10 +01:00
Ian Douglas Scott
fc1bba64ab Rename SwBufError back to SoftBufferError
This seems to be the last thing left over from the `swbuf` rename.
2022-12-27 12:57:26 -08:00
Mads Marquart
89bd260fd8 Use #![deny(unsafe_op_in_unsafe_fn)] 2022-12-23 04:19:41 +01:00
John Nunley
5674886dfa
Add reformat to the CI (#21) 2022-12-22 12:35:18 -08:00
jtnunley
319ff565a5 Use static dispatch 2022-12-22 10:09:47 -08:00
Simon Hausmann
b74047ae86 Fix scaling of the buffer on macOS
Currently the size of the buffer on macOS is interpreted in logical pixels, which
is inconsistent with the other platforms. Instead,
we should apply the same scale factor that applies to regular rendering.
2022-12-21 07:40:47 +01:00
Jeremy Soller
99d63063b6 Take a reference to a window in GraphicsContext::new, like glutin and wgpu 2022-12-20 13:40:54 -07:00
Jeremy Soller
95e8d05902
Rename SoftBufferError to SwBufError 2022-12-20 07:11:11 -07:00
David Johnson
d30d3255c2 Updated winit to 0.27.2 for examples and raw-window-handle to 0.5.0 2022-08-24 00:16:20 -05:00
Ryan Hileman
112e777179 macOS: use a subview, improve image handling 2022-05-16 10:16:50 -07:00
Ryan Hileman
44d1ababf0 CALayer: place buffer in top left instead of scaling to window 2022-05-16 09:15:21 -07:00
Ryan Hileman
ba3b823e1c use CALayer for macOS backend 2022-04-24 07:31:19 -07:00
Seo Sanghyeon
f5b18e8196 Adapt to Core Graphics coordinate system 2022-01-19 14:04:17 +09:00
Seo Sanghyeon
7ff0d65793 Add macOS support using Core Graphics 2022-01-19 13:18:09 +09:00