This commit is contained in:
agra
2026-02-26 02:25:02 +02:00
parent 7209e8e69d
commit dd14f1206b
23 changed files with 5433 additions and 9 deletions

View File

@@ -155,7 +155,7 @@ main :: () {
glBindVertexArray(vao);
glBindBuffer(GL_ARRAY_BUFFER, vbo);
glBufferData(GL_ARRAY_BUFFER, 1152, @vertices, GL_STATIC_DRAW);
glBufferData(GL_ARRAY_BUFFER, 1152, vertices.ptr, GL_STATIC_DRAW);
// Position attribute (location 0): 3 floats, stride 32 bytes, offset 0
glVertexAttribPointer(0, 3, GL_FLOAT, 0, 32, xx 0);
@@ -204,7 +204,7 @@ main :: () {
view := mat4_translate(0.0, 0.0, -3.0);
rot_y := mat4_rotate_y(angle);
rot_x := mat4_rotate_x(angle * 0.7);
model := (rot_y, rot_x).multiply();
model := mat4_multiply(rot_y, rot_x);
vm := mat4_multiply(view, model);
mvp := mat4_multiply(proj, vm);