Port the renderer from Glium to WGPU#153
Open
hovinen wants to merge 58 commits into
Open
Conversation
Before upgrading, I got the following error when running rust-doom on Ubuntu 23.10:
```
[INFO engine::context] Creating system "tick"... │
[INFO engine::context] Creating system "frame_timers"... │
[INFO engine::context] Creating system "window"... │
interface 'wl_output' has no event 4 │
thread 'main' panicked at /home/hovinen/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.21.0/src/platform_impl/linux/wayland/event_loop.rs:395:10: │
called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" } │
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace │
```
This attempts to do just the minimum needed to bring winit and glium up to their latest versions. This requires several changes due to API changes in those libraries. Other than that, I am avoiding any rearchitecting or other changes.
After upgrading, the program runs without crashing. One can navigate the levels, but the graphics and animation are a messed up. I don't know the code well enough to be able to fix that problem easily.
|
WGPU just for funsies or for webasm and/or bevy engine ? |
Author
Basically the former. I guess wasm and/or Bevy integration would be nice potential side effects. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Not sure whether you would ever want to merge this, but I thought I'd try porting this renderer to WGPU, just for fun. Consider this PR a "heads up".
All the functionality from the Glium version works as far as I can tell. Figuring out how to map the existing structure to WGPU idioms was a bit challenging. I make no guarantees about whether the code in its current from is still idiomatic :-)