examples: add pixel post processing effect example
This commit is contained in:
parent
6183e39593
commit
eef76effe3
9 changed files with 618 additions and 0 deletions
8
examples/pixel-post-process/frag.wgsl
Normal file
8
examples/pixel-post-process/frag.wgsl
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
@fragment fn main(
|
||||
@location(0) normal: vec3<f32>,
|
||||
@location(1) uv: vec2<f32>,
|
||||
) -> @location(0) vec4<f32> {
|
||||
var color = floor((uv * 0.5 + 0.25) * 32) / 32;
|
||||
return vec4<f32>(color, 1, 1);
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue