summaryrefslogtreecommitdiff
path: root/skybox/shaders/refraction.vs
blob: 34ad1427e14fc49fefc70307b2be872da16f73f1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#version 330 core

layout(location = 0) in vec3 apos;
layout(location = 1) in vec3 anormal;

out vec3 pos;
out vec3 normal;

uniform mat4 model;
uniform mat4 view;
uniform mat4 projection;

void
main(void)
{
    pos = vec3(model*vec4(apos, 1.0f));
    normal = mat3(transpose(inverse(model)))*anormal;
    gl_Position = projection*view*model*vec4(apos, 1.0f);
}