Files
wgpu/naga/tests/out/wgsl/glsl-dual-source-blending.frag.wgsl
Dmitry Zamkov bbb7cc79ef Implement clip-distances extension for GL and Vulkan backends (#7730)
* Basic implementation of `clip_distances` for Vulkan and GL backends

* Added GPU test for `clip-distances`

* Update feature array size

* Add changelog entry

* Validate `clip_distances` array size

* Check for `clip_distances` enable directive

* Consolidate code for generating `enable` directives in WGSL backend and add `clip_distances`.
2025-06-16 10:33:31 +02:00

24 lines
485 B
WebGPU Shading Language

enable dual_source_blending;
struct FragmentOutput {
@location(0) @blend_src(0) output0_: vec4<f32>,
@location(0) @blend_src(1) output1_: vec4<f32>,
}
var<private> output0_: vec4<f32>;
var<private> output1_: vec4<f32>;
fn main_1() {
output0_ = vec4<f32>(1f, 0f, 1f, 0f);
output1_ = vec4<f32>(0f, 1f, 0f, 1f);
return;
}
@fragment
fn main() -> FragmentOutput {
main_1();
let _e1 = output0_;
let _e3 = output1_;
return FragmentOutput(_e1, _e3);
}