diff options
Diffstat (limited to 'shader/vertex_shader.vert')
| -rw-r--r-- | shader/vertex_shader.vert | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/shader/vertex_shader.vert b/shader/vertex_shader.vert new file mode 100644 index 0000000..9a07371 --- /dev/null +++ b/shader/vertex_shader.vert @@ -0,0 +1,10 @@ + +varying vec3 vWorldPosition; + +void main() { + vec4 worldPosition = modelMatrix * vec4( position, 1.0 ); + vWorldPosition = worldPosition.xyz; + + gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 ); + +} |
