summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-09-04 12:34:00 +0200
committerwm4 <wm4@nowhere>2015-09-04 13:03:35 +0200
commit215afe7a41a20d7de1ca96cabfb89b2234b564ff (patch)
treeb6023b8add516ae42534ff349f833e3b785e2852 /video
parentd04d2380e35ba016e3816ab5d7c282997df74168 (diff)
downloadmpv-215afe7a41a20d7de1ca96cabfb89b2234b564ff.tar.bz2
mpv-215afe7a41a20d7de1ca96cabfb89b2234b564ff.tar.xz
vo_opengl: use the correct attribute name for vertex position
This didn't seem entirely sane. It probably worked by accident, because "position" is always the first attribute, and thus the default value 0 for the location was always correct.
Diffstat (limited to 'video')
-rw-r--r--video/out/gl_utils.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/video/out/gl_utils.c b/video/out/gl_utils.c
index 7e13f839d6..b88e04c6c0 100644
--- a/video/out/gl_utils.c
+++ b/video/out/gl_utils.c
@@ -877,8 +877,8 @@ void gl_sc_gen_shader_and_reset(struct gl_shader_cache *sc)
if (strcmp(e->name, "position") == 0) {
// setting raster pos. requires setting gl_Position magic variable
assert(e->num_elems == 2 && e->type == GL_FLOAT);
- ADD(vert_head, "%s vec2 position;\n", vert_in);
- ADD(vert_body, "gl_Position = vec4(position, 1.0, 1.0);\n");
+ ADD(vert_head, "%s vec2 vertex_position;\n", vert_in);
+ ADD(vert_body, "gl_Position = vec4(vertex_position, 1.0, 1.0);\n");
} else {
ADD(vert_head, "%s %s vertex_%s;\n", vert_in, glsl_type, e->name);
ADD(vert_head, "%s %s %s;\n", vert_out, glsl_type, e->name);