From 0171023edc80901c6028f144b8155d74d9828aa8 Mon Sep 17 00:00:00 2001 From: Themaister Date: Sun, 27 May 2012 21:24:55 +0200 Subject: [PATCH] Fix build. --- gfx/context/sdl_ctx.c | 3 +++ gfx/context/sdl_ctx.h | 1 - gfx/gfx_context.h | 9 ++++++++- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/gfx/context/sdl_ctx.c b/gfx/context/sdl_ctx.c index 0742c12dfb..12f8b576d5 100644 --- a/gfx/context/sdl_ctx.c +++ b/gfx/context/sdl_ctx.c @@ -397,6 +397,7 @@ void gfx_ctx_input_driver(const input_driver_t **input, void **input_data) *input = NULL; } +#ifdef HAVE_OPENGL void gfx_ctx_set_projection(gl_t *gl, bool allow_rotate) { glMatrixMode(GL_PROJECTION); @@ -409,3 +410,5 @@ void gfx_ctx_set_projection(gl_t *gl, bool allow_rotate) glMatrixMode(GL_MODELVIEW); glLoadIdentity(); } +#endif + diff --git a/gfx/context/sdl_ctx.h b/gfx/context/sdl_ctx.h index ce1b5f4b21..7f3167bc52 100644 --- a/gfx/context/sdl_ctx.h +++ b/gfx/context/sdl_ctx.h @@ -17,7 +17,6 @@ #define _SDL_CTX_H #include "SDL.h" -#include "SDL_opengl.h" #include "SDL_version.h" #if SDL_VERSION_ATLEAST(1, 3, 0) diff --git a/gfx/gfx_context.h b/gfx/gfx_context.h index 9cb0c55e03..026d2c4e51 100644 --- a/gfx/gfx_context.h +++ b/gfx/gfx_context.h @@ -21,10 +21,15 @@ #include "../boolean.h" #include "../driver.h" + #ifdef HAVE_CONFIG_H #include "../config.h" #endif +#ifdef HAVE_OPENGL +#include "gl_common.h" +#endif + #ifdef HAVE_SDL #include "SDL_syswm.h" #endif @@ -64,10 +69,12 @@ bool gfx_ctx_menu_init(void) #ifdef RARCH_CONSOLE void gfx_ctx_set_filtering(unsigned index, bool set_smooth); -void gfx_ctx_get_available_resolutions (void); +void gfx_ctx_get_available_resolutions(void); #endif +#ifdef HAVE_OPENGL void gfx_ctx_set_projection(gl_t *gl, bool allow_rotate); +#endif #endif