use GL_TEXTURE_2D_ARRAY for most of our textures

This commit is contained in:
degasus
2014-10-10 00:06:29 +02:00
committed by Jules Blok
parent 60e9301f40
commit 6670cacddc
7 changed files with 86 additions and 69 deletions

View File

@ -206,6 +206,10 @@ static void GLAPIENTRY ClearDepthf(GLfloat depthval)
{
glClearDepth(depthval);
}
static void GLAPIENTRY FramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
{
glFramebufferTextureLayer(target, attachment, texture, level, 0);
}
static void InitDriverInfo()
{
@ -462,6 +466,11 @@ Renderer::Renderer()
glClearDepthf = ClearDepthf;
}
if (!(GLExtensions::Version() >= 320))
{
glFramebufferTexture = FramebufferTexture;
}
g_Config.backend_info.bSupportsDualSourceBlend = GLExtensions::Supports("GL_ARB_blend_func_extended");
g_Config.backend_info.bSupportsPrimitiveRestart = !DriverDetails::HasBug(DriverDetails::BUG_PRIMITIVERESTART) &&
((GLExtensions::Version() >= 310) || GLExtensions::Supports("GL_NV_primitive_restart"));