winit 0.27 upgrade breaking changes
error[E0277]: the trait bound `winit::window::Window: HasRawWindowHandle` is not satisfied
--> crates\head\src\main.rs:350:27
|
350 | let surface_texture = SurfaceTexture::new(window_size.width, window_size.height, &window);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `HasRawWindowHandle` is not implemented for `winit::window::Window`
|
= help: the trait `HasRawWindowHandle` is implemented for `&'a T`
error[E0277]: the trait bound `winit::window::Window: HasRawWindowHandle` is not satisfied
--> crates\head\src\main.rs:351:71
|
351 | let pixels = if let Ok(pixels) = Pixels::new_async(WIDTH, HEIGHT, surface_texture).await {
| ----------------- ^^^^^^^^^^^^^^^ the trait `HasRawWindowHandle` is not implemented for `winit::window::Window`
| |
| required by a bound introduced by this call
|
= help: the trait `HasRawWindowHandle` is implemented for `&'a T`
note: required by a bound in `pixels::Pixels::new_async`
--> C:\Users\Zageron\.cargo\git\checkouts\pixels-fd3805be475df9df\0b15a5d\src\lib.rs:227:31
|
227 | pub async fn new_async<W: HasRawWindowHandle>(
| ^^^^^^^^^^^^^^^^^^ required by this bound in `pixels::Pixels::new_async`
Thanks!
I am interested in seeing how this is resolved, not understanding how to make a PR for this feels like a major gap in my knowledge.
We depend on raw-window-handle which is a shared dependency with winit, and needs to be updated to maintain compatibility with newer versions.
https://github.com/parasyte/pixels/blob/41063dbf4b105c45c7bb560f63b41459957faa85/Cargo.toml#L23
Just looked into this. We are blocked on https://github.com/gfx-rs/wgpu/pull/2918 and #289
Heads up! This is getting addressed by #302.
winit 0.27.2 is backward compatible with raw-window-handle 0.4, so you should be able to easily update your project since #300 landed.
Yup everything working great for me with latest on your repo.