Remove unused ifdef for GL setting

Signed-off-by: Mahyar Koshkouei <mahyar.koshkouei@gmail.com>
This commit is contained in:
Mahyar Koshkouei 2018-01-19 22:09:30 +00:00
parent a4fb27346f
commit 07e0c1d10e
1 changed files with 2 additions and 20 deletions

View File

@ -260,30 +260,13 @@ static void context_destroy(void)
log_cb(RETRO_LOG_INFO, "Context destroyed.\n"); log_cb(RETRO_LOG_INFO, "Context destroyed.\n");
} }
#ifdef HAVE_OPENGLES
static bool retro_init_hw_context(void) static bool retro_init_hw_context(void)
{ {
#if defined(HAVE_OPENGLES_3_1) #if defined(HAVE_OPENGLES)
hw_render.context_type = RETRO_HW_CONTEXT_OPENGLES_VERSION;
hw_render.version_major = 3;
hw_render.version_minor = 1;
#elif defined(HAVE_OPENGLES3)
hw_render.context_type = RETRO_HW_CONTEXT_OPENGLES3;
#else
hw_render.context_type = RETRO_HW_CONTEXT_OPENGLES2; hw_render.context_type = RETRO_HW_CONTEXT_OPENGLES2;
#endif
hw_render.context_reset = context_reset;
hw_render.context_destroy = context_destroy;
if (!environ_cb(RETRO_ENVIRONMENT_SET_HW_RENDER, &hw_render))
return false;
return true;
}
#else #else
static bool retro_init_hw_context(void)
{
hw_render.context_type = RETRO_HW_CONTEXT_OPENGL; hw_render.context_type = RETRO_HW_CONTEXT_OPENGL;
#endif
hw_render.context_reset = context_reset; hw_render.context_reset = context_reset;
hw_render.context_destroy = context_destroy; hw_render.context_destroy = context_destroy;
@ -292,7 +275,6 @@ static bool retro_init_hw_context(void)
return true; return true;
} }
#endif
void retro_set_audio_sample(retro_audio_sample_t cb) void retro_set_audio_sample(retro_audio_sample_t cb)
{ {