Basic 3D rendering

This commit is contained in:
var
2026-04-01 00:13:07 -05:00
parent 7b40b8702c
commit b4768a885b
14 changed files with 638 additions and 23 deletions

17
res/glsl/vertex.glsl Normal file
View File

@@ -0,0 +1,17 @@
#version 450 core
layout (location = 0) in vec3 position;
layout (location = 1) in vec2 texCoord;
layout (location = 2) in float texIndex;
layout (location = 3) in mat4 theModelMatrix;
out vec3 textureCoord;
uniform mat4 theViewMatrix;
uniform mat4 theProjMatrix;
void main()
{
gl_Position = theProjMatrix * theViewMatrix * theModelMatrix * vec4(position, 1.0);
textureCoord = vec3(1.0 - texCoord.x, 1.0 - texCoord.y, texIndex);
}