diff options
author | Omniscient <omniscient.oce@gmail.com> | 2024-06-07 12:22:50 +1000 |
---|---|---|
committer | Omniscient <omniscient.oce@gmail.com> | 2024-06-07 12:22:50 +1000 |
commit | 4cbb8a9ec77620e6d3c0e4063b249e9cd8df46af (patch) | |
tree | ea60540b6c3a2410b3e5185355033050d0be671b | |
parent | fc960d1f096332b30e6fa7694cf20849478d2b4d (diff) |
what about this?
-rw-r--r-- | examples/triangle/ex_triangle.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/examples/triangle/ex_triangle.c b/examples/triangle/ex_triangle.c index a19cbb3..5b6fbea 100644 --- a/examples/triangle/ex_triangle.c +++ b/examples/triangle/ex_triangle.c @@ -15,15 +15,15 @@ extern core g_core; -static custom_vertex vertices[] = { - (custom_vertex){ .pos = vec2(-0.5, -0.5), .color = vec3(1.0, 1.0, 1.0) }, - (custom_vertex){ .pos = vec2(0.5, -0.5), .color = vec3(1.0, 0.0, 0.0) }, - (custom_vertex){ .pos = vec2(-0.5, 0.5), .color = vec3(0.0, 0.0, 1.0) }, - (custom_vertex){ .pos = vec2(0.5, 0.5), .color = vec3(0.0, 1.0, 0.0) }, -}; -const u32 indices[] = { 2, 1, 0, 1, 2, 3 }; - int main() { + custom_vertex vertices[] = { + (custom_vertex){ .pos = vec2(-0.5, -0.5), .color = vec3(1.0, 1.0, 1.0) }, + (custom_vertex){ .pos = vec2(0.5, -0.5), .color = vec3(1.0, 0.0, 0.0) }, + (custom_vertex){ .pos = vec2(-0.5, 0.5), .color = vec3(0.0, 0.0, 1.0) }, + (custom_vertex){ .pos = vec2(0.5, 0.5), .color = vec3(0.0, 1.0, 0.0) }, + }; + const u32 indices[] = { 2, 1, 0, 1, 2, 3 }; + core_bringup(); arena scratch = arena_create(malloc(1024 * 1024), 1024 * 1024); |