Signed-off-by: Jordan Justen <jordan.l.jus...@intel.com> --- src/mesa/main/texformat.c | 13 +++++++++++++ src/mesa/main/texformat.h | 2 ++ 2 files changed, 15 insertions(+)
diff --git a/src/mesa/main/texformat.c b/src/mesa/main/texformat.c index ed40b7e..a7df868 100644 --- a/src/mesa/main/texformat.c +++ b/src/mesa/main/texformat.c @@ -929,3 +929,16 @@ _mesa_choose_tex_format(struct gl_context *ctx, GLenum target, return MESA_FORMAT_NONE; } +GLboolean +_mesa_tex_target_is_array(GLenum target) +{ + switch (target) { + case GL_TEXTURE_1D_ARRAY_EXT: + case GL_TEXTURE_2D_ARRAY_EXT: + case GL_TEXTURE_2D_MULTISAMPLE_ARRAY: + case GL_TEXTURE_CUBE_MAP_ARRAY: + return GL_TRUE; + default: + return GL_FALSE; + } +} diff --git a/src/mesa/main/texformat.h b/src/mesa/main/texformat.h index efe2699..d6ff541 100644 --- a/src/mesa/main/texformat.h +++ b/src/mesa/main/texformat.h @@ -36,5 +36,7 @@ extern gl_format _mesa_choose_tex_format(struct gl_context *ctx, GLenum target, GLint internalFormat, GLenum format, GLenum type); +extern GLboolean +_mesa_tex_target_is_array(GLenum target); #endif -- 1.7.10.4 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev