Introduce CanvasMaterial

This commit is contained in:
2023-01-21 23:00:17 +01:00
parent d788019363
commit 0124123189
4 changed files with 224 additions and 33 deletions

12
assets/canvas_shader.wgsl Normal file
View File

@@ -0,0 +1,12 @@
struct VertexOutput {
@builtin(position) clip_position: vec4<f32>,
@location(0) world_position: vec4<f32>,
@location(1) world_normal: vec3<f32>,
@location(2) uv: vec2<f32>,
};
@fragment
fn fragment(input: VertexOutput) -> @location(0) vec4<f32> {
var output_color = vec4<f32>(input.uv, 1.0, 1.0);
return output_color;
}