diff options
Diffstat (limited to 'slideshow/opengl/reflectionVertexShader.glsl')
-rw-r--r-- | slideshow/opengl/reflectionVertexShader.glsl | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/slideshow/opengl/reflectionVertexShader.glsl b/slideshow/opengl/reflectionVertexShader.glsl index 566eafa7590b..96748887c308 100644 --- a/slideshow/opengl/reflectionVertexShader.glsl +++ b/slideshow/opengl/reflectionVertexShader.glsl @@ -28,6 +28,10 @@ #version 130 +attribute vec3 a_position; +attribute vec3 a_normal; +attribute vec2 a_texCoord; + uniform mat4 u_projectionMatrix; uniform mat4 u_modelViewMatrix; uniform mat4 u_sceneTransformMatrix; @@ -42,9 +46,9 @@ void main( void ) { mat4 modelViewMatrix = u_modelViewMatrix * u_operationsTransformMatrix * u_sceneTransformMatrix * u_primitiveTransformMatrix; mat3 normalMatrix = mat3(transpose(inverse(modelViewMatrix))); - gl_Position = u_projectionMatrix * modelViewMatrix * gl_Vertex; - v_texturePosition = gl_MultiTexCoord0.xy; - v_normal = normalize(normalMatrix * gl_Normal); + gl_Position = u_projectionMatrix * modelViewMatrix * vec4(a_position, 1.0); + v_texturePosition = a_texCoord; + v_normal = normalize(normalMatrix * a_normal); v_isShadow = float(gl_VertexID >= 6); } |