[gst-cvs] gst-plugins-gl: rgb_to_curve: save up a texture indirection

Filippo Argiolas fargiolas at kemper.freedesktop.org
Sun Apr 25 01:34:11 PDT 2010


Module: gst-plugins-gl
Branch: master
Commit: f39ceaaf48418e40d9f35f50f530bcbc3ce2cf55
URL:    http://cgit.freedesktop.org/gstreamer/gst-plugins-gl/commit/?id=f39ceaaf48418e40d9f35f50f530bcbc3ce2cf55

Author: Filippo Argiolas <filippo.argiolas at gmail.com>
Date:   Sun Apr 25 10:31:01 2010 +0200

rgb_to_curve: save up a texture indirection

Apparently assigning gl_TexCoord to a temp count as an indirection.
Using it directly avoids it and limits indirections to four not
exceeding i915 limit. Now xpro effect works on i915.

---

 gst/gl/effects/gstgleffectssources.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/gst/gl/effects/gstgleffectssources.c b/gst/gl/effects/gstgleffectssources.c
index bcd9a62..aeaeb7d 100644
--- a/gst/gl/effects/gstgleffectssources.c
+++ b/gst/gl/effects/gstgleffectssources.c
@@ -383,8 +383,7 @@ const gchar *rgb_to_curve_fragment_source =
   "uniform sampler2DRect tex;"
   "uniform sampler1D curve;"
   "void main () {"
-  "  vec2 texturecoord = gl_TexCoord[0].st;"
-  "  vec4 color = texture2DRect (tex, texturecoord);"
+  "  vec4 color = texture2DRect (tex, gl_TexCoord[0].st);"
   "  vec4 outcolor;"
   "  outcolor.r = texture1D(curve, color.r).r;"
   "  outcolor.g = texture1D(curve, color.g).g;"





More information about the Gstreamer-commits mailing list