uterm: drm: fix y-invert bug

This fixes the last OpenGL user that still uses the wrong y-axis
direction. See the gltex helpers for more information.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
This commit is contained in:
David Herrmann 2013-01-12 00:53:01 +01:00
parent 921d4e8c25
commit 9d70156dc9

View File

@ -582,18 +582,18 @@ static int display_blit(struct uterm_display *disp,
vertices[11] = -1.0;
texpos[0] = 0.0;
texpos[1] = 0.0;
texpos[1] = 1.0;
texpos[2] = 0.0;
texpos[3] = 1.0;
texpos[3] = 0.0;
texpos[4] = 1.0;
texpos[5] = 1.0;
texpos[5] = 0.0;
texpos[6] = 0.0;
texpos[7] = 0.0;
texpos[7] = 1.0;
texpos[8] = 1.0;
texpos[9] = 1.0;
texpos[9] = 0.0;
texpos[10] = 1.0;
texpos[11] = 0.0;
texpos[11] = 1.0;
tmp = x + buf->width;
if (tmp < x || x >= sw)
@ -611,7 +611,7 @@ static int display_blit(struct uterm_display *disp,
else
height = buf->height;
glViewport(x, y, width, height);
glViewport(x, sh - y - height, width, height);
glDisable(GL_BLEND);
gl_shader_use(v3d->blit_shader);