Commit Graph

18 Commits

Author SHA1 Message Date
Imbris
ae22743326 Add test case to naga/spv-in for an unnamed glPerVertex struct 2024-02-15 18:12:25 +01:00
Imbris
4554f852c1 [spv-in] Remove providing "perVertexStruct" for certain unnamed inputs
since we probably shouldn't be naming things if they don't have a name
in the input.

As requested here: https://github.com/gfx-rs/wgpu/pull/5227#issuecomment-1936027091
2024-02-15 18:12:25 +01:00
Christian Schwarz
2382c8e74f
Fix glsl backend errors regarding samplerCubeArrayShadow (#5171)
* add GL_EXT_texture_shadow_lod feature detection

* allow more cases of cube depth texture sampling in glsl

* add test for sampling a cubemap array depth texture with lod

* add test for chosing GL_EXT_texture_shadow_lod over the grad workaround if instructed

* add changelog entry for GL_EXT_texture_shadow_lod

* fix criteria for requiring and using TEXTURE_SHADOW_LOD

* require gles 320 for textureSampling over cubeArrayShadow

* prevent false positives in TEXTURE_SHADOW_LOD in checks

* make workaround_lod_with_grad usecase selection less context dependant

* move 3d array texture error into the validator

* correct ImageSample logic errors
2024-02-08 18:27:58 +01:00
Erich Gubler
2d3005b745 feat(const_eval): impl. sign with new component_wise_signed 2024-01-30 10:53:03 +01:00
Erich Gubler
66fd1872ab feat(const_eval): impl. countTrailingZeros 2024-01-30 10:53:03 +01:00
Erich Gubler
ea044f039c feat(const_eval): impl. countLeadingZeros with new component_wise_concrete_int 2024-01-30 10:53:03 +01:00
Erich Gubler
a05cc37e3c feat(const_eval): impl. ceil 2024-01-30 10:53:03 +01:00
Erich Gubler
fc27b08dca feat(const_eval): impl. abs with new component_wise_scalar 2024-01-18 16:57:46 -05:00
Patryk Wychowaniec
e7c7017d2e [naga wgsl-in] Fix parsing break ifs
Closes https://github.com/gfx-rs/wgpu/issues/4982.
2024-01-08 10:50:38 +01:00
Jim Blandy
4b6a2d1dfa [naga] Teach the constant evaluator vector/vector operators.
Allow constant evaluation of binary operators whose left and right
operands are both vectors.
2023-12-12 12:48:10 +01:00
Jim Blandy
0e41cfe4ca [naga] Change operators.wgsl to use values that matter.
Change `splat` to take run-time values as arguments, to prevent
constant evaluation from boiling everything away.
2023-12-12 12:48:10 +01:00
Jim Blandy
86562e69a6 [naga] Support casting to f64 in the constant evaluator. 2023-11-23 12:17:21 +01:00
Jim Blandy
eb92ab2878 [naga wgsl] Experimental 64-bit floating-point literals.
In the WGSL front and back ends, support an `lf` suffix on
floating-point literals to yield 64-bit integer literals.
2023-11-23 12:17:21 +01:00
Erich Gubler
1cf0fe841a test(naga): add struct-layout test 2023-11-22 03:54:16 -07:00
Connor Fitzgerald
1df98d9888
Test And Normalize Vertex Behavior on All Backends (#4723)
Co-authored-by: teoxoy <28601907+teoxoy@users.noreply.github.com>
2023-11-21 22:11:24 +00:00
Jim Blandy
b7dd59e1dc [naga] Let constant evaluation handle Compose of Splat.
When consuming a `Compose` expression that constructs a vector,
flatten `Splat` subexpressions out into their components.

Fixes #4581.
2023-11-16 13:34:27 +01:00
Connor Fitzgerald
7f72c9fc3b
Fix GL Push Constant Layout (#4607)
* It verks!

* More tests

* Fixes

* Working multi-stage push constants

* Comments

* Add push constant partial update teste

* Docs

* Update Cargo.toml

* Comments
2023-11-06 07:58:26 -05:00
Connor Fitzgerald
5369eec3b2
Move naga to subfolder 2023-10-25 14:25:04 -04:00