aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2013-09-25 09:36:22 +0200
committermarha <marha@users.sourceforge.net>2013-09-25 09:36:22 +0200
commit14718f10dcda487178690de9a51cc5acdf21e468 (patch)
tree756b76a52c4382e58e5e552e468d93d453c3ae86 /mesalib/src/mesa/main
parente4d5a2996e4a03f55bc7d21c493ba1bcbef35aae (diff)
downloadvcxsrv-14718f10dcda487178690de9a51cc5acdf21e468.tar.gz
vcxsrv-14718f10dcda487178690de9a51cc5acdf21e468.tar.bz2
vcxsrv-14718f10dcda487178690de9a51cc5acdf21e468.zip
fontconfig mesa git update 25 Sep 2013
fontconfig commit 102864d0dba46c99b22c912454c1f58731287405 mesa commit 59157d1c96f33ca56d9aba6cff75145d732dbbab
Diffstat (limited to 'mesalib/src/mesa/main')
-rw-r--r--mesalib/src/mesa/main/bufferobj.c1
-rw-r--r--mesalib/src/mesa/main/compiler.h9
-rw-r--r--mesalib/src/mesa/main/enums.h2
-rw-r--r--mesalib/src/mesa/main/mtypes.h2
-rw-r--r--mesalib/src/mesa/main/teximage.c33
5 files changed, 29 insertions, 18 deletions
diff --git a/mesalib/src/mesa/main/bufferobj.c b/mesalib/src/mesa/main/bufferobj.c
index b22340ff3..312ffb788 100644
--- a/mesalib/src/mesa/main/bufferobj.c
+++ b/mesalib/src/mesa/main/bufferobj.c
@@ -440,7 +440,6 @@ _mesa_buffer_data( struct gl_context *ctx, GLenum target, GLsizeiptrARB size,
* Note that all GL error checking will have been done already.
*
* \param ctx GL context.
- * \param target Buffer object target on which to operate.
* \param offset Offset of the first byte to be modified.
* \param size Size, in bytes, of the data range.
* \param data Pointer to the data to store in the buffer object.
diff --git a/mesalib/src/mesa/main/compiler.h b/mesalib/src/mesa/main/compiler.h
index fb7baf84e..0f27d5a66 100644
--- a/mesalib/src/mesa/main/compiler.h
+++ b/mesalib/src/mesa/main/compiler.h
@@ -270,6 +270,15 @@ static INLINE GLuint CPU_TO_LE32(GLuint x)
#define NULL 0
#endif
+/* Used to optionally mark structures with misaligned elements or size as
+ * packed, to trade off performance for space.
+ */
+#if (__GNUC__ >= 3)
+#define PACKED __attribute__((__packed__))
+#else
+#define PACKED
+#endif
+
/**
* LONGSTRING macro
diff --git a/mesalib/src/mesa/main/enums.h b/mesalib/src/mesa/main/enums.h
index 556c1db99..36c053d4b 100644
--- a/mesalib/src/mesa/main/enums.h
+++ b/mesalib/src/mesa/main/enums.h
@@ -44,6 +44,4 @@ extern const char *_mesa_lookup_enum_by_nr( int nr );
*/
const char *_mesa_lookup_prim_by_nr( unsigned nr );
-extern int _mesa_lookup_enum_by_name( const char *symbol );
-
#endif
diff --git a/mesalib/src/mesa/main/mtypes.h b/mesalib/src/mesa/main/mtypes.h
index c88c1c67b..448946c03 100644
--- a/mesalib/src/mesa/main/mtypes.h
+++ b/mesalib/src/mesa/main/mtypes.h
@@ -3498,8 +3498,6 @@ struct gl_uniform_buffer_binding
* OpenGL state is contained in this structure.
* Think of this as a base class from which device drivers will derive
* sub classes.
- *
- * The struct gl_context typedef names this structure.
*/
struct gl_context
{
diff --git a/mesalib/src/mesa/main/teximage.c b/mesalib/src/mesa/main/teximage.c
index b719fc856..c1261138d 100644
--- a/mesalib/src/mesa/main/teximage.c
+++ b/mesalib/src/mesa/main/teximage.c
@@ -661,22 +661,29 @@ _mesa_delete_texture_image(struct gl_context *ctx,
GLboolean
_mesa_is_proxy_texture(GLenum target)
{
+ unsigned i;
+ static const GLenum targets[] = {
+ GL_PROXY_TEXTURE_1D,
+ GL_PROXY_TEXTURE_2D,
+ GL_PROXY_TEXTURE_3D,
+ GL_PROXY_TEXTURE_CUBE_MAP,
+ GL_PROXY_TEXTURE_RECTANGLE,
+ GL_PROXY_TEXTURE_1D_ARRAY,
+ GL_PROXY_TEXTURE_2D_ARRAY,
+ GL_PROXY_TEXTURE_CUBE_MAP_ARRAY,
+ GL_PROXY_TEXTURE_2D_MULTISAMPLE,
+ GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY
+ };
/*
- * NUM_TEXTURE_TARGETS should match number of terms below, except there's no
+ * NUM_TEXTURE_TARGETS should match number of terms above, except there's no
* proxy for GL_TEXTURE_BUFFER and GL_TEXTURE_EXTERNAL_OES.
*/
- assert(NUM_TEXTURE_TARGETS == 10 + 2);
-
- return (target == GL_PROXY_TEXTURE_1D ||
- target == GL_PROXY_TEXTURE_2D ||
- target == GL_PROXY_TEXTURE_3D ||
- target == GL_PROXY_TEXTURE_CUBE_MAP_ARB ||
- target == GL_PROXY_TEXTURE_RECTANGLE_NV ||
- target == GL_PROXY_TEXTURE_1D_ARRAY_EXT ||
- target == GL_PROXY_TEXTURE_2D_ARRAY_EXT ||
- target == GL_PROXY_TEXTURE_CUBE_MAP_ARRAY ||
- target == GL_PROXY_TEXTURE_2D_MULTISAMPLE ||
- target == GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY);
+ STATIC_ASSERT(NUM_TEXTURE_TARGETS == Elements(targets) + 2);
+
+ for (i = 0; i < Elements(targets); ++i)
+ if (target == targets[i])
+ return GL_TRUE;
+ return GL_FALSE;
}