From 31580db11d1e3c4251ef2dbba9ea8556c9531d3f Mon Sep 17 00:00:00 2001 From: omegadox Date: Tue, 10 Mar 2009 13:54:58 +0000 Subject: [PATCH] OGL Plugin: added more info to an error message and some warning fixes. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2640 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Plugins/Plugin_VideoOGL/Src/Globals.cpp | 2 +- Source/Plugins/Plugin_VideoOGL/Src/Render.cpp | 2 +- Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Source/Plugins/Plugin_VideoOGL/Src/Globals.cpp b/Source/Plugins/Plugin_VideoOGL/Src/Globals.cpp index 639ad284c0..936f758b20 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/Globals.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/Globals.cpp @@ -89,7 +89,7 @@ void __Log(const char *fmt, ...) void __Log(int type, const char *fmt, ...) { - int len = strlen(fmt); + int len = (int)strlen(fmt); if (!len) return; char* Msg = (char*)alloca(len + 512); diff --git a/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp b/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp index c7e35891cb..7d91021790 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp @@ -199,7 +199,7 @@ bool Renderer::Init() const char *ptoken = (const char*)glGetString(GL_EXTENSIONS); if (!ptoken) { - PanicAlert("Failed to get OpenGL extension string. Do you have OpenGL drivers installed?"); + PanicAlert("Failed to get OpenGL extension string.\nDo you have the latest video drivers installed?\nIs your video card OpenGL 2.x compatible?"); return false; } INFO_LOG(VIDEO, "Supported OpenGL Extensions:\n"); diff --git a/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp b/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp index 0d05d05100..f0cb5c9a12 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp @@ -697,10 +697,10 @@ void TextureMngr::CopyRenderTargetToTexture(u32 address, bool bFromZBuffer, bool GL_REPORT_ERRORD(); glBegin(GL_QUADS); - glTexCoord2f(flipped_rect.left, flipped_rect.bottom); glVertex2f(-1, 1); - glTexCoord2f(flipped_rect.left, flipped_rect.top ); glVertex2f(-1, -1); - glTexCoord2f(flipped_rect.right, flipped_rect.top ); glVertex2f( 1, -1); - glTexCoord2f(flipped_rect.right, flipped_rect.bottom); glVertex2f( 1, 1); + glTexCoord2f((GLfloat)flipped_rect.left, (GLfloat)flipped_rect.bottom); glVertex2f(-1, 1); + glTexCoord2f((GLfloat)flipped_rect.left, (GLfloat)flipped_rect.top ); glVertex2f(-1, -1); + glTexCoord2f((GLfloat)flipped_rect.right, (GLfloat)flipped_rect.top ); glVertex2f( 1, -1); + glTexCoord2f((GLfloat)flipped_rect.right, (GLfloat)flipped_rect.bottom); glVertex2f( 1, 1); glEnd(); GL_REPORT_ERRORD();