diff options
author | sanine <sanine.not@pm.me> | 2022-10-04 14:53:08 -0500 |
---|---|---|
committer | sanine <sanine.not@pm.me> | 2022-10-04 14:53:08 -0500 |
commit | 6d96b0e7ea1d98e44647d0bbbba232701a7d557e (patch) | |
tree | 15fa9d310f1db5767b662fb0bb4cad8a560d3650 /demo/first_person/height.vs | |
parent | 0c55c0e1b48de55fea401ea1b2b3f2280ef0f93c (diff) |
add first person demo
Diffstat (limited to 'demo/first_person/height.vs')
-rw-r--r-- | demo/first_person/height.vs | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/demo/first_person/height.vs b/demo/first_person/height.vs new file mode 100644 index 0000000..a0a61d2 --- /dev/null +++ b/demo/first_person/height.vs @@ -0,0 +1,20 @@ +#version 330 core +layout (location = 0) in vec3 position; +layout (location = 1) in vec3 normal_; +layout (location = 2) in vec2 uv_; + +uniform mat4 model; +uniform mat4 view; +uniform mat4 projection; + +out vec3 pos; +out vec3 normal; +out vec2 uv; + +void main() +{ + gl_Position = projection * view * model * vec4(position, 1.0); + pos = vec3(gl_Position); + normal = normal_; + uv = uv_; +} |