Skip to content
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

The source code in the Dependencies and window chapters is outdated. #546

Closed
whtsht opened this issue May 5, 2024 · 1 comment
Closed

Comments

@whtsht
Copy link

whtsht commented May 5, 2024

Hello, I'm enjoying reading learn-wgpu.

As a result of changes made in rust-windowing/winit#3056, the following adjustments are necessary:

  • Replace control_flow = ControlFlow::Exit with control_flow.exit().
  • Change event_loop.run(move |event, _, control_flow| { ... }) to event_loop.run(move |event, control_flow| { ... }).

The source code on github has been updated. However, it appears that the code on the article remains unchanged.

Readers who copy and paste this code will encounter compilation errors. This could discourage beginners from continuing with the article.

I can submit a pull request to address this issue.

@aerosayan
Copy link

Exactly the problem I faced.

I'm new to rust, and started learning wpgu two days ago.

I was irritated to find that this tutorial recommended by wgpu was not even compiling, and the new API is so complex and unstable that I couldn't use it.

Only after one day of trying different things, I found out that this tutorial series had a github repo, and the code in the repo, was working correctly.

I see three critical reason that caused this confusion:

  1. The article contains bugs, and even the first tutorial doesn't compile. This will prevent first time visitors from continuing the series.
  2. The over-dependence on the "web" aspect of wgpu is not useful for me. I want to develop a desktop application, and millions of other developers would want to do the same. Web dev is not a priority for us. Perhaps it would be better if the tutorial series was split into two parts. One for desktop development, and one for web development.
  3. The article's UI design makes it difficult to find the link to this repo. As seen in this picture, the link to this repo is given at the bottom, in small text, and is almost invisible to a first time visitor. I did not notice it for one day. The source code should be linked at the top banner, or spread out multiple times throughout the article. The link to this repo should be included at the top of the left pane. Github icons should be used at the top of the repo (or anywhere you deem useful) to link to this repo.

1

@sotrh sotrh closed this as completed in a48836f May 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants