- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 99
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
Port the renderer from Glium to WGPU #153
Open
hovinen
wants to merge
58
commits into
cristicbz:master
Choose a base branch
from
hovinen:port-to-wgpu
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
+3,687
−1,587
Conversation
This file contains 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
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.
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 :-)