diff options
author | Brian Paul <[email protected]> | 2011-11-18 17:39:00 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2011-11-19 07:28:07 -0700 |
commit | 2efa3d4f9fd1e1683c5366d402d8740ecfb688e5 (patch) | |
tree | bb164b00ada68c6af90f8f536c548670acb9a23b /src/mesa/main/teximage.h | |
parent | a43908fe62c39b84f014ddf2bee15cd07a77fc0d (diff) |
mesa: define, use _mesa_is_cube_face() in several places
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main/teximage.h')
-rw-r--r-- | src/mesa/main/teximage.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mesa/main/teximage.h b/src/mesa/main/teximage.h index fd315bea3db..9cc7d5a543e 100644 --- a/src/mesa/main/teximage.h +++ b/src/mesa/main/teximage.h @@ -36,6 +36,16 @@ #include "formats.h" +/** Is the given value one of the 6 cube faces? */ +static inline GLboolean +_mesa_is_cube_face(GLenum target) +{ + return (target >= GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB && + target <= GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB); +} + + + /** \name Internal functions */ /*@{*/ |