Commit Graph

94 Commits (web2)

Author SHA1 Message Date
Ben Hansen ef6ec265d8 Merge branch 'master' into web2 3 years ago
Ben Hansen 1135fead3a updated intermediate tutorial docs and removing tutorial13 for maintenance 3 years ago
roudy16 2c4b3668cd address review comment 3 years ago
roudy16 212da09b15 enable right-handed normal maps 3 years ago
sotrh f9b6704cc4
Merge pull request #322 from rokonio/patch-4
Add missing half_dir
3 years ago
Rokonio a9985c2f94
Add missing half_dir
The shader panics (see below) because `half_dir` is missing so I added it.
```
❯ cargo run
   Compiling graphic_rust v0.1.0 (/home/rokonio/dev/rust/graphic_rust)
    Finished dev [unoptimized + debuginfo] target(s) in 5.39s
     Running `target/debug/graphic_rust`
[2022-02-20T10:27:50Z ERROR wgpu::backend::direct] Handling wgpu errors as fatal by default
thread 'main' panicked at 'wgpu error: Validation Error

Caused by:
    In Device::create_shader_module
      note: label = `Shader`
    
Shader 'Shader' parsing error: no definition in scope for identifier: 'half_dir'
   ┌─ wgsl:93:57
   │
93 │     let specular_strength = pow(max(dot(tangent_normal, half_dir), 0.0), 32.0);
   │                                                         ^^^^^^^^ unknown identifier


    no definition in scope for identifier: 'half_dir'

', /home/rokonio/.cargo/registry/src/github.com-1ecc6299db9ec823/wgpu-0.12.0/src/backend/direct.rs:2273:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
```
3 years ago
Rokonio 411702cf17
Correct an error in the normal map tutorial
`wgpu::BindingType::Sampler` is a tuple like variant
3 years ago
Ben Hansen c269f46a0e testing some things 3 years ago
Ben Hansen 6324e485f1 tutorials 1-9 now work with wasm 3 years ago
Daisuke Kato c09edf860e fix typo in docs/tutorial13-threading
Propably -> Probably
3 years ago
rhysd 54121a5c54 fix some typos 3 years ago
Ben Hansen c0843b3f92 fixes #285 3 years ago
Ben Hansen 7a42a0d4db reworking the alignment readme 3 years ago
Ben Hansen 4ae6c3f89f added 0.12.md and examples now compile 3 years ago
Ben Hansen 2073b0fbc1 updated to 0.12 3 years ago
sotrh 92c56a6aa4
Merge pull request #272 from nxsy/tutorial12-updates
Minor update nits for tutorial 12
3 years ago
sotrh a3b9a42c7a
Merge pull request #270 from nxsy/tutorial10-into
Update tutorial 10 to match types and remove deprecated flags
3 years ago
Neil Blakey-Milner 24f4ccea20 Minor update nits for tutorial 12 3 years ago
Neil Blakey-Milner 6f388ff8eb Improve clarity of tutorial11 in terms of updates, files 3 years ago
Neil Blakey-Milner 41d8286645 Add missing or rename shader vars 3 years ago
Neil Blakey-Milner 6be05f781e Update tutorial 10 to match types and remove deprecated flags 3 years ago
Ferdinand Schäffler bd46bdb243 Converted docs. 3 years ago
Martino Fontana 11b24cebc5 model.rs: added "_bind_group" where appropriate 3 years ago
Ben Hansen c0754f9dd3 migrated tutorial5 3 years ago
Ben Hansen 57d7eb763f migrated tutorial4 3 years ago
Ben Hansen 0f618a2ff8 migrated tutorial3 3 years ago
Ben Hansen 822f2d6191 started 0.10 3 years ago
Ben Hansen 806d5aa8af some notes on pbr 3 years ago
Martino Fontana 463b6117eb Renamed "light" to "light_uniform" 3 years ago
Martino Fontana b2b77294f6 Change "uniform" naming to "camera" 3 years ago
Ben Hansen 70bf012641 fixed tangent/bitangent comp and cargo fmt 3 years ago
Martino Fontana 467cec5367 Removed unnecessary borrows 3 years ago
Martino Fontana c80b5a9ae2 Collapsed event_loop match 3 years ago
Martino Fontana b5af53b272 Simplify DrawModel and DrawLight lifetimes 3 years ago
Ben Hansen f46b2f6d74 fixed #142 3 years ago
sotrh 0dce068dcc
Merge pull request #205 from hwoodiwiss/fix-tutorial-10
fix: Tutorial 10 Docs Specular Lighting Shader Problems
3 years ago
Hugo Woodiwiss 87d74d104f
Fix type issue when using pow in wgsl 3 years ago
Hugo Woodiwiss af11f05523
Fix errors in tutorial for specular lighting
Also minor fix to file name
3 years ago
Joshua Barretto 12ba9bed0c Switched to pollster 3 years ago
Ben Hansen 53a019b902 fixed #189 3 years ago
Ben Hansen 63e0d9c6b8 intermediate tutorials migrated 3 years ago
Ben Hansen 46eb5eb139 code now builds on 0.8 3 years ago
sotrh d8a861b515
Merge branch 'master' into cgmath-0.18 3 years ago
Hiroaki Yutani 24f565ee58 Update winit to 0.24 4 years ago
Hiroaki Yutani 1bb374c89e docs 4 years ago
Elijah C. Voigt bcc79b5e41 Misc typo and code fixes.
009: impl Vertex for ModelVertex was using the vertex_attr_array! macro.
009: RenderPipelineDescriptor has a `vertex` member not  `vertex_state`.
009: to_rgba() should be to_rgba8(), to_rgba is set to be deprecated.

010: BindGroupDescriptor has a `entries` member not `bindings`.
010: Remove re-declaration of mat4 model_matrix;
010: Prefer hard-coded [#.#; #] instead of `Foo::fn().into()`.
010: Clarify which shader frag/vert file changes are in.

011: Change Model::load return type to Result<Self>.
011: TextureDescriptor does not have a array_layer_count member.

012: Add .into() to calls in Uniforms::update_view_proj().
012: Dereference delta variable in State::input().

013: Add more changed lines to Model::load to avoid compiler yelling.
4 years ago
Linden Krouse f6f6fa29c4
Fixed some spelling and grammar errors 4 years ago
Ben Hansen 87d0a97404 migrated intermediate tutorial docs 4 years ago
Ben Hansen b4dd4654e4 intermediate tutorial code migrated 4 years ago
Ben Hansen 3901419a58 beginner tutorial code done 4 years ago