summaryrefslogtreecommitdiffstats
path: root/video/out
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2017-08-04 18:22:26 +0200
committerwm4 <wm4@nowhere>2017-08-05 13:09:05 +0200
commitfa4a1c46759136334646e47c627ddb75e532a658 (patch)
treea445504c3ee4492b3a7247d4e24ca256c117c2e0 /video/out
parent0206efa94aea3d4d20584c4446654a5ddd8e7896 (diff)
downloadmpv-fa4a1c46759136334646e47c627ddb75e532a658.tar.bz2
mpv-fa4a1c46759136334646e47c627ddb75e532a658.tar.xz
vo_opengl: always use GL_TRIANGLES for all primitives
Will make the ra layer _slightly_ simpler.
Diffstat (limited to 'video/out')
-rw-r--r--video/out/opengl/video.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/video/out/opengl/video.c b/video/out/opengl/video.c
index 0923d626d1..1274cc6e3c 100644
--- a/video/out/opengl/video.c
+++ b/video/out/opengl/video.c
@@ -1172,7 +1172,7 @@ static void dispatch_compute(struct gl_video *p, int w, int h,
static void render_pass_quad(struct gl_video *p, int vp_w, int vp_h,
const struct mp_rect *dst)
{
- struct vertex va[4] = {0};
+ struct vertex va[6] = {0};
struct gl_transform t;
gl_transform_ortho(&t, 0, vp_w, 0, vp_h);
@@ -1200,8 +1200,11 @@ static void render_pass_quad(struct gl_video *p, int vp_w, int vp_h,
}
}
+ va[4] = va[2];
+ va[5] = va[1];
+
p->gl->Viewport(0, 0, vp_w, abs(vp_h));
- gl_sc_draw_data(p->sc, GL_TRIANGLE_STRIP, va, 4);
+ gl_sc_draw_data(p->sc, GL_TRIANGLES, va, 6);
debug_check_gl(p, "after rendering");
}