forked from mirror/openmw-tes3mp
Merge pull request #904 from sandstranger/disable_opengles_anddroid
disable opengl es for Android by default
This commit is contained in:
commit
195c3b9967
2 changed files with 4 additions and 6 deletions
|
@ -190,10 +190,6 @@ if (WIN32)
|
||||||
add_definitions(-DNOMINMAX -DWIN32_LEAN_AND_MEAN)
|
add_definitions(-DNOMINMAX -DWIN32_LEAN_AND_MEAN)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (ANDROID)
|
|
||||||
set(OPENGL_ES TRUE CACHE BOOL "enable opengl es support for android" FORCE)
|
|
||||||
endif (ANDROID)
|
|
||||||
|
|
||||||
option(OPENGL_ES "enable opengl es support" FALSE )
|
option(OPENGL_ES "enable opengl es support" FALSE )
|
||||||
|
|
||||||
if (OPENGL_ES)
|
if (OPENGL_ES)
|
||||||
|
@ -566,7 +562,9 @@ endif(WIN32)
|
||||||
# Extern
|
# Extern
|
||||||
add_subdirectory (extern/osg-ffmpeg-videoplayer)
|
add_subdirectory (extern/osg-ffmpeg-videoplayer)
|
||||||
add_subdirectory (extern/oics)
|
add_subdirectory (extern/oics)
|
||||||
|
if (USE_QT)
|
||||||
add_subdirectory (extern/osgQt)
|
add_subdirectory (extern/osgQt)
|
||||||
|
endif()
|
||||||
|
|
||||||
# Components
|
# Components
|
||||||
add_subdirectory (components)
|
add_subdirectory (components)
|
||||||
|
|
|
@ -91,7 +91,7 @@ void GraphicsWindowSDL2::init()
|
||||||
SDL_Window *oldWin = SDL_GL_GetCurrentWindow();
|
SDL_Window *oldWin = SDL_GL_GetCurrentWindow();
|
||||||
SDL_GLContext oldCtx = SDL_GL_GetCurrentContext();
|
SDL_GLContext oldCtx = SDL_GL_GetCurrentContext();
|
||||||
|
|
||||||
#ifdef OPENGL_ES
|
#if defined(OPENGL_ES) || defined(ANDROID)
|
||||||
SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_ES);
|
SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_ES);
|
||||||
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 1);
|
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 1);
|
||||||
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 1);
|
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 1);
|
||||||
|
|
Loading…
Reference in a new issue