From e2c9befeae0c45e2f41dd0d388a02c4034b14693 Mon Sep 17 00:00:00 2001 From: Rodrigo Braz Monteiro Date: Sun, 15 Apr 2007 22:44:52 +0000 Subject: [PATCH] Fixed display of video coordinates. Originally committed to SVN as r1078. --- aegisub/video_display_visual.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/aegisub/video_display_visual.cpp b/aegisub/video_display_visual.cpp index fad40fac2..c2fde30b8 100644 --- a/aegisub/video_display_visual.cpp +++ b/aegisub/video_display_visual.cpp @@ -500,6 +500,13 @@ void VideoDisplayVisual::DrawOverlay() { glEnd(); glDisable(GL_COLOR_LOGIC_OP); + // Switch display + glMatrixMode(GL_PROJECTION); + glPushMatrix(); + glLoadIdentity(); + glOrtho(0.0f,w,h,0.0f,-1000.0f,1000.0f); + glMatrixMode(GL_MODELVIEW); + // Setup text int tw,th; OpenGLText::SetFont(_T("Verdana"),12,true); @@ -519,6 +526,11 @@ void VideoDisplayVisual::DrawOverlay() { // Draw text OpenGLText::Print(mouseText,dx,dy); + + // Restore matrix + glMatrixMode(GL_PROJECTION); + glPopMatrix(); + glMatrixMode(GL_MODELVIEW); } }