Harbor

branch main
showing the latest snapshot on main
workflow_discard_output.wgsl 360 B · Plain text
gpu/shader/tests/golden/workflow_discard_output.wgsl 0644 Raw
struct _shade_Input {
	@location(0) alpha: f32,
}

struct _shade_Output {
	@location(0) color: vec4<f32>,
}

@fragment
fn shade(input: _shade_Input) -> _shade_Output {
	var __luma_output: _shade_Output;
	if ((input.alpha < 0.01)) {
		discard;
	} else {
		__luma_output.color = vec4<f32>(input.alpha, input.alpha, input.alpha, 1.0);
	}
	return __luma_output;
}