renderer new

This commit is contained in:
Jérôme Bousquié
2026-07-04 15:40:32 +02:00
parent 4b7a1b05e5
commit 2a3c6493fc
5 changed files with 122 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
@vertex
pub fn vs_main(@builtin(vertex_index) vertex_index: u32) -> @builtin(position) vec4f {
var positions = array<vec2f, 3>(
vec2f(0.0, 0.5),
vec2f(-0.5, -0.5),
vec2f(0.5, -0.5),
);
return vec4f(positions[vertex_index], 0.0, 1.0);
}
@fragment
pub fn fs_main() -> @location(0) vec4f {
return vec4f(1.0, 0.0, 0.0, 1.0);
}