diff mbox

[3/6] gl: Replace ftransform() with manual coordinate calculation in shaders

Message ID 1297163415-31035-4-git-send-email-alexandros.frantzis@linaro.org
State Accepted
Commit d88ada384fcb045cc9899339f9e8c1cbb8280c16
Headers show

Commit Message

alexandros.frantzis@linaro.org Feb. 8, 2011, 11:10 a.m. UTC
From: Alexandros Frantzis <alexandros.frantzis@linaro.org>

The ftransform() shader function was deprecated and removed in recent
GLSL versions and is not included at all in GLSL ES.
---
 src/cairo-gl-shaders.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff mbox

Patch

diff --git a/src/cairo-gl-shaders.c b/src/cairo-gl-shaders.c
index 1b10b04..13efccb 100644
--- a/src/cairo-gl-shaders.c
+++ b/src/cairo-gl-shaders.c
@@ -520,7 +520,7 @@  cairo_gl_shader_get_vertex_source (cairo_gl_var_type_t src,
     _cairo_output_stream_printf (stream,
 				 "void main()\n"
 				 "{\n"
-				 "    gl_Position = ftransform();\n");
+				 "    gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;\n");
 
     cairo_gl_shader_emit_vertex (stream, src, CAIRO_GL_TEX_SOURCE);
     cairo_gl_shader_emit_vertex (stream, mask, CAIRO_GL_TEX_MASK);