aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-06-28 08:08:21 +0200
committermarha <marha@users.sourceforge.net>2012-06-28 08:08:21 +0200
commit67551627d34fff4a0fbe719bce33a3bacb55ccef (patch)
tree37b58281a1186148a56dbb3b9eed6eaf759cbe7b /mesalib/src/mesa
parent7baa3d795c87c11550f1686488c968320428cbf9 (diff)
downloadvcxsrv-67551627d34fff4a0fbe719bce33a3bacb55ccef.tar.gz
vcxsrv-67551627d34fff4a0fbe719bce33a3bacb55ccef.tar.bz2
vcxsrv-67551627d34fff4a0fbe719bce33a3bacb55ccef.zip
xkeyboard-config mesa fontconfig randrproto git update 28 Jun 2012
Diffstat (limited to 'mesalib/src/mesa')
-rw-r--r--mesalib/src/mesa/main/APIspec.xml2
-rw-r--r--mesalib/src/mesa/main/arrayobj.c11
-rw-r--r--mesalib/src/mesa/main/arrayobj.h12
-rw-r--r--mesalib/src/mesa/main/bufferobj.c11
-rw-r--r--mesalib/src/mesa/main/dd.h2
-rw-r--r--mesalib/src/mesa/main/enable.c11
-rw-r--r--mesalib/src/mesa/main/errors.c18
-rw-r--r--mesalib/src/mesa/main/ffvertex_prog.c2
-rw-r--r--mesalib/src/mesa/main/imports.h10
-rw-r--r--mesalib/src/mesa/main/light.c10
-rw-r--r--mesalib/src/mesa/main/mtypes.h138
-rw-r--r--mesalib/src/mesa/main/transformfeedback.c2
-rw-r--r--mesalib/src/mesa/state_tracker/st_cb_fbo.c26
-rw-r--r--mesalib/src/mesa/tnl/t_vb_light.c4
-rw-r--r--mesalib/src/mesa/vbo/vbo_exec_api.c2
-rw-r--r--mesalib/src/mesa/vbo/vbo_exec_array.c5
-rw-r--r--mesalib/src/mesa/vbo/vbo_noop.c2
-rw-r--r--mesalib/src/mesa/vbo/vbo_save_api.c4
-rw-r--r--mesalib/src/mesa/x86/Makefile.am1
-rw-r--r--mesalib/src/mesa/x86/gen_matypes.c2
20 files changed, 172 insertions, 103 deletions
diff --git a/mesalib/src/mesa/main/APIspec.xml b/mesalib/src/mesa/main/APIspec.xml
index 64e666eff..f870cf7db 100644
--- a/mesalib/src/mesa/main/APIspec.xml
+++ b/mesalib/src/mesa/main/APIspec.xml
@@ -2946,7 +2946,7 @@
<return type="void"/>
<param name="shader" type="GLuint"/>
<param name="count" type="GLsizei"/>
- <param name="string" type="const GLchar **"/>
+ <param name="string" type="const GLchar * const *"/>
<param name="length" type="const int *"/>
</proto>
</template>
diff --git a/mesalib/src/mesa/main/arrayobj.c b/mesalib/src/mesa/main/arrayobj.c
index 4c50066de..3439ab6b5 100644
--- a/mesalib/src/mesa/main/arrayobj.c
+++ b/mesalib/src/mesa/main/arrayobj.c
@@ -123,14 +123,15 @@ _mesa_delete_array_object( struct gl_context *ctx, struct gl_array_object *obj )
/**
* Set ptr to arrayObj w/ reference counting.
+ * Note: this should only be called from the _mesa_reference_array_object()
+ * inline function.
*/
void
-_mesa_reference_array_object(struct gl_context *ctx,
- struct gl_array_object **ptr,
- struct gl_array_object *arrayObj)
+_mesa_reference_array_object_(struct gl_context *ctx,
+ struct gl_array_object **ptr,
+ struct gl_array_object *arrayObj)
{
- if (*ptr == arrayObj)
- return;
+ assert(*ptr != arrayObj);
if (*ptr) {
/* Unreference the old array object */
diff --git a/mesalib/src/mesa/main/arrayobj.h b/mesalib/src/mesa/main/arrayobj.h
index 717c7916e..e5270fa2c 100644
--- a/mesalib/src/mesa/main/arrayobj.h
+++ b/mesalib/src/mesa/main/arrayobj.h
@@ -52,9 +52,19 @@ extern void
_mesa_delete_array_object( struct gl_context *ctx, struct gl_array_object *obj );
extern void
+_mesa_reference_array_object_(struct gl_context *ctx,
+ struct gl_array_object **ptr,
+ struct gl_array_object *arrayObj);
+
+static inline void
_mesa_reference_array_object(struct gl_context *ctx,
struct gl_array_object **ptr,
- struct gl_array_object *arrayObj);
+ struct gl_array_object *arrayObj)
+{
+ if (*ptr != arrayObj)
+ _mesa_reference_array_object_(ctx, ptr, arrayObj);
+}
+
extern void
_mesa_initialize_array_object( struct gl_context *ctx,
diff --git a/mesalib/src/mesa/main/bufferobj.c b/mesalib/src/mesa/main/bufferobj.c
index 5f724ace3..ea48af97e 100644
--- a/mesalib/src/mesa/main/bufferobj.c
+++ b/mesalib/src/mesa/main/bufferobj.c
@@ -2021,8 +2021,11 @@ set_ubo_binding(struct gl_context *ctx,
}
/**
- * Specify a buffer object to receive vertex shader results. Plus,
- * specify the starting offset to place the results, and max size.
+ * Bind a region of a buffer object to a uniform block binding point.
+ * \param index the uniform buffer binding point index
+ * \param bufObj the buffer object
+ * \param offset offset to the start of buffer object region
+ * \param size size of the buffer object region
*/
static void
bind_buffer_range_uniform_buffer(struct gl_context *ctx,
@@ -2054,8 +2057,8 @@ bind_buffer_range_uniform_buffer(struct gl_context *ctx,
/**
- * Specify a buffer object to receive vertex shader results.
- * As above, but start at offset = 0.
+ * Bind a buffer object to a uniform block binding point.
+ * As above, but offset = 0.
*/
static void
bind_buffer_base_uniform_buffer(struct gl_context *ctx,
diff --git a/mesalib/src/mesa/main/dd.h b/mesalib/src/mesa/main/dd.h
index 5bcf36bfa..687a38f44 100644
--- a/mesalib/src/mesa/main/dd.h
+++ b/mesalib/src/mesa/main/dd.h
@@ -1024,7 +1024,7 @@ typedef struct {
void (GLAPIENTRYP MultiDrawElementsBaseVertex)( GLenum mode,
const GLsizei *count,
GLenum type,
- const GLvoid **indices,
+ const GLvoid * const *indices,
GLsizei primcount,
const GLint *basevertex);
void (GLAPIENTRYP DrawArraysInstanced)(GLenum mode, GLint first,
diff --git a/mesalib/src/mesa/main/enable.c b/mesalib/src/mesa/main/enable.c
index d0b462580..c811f2a9c 100644
--- a/mesalib/src/mesa/main/enable.c
+++ b/mesalib/src/mesa/main/enable.c
@@ -161,8 +161,8 @@ client_state(struct gl_context *ctx, GLenum cap, GLboolean state)
return;
invalid_enum_error:
- _mesa_error(ctx, GL_INVALID_ENUM, "gl%sClientState(0x%x)",
- state ? "Enable" : "Disable", cap);
+ _mesa_error(ctx, GL_INVALID_ENUM, "gl%sClientState(%s)",
+ state ? "Enable" : "Disable", _mesa_lookup_enum_by_nr(cap));
}
@@ -937,8 +937,8 @@ _mesa_set_enable(struct gl_context *ctx, GLenum cap, GLboolean state)
return;
invalid_enum_error:
- _mesa_error(ctx, GL_INVALID_ENUM, "gl%s(0x%x)",
- state ? "Enable" : "Disable", cap);
+ _mesa_error(ctx, GL_INVALID_ENUM, "gl%s(%s)",
+ state ? "Enable" : "Disable", _mesa_lookup_enum_by_nr(cap));
}
@@ -1441,6 +1441,7 @@ _mesa_IsEnabled( GLenum cap )
return GL_FALSE;
invalid_enum_error:
- _mesa_error(ctx, GL_INVALID_ENUM, "glIsEnabled(0x%x)", (int) cap);
+ _mesa_error(ctx, GL_INVALID_ENUM, "glIsEnabled(%s)",
+ _mesa_lookup_enum_by_nr(cap));
return GL_FALSE;
}
diff --git a/mesalib/src/mesa/main/errors.c b/mesalib/src/mesa/main/errors.c
index 69dbb65cf..8b96319ce 100644
--- a/mesalib/src/mesa/main/errors.c
+++ b/mesalib/src/mesa/main/errors.c
@@ -718,11 +718,11 @@ _mesa_DebugMessageControlARB(GLenum source, GLenum type, GLenum severity,
}
static void GLAPIENTRY
-_mesa_DebugMessageCallbackARB(GLDEBUGPROCARB callback, GLvoid *userParam)
+_mesa_DebugMessageCallbackARB(GLDEBUGPROCARB callback, const GLvoid *userParam)
{
GET_CURRENT_CONTEXT(ctx);
ctx->Debug.Callback = callback;
- ctx->Debug.CallbackData = userParam;
+ ctx->Debug.CallbackData = (void *) userParam;
}
void
@@ -801,12 +801,21 @@ output_if_debug(const char *prefixString, const char *outputString,
GLboolean newline)
{
static int debug = -1;
+ static FILE *fout = NULL;
/* Init the local 'debug' var once.
* Note: the _mesa_init_debug() function should have been called
* by now so MESA_DEBUG_FLAGS will be initialized.
*/
if (debug == -1) {
+ /* If MESA_LOG_FILE env var is set, log Mesa errors, warnings,
+ * etc to the named file. Otherwise, output to stderr.
+ */
+ const char *logFile = _mesa_getenv("MESA_LOG_FILE");
+ if (logFile)
+ fout = fopen(logFile, "w");
+ if (!fout)
+ fout = stderr;
#ifdef DEBUG
/* in debug builds, print messages unless MESA_DEBUG="silent" */
if (MESA_DEBUG_FLAGS & DEBUG_SILENT)
@@ -821,9 +830,10 @@ output_if_debug(const char *prefixString, const char *outputString,
/* Now only print the string if we're required to do so. */
if (debug) {
- fprintf(stderr, "%s: %s", prefixString, outputString);
+ fprintf(fout, "%s: %s", prefixString, outputString);
if (newline)
- fprintf(stderr, "\n");
+ fprintf(fout, "\n");
+ fflush(fout);
#if defined(_WIN32) && !defined(_WIN32_WCE)
/* stderr from windows applications without console is not usually
diff --git a/mesalib/src/mesa/main/ffvertex_prog.c b/mesalib/src/mesa/main/ffvertex_prog.c
index f1ab75333..557768311 100644
--- a/mesalib/src/mesa/main/ffvertex_prog.c
+++ b/mesalib/src/mesa/main/ffvertex_prog.c
@@ -181,7 +181,7 @@ static void make_state_key( struct gl_context *ctx, struct state_key *key )
key->light_twoside = 1;
if (ctx->Light.ColorMaterialEnabled) {
- key->light_color_material_mask = ctx->Light.ColorMaterialBitmask;
+ key->light_color_material_mask = ctx->Light._ColorMaterialBitmask;
}
for (i = 0; i < MAX_LIGHTS; i++) {
diff --git a/mesalib/src/mesa/main/imports.h b/mesalib/src/mesa/main/imports.h
index c0b6cecea..9fb6ae8f1 100644
--- a/mesalib/src/mesa/main/imports.h
+++ b/mesalib/src/mesa/main/imports.h
@@ -646,6 +646,16 @@ _mesa_vsnprintf(char *str, size_t size, const char *fmt, va_list arg);
#endif
+/**
+ * On Mingw32 we need to use __mingw_fprintf() to parse formats such
+ * as "0x%llx", and possibly others
+ */
+#ifdef __MINGW32__
+#define fprintf __mingw_fprintf
+#endif
+
+
+
#ifdef __cplusplus
}
#endif
diff --git a/mesalib/src/mesa/main/light.c b/mesalib/src/mesa/main/light.c
index 38ec1b6e8..d6fbcd9be 100644
--- a/mesalib/src/mesa/main/light.c
+++ b/mesalib/src/mesa/main/light.c
@@ -693,13 +693,13 @@ _mesa_update_material( struct gl_context *ctx, GLuint bitmask )
/*
* Update the current materials from the given rgba color
- * according to the bitmask in ColorMaterialBitmask, which is
+ * according to the bitmask in _ColorMaterialBitmask, which is
* set by glColorMaterial().
*/
void
_mesa_update_color_material( struct gl_context *ctx, const GLfloat color[4] )
{
- GLuint bitmask = ctx->Light.ColorMaterialBitmask;
+ const GLbitfield bitmask = ctx->Light._ColorMaterialBitmask;
struct gl_material *mat = &ctx->Light.Material;
int i;
@@ -731,13 +731,13 @@ _mesa_ColorMaterial( GLenum face, GLenum mode )
if (bitmask == 0)
return; /* error was recorded */
- if (ctx->Light.ColorMaterialBitmask == bitmask &&
+ if (ctx->Light._ColorMaterialBitmask == bitmask &&
ctx->Light.ColorMaterialFace == face &&
ctx->Light.ColorMaterialMode == mode)
return;
FLUSH_VERTICES(ctx, _NEW_LIGHT);
- ctx->Light.ColorMaterialBitmask = bitmask;
+ ctx->Light._ColorMaterialBitmask = bitmask;
ctx->Light.ColorMaterialFace = face;
ctx->Light.ColorMaterialMode = mode;
@@ -1188,7 +1188,7 @@ _mesa_init_lighting( struct gl_context *ctx )
ctx->Light.Enabled = GL_FALSE;
ctx->Light.ColorMaterialFace = GL_FRONT_AND_BACK;
ctx->Light.ColorMaterialMode = GL_AMBIENT_AND_DIFFUSE;
- ctx->Light.ColorMaterialBitmask = _mesa_material_bitmask( ctx,
+ ctx->Light._ColorMaterialBitmask = _mesa_material_bitmask( ctx,
GL_FRONT_AND_BACK,
GL_AMBIENT_AND_DIFFUSE, ~0,
NULL );
diff --git a/mesalib/src/mesa/main/mtypes.h b/mesalib/src/mesa/main/mtypes.h
index def0db1aa..d37c1f3de 100644
--- a/mesalib/src/mesa/main/mtypes.h
+++ b/mesalib/src/mesa/main/mtypes.h
@@ -630,6 +630,26 @@ struct gl_config
/**
+ * Material state.
+ */
+struct gl_material
+{
+ GLfloat Attrib[MAT_ATTRIB_MAX][4];
+};
+
+
+/**
+ * Light state flags.
+ */
+/*@{*/
+#define LIGHT_SPOT 0x1
+#define LIGHT_LOCAL_VIEWER 0x2
+#define LIGHT_POSITIONAL 0x4
+#define LIGHT_NEED_VERTICES (LIGHT_POSITIONAL|LIGHT_LOCAL_VIEWER)
+/*@}*/
+
+
+/**
* Light source state.
*/
struct gl_light
@@ -654,7 +674,7 @@ struct gl_light
* \name Derived fields
*/
/*@{*/
- GLbitfield _Flags; /**< State */
+ GLbitfield _Flags; /**< Mask of LIGHT_x bits defined above */
GLfloat _Position[4]; /**< position in eye/obj coordinates */
GLfloat _VP_inf_norm[3]; /**< Norm direction to infinite light */
@@ -683,15 +703,6 @@ struct gl_lightmodel
/**
- * Material state.
- */
-struct gl_material
-{
- GLfloat Attrib[MAT_ATTRIB_MAX][4];
-};
-
-
-/**
* Accumulation buffer attribute group (GL_ACCUM_BUFFER_BIT)
*/
struct gl_accum_attrib
@@ -912,16 +923,6 @@ struct gl_hint_attrib
GLenum FragmentShaderDerivative; /**< GL_ARB_fragment_shader */
};
-/**
- * Light state flags.
- */
-/*@{*/
-#define LIGHT_SPOT 0x1
-#define LIGHT_LOCAL_VIEWER 0x2
-#define LIGHT_POSITIONAL 0x4
-#define LIGHT_NEED_VERTICES (LIGHT_POSITIONAL|LIGHT_LOCAL_VIEWER)
-/*@}*/
-
/**
* Lighting attribute group (GL_LIGHT_BIT).
@@ -932,20 +933,19 @@ struct gl_light_attrib
struct gl_lightmodel Model; /**< Lighting model */
/**
- * Must flush FLUSH_VERTICES before referencing:
+ * Front and back material values.
+ * Note: must call FLUSH_VERTICES() before using.
*/
- /*@{*/
- struct gl_material Material; /**< Includes front & back values */
- /*@}*/
+ struct gl_material Material;
GLboolean Enabled; /**< Lighting enabled flag */
GLenum ShadeModel; /**< GL_FLAT or GL_SMOOTH */
GLenum ProvokingVertex; /**< GL_EXT_provoking_vertex */
GLenum ColorMaterialFace; /**< GL_FRONT, BACK or FRONT_AND_BACK */
GLenum ColorMaterialMode; /**< GL_AMBIENT, GL_DIFFUSE, etc */
- GLbitfield ColorMaterialBitmask; /**< bitmask formed from Face and Mode */
+ GLbitfield _ColorMaterialBitmask; /**< bitmask formed from Face and Mode */
GLboolean ColorMaterialEnabled;
- GLenum ClampVertexColor;
+ GLenum ClampVertexColor; /**< GL_TRUE, GL_FALSE, GL_FIXED_ONLY */
GLboolean _ClampVertexColor;
struct gl_light EnabledList; /**< List sentinel */
@@ -1181,46 +1181,6 @@ typedef enum
/**
- * TexGenEnabled flags.
- */
-/*@{*/
-#define S_BIT 1
-#define T_BIT 2
-#define R_BIT 4
-#define Q_BIT 8
-#define STR_BITS (S_BIT | T_BIT | R_BIT)
-/*@}*/
-
-
-/**
- * Bit flag versions of the corresponding GL_ constants.
- */
-/*@{*/
-#define TEXGEN_SPHERE_MAP 0x1
-#define TEXGEN_OBJ_LINEAR 0x2
-#define TEXGEN_EYE_LINEAR 0x4
-#define TEXGEN_REFLECTION_MAP_NV 0x8
-#define TEXGEN_NORMAL_MAP_NV 0x10
-
-#define TEXGEN_NEED_NORMALS (TEXGEN_SPHERE_MAP | \
- TEXGEN_REFLECTION_MAP_NV | \
- TEXGEN_NORMAL_MAP_NV)
-#define TEXGEN_NEED_EYE_COORD (TEXGEN_SPHERE_MAP | \
- TEXGEN_REFLECTION_MAP_NV | \
- TEXGEN_NORMAL_MAP_NV | \
- TEXGEN_EYE_LINEAR)
-/*@}*/
-
-
-
-/** Tex-gen enabled for texture unit? */
-#define ENABLE_TEXGEN(unit) (1 << (unit))
-
-/** Non-identity texture matrix for texture unit? */
-#define ENABLE_TEXMAT(unit) (1 << (unit))
-
-
-/**
* Texture image state. Drivers will typically create a subclass of this
* with extra fields for memory buffers, etc.
*/
@@ -1367,6 +1327,46 @@ struct gl_tex_env_combine_state
/**
+ * TexGenEnabled flags.
+ */
+/*@{*/
+#define S_BIT 1
+#define T_BIT 2
+#define R_BIT 4
+#define Q_BIT 8
+#define STR_BITS (S_BIT | T_BIT | R_BIT)
+/*@}*/
+
+
+/**
+ * Bit flag versions of the corresponding GL_ constants.
+ */
+/*@{*/
+#define TEXGEN_SPHERE_MAP 0x1
+#define TEXGEN_OBJ_LINEAR 0x2
+#define TEXGEN_EYE_LINEAR 0x4
+#define TEXGEN_REFLECTION_MAP_NV 0x8
+#define TEXGEN_NORMAL_MAP_NV 0x10
+
+#define TEXGEN_NEED_NORMALS (TEXGEN_SPHERE_MAP | \
+ TEXGEN_REFLECTION_MAP_NV | \
+ TEXGEN_NORMAL_MAP_NV)
+#define TEXGEN_NEED_EYE_COORD (TEXGEN_SPHERE_MAP | \
+ TEXGEN_REFLECTION_MAP_NV | \
+ TEXGEN_NORMAL_MAP_NV | \
+ TEXGEN_EYE_LINEAR)
+/*@}*/
+
+
+
+/** Tex-gen enabled for texture unit? */
+#define ENABLE_TEXGEN(unit) (1 << (unit))
+
+/** Non-identity texture matrix for texture unit? */
+#define ENABLE_TEXMAT(unit) (1 << (unit))
+
+
+/**
* Texture coord generation state.
*/
struct gl_texgen
@@ -2021,6 +2021,12 @@ struct gl_fragment_program
* GLSL, the value is INTERP_QUALIFIER_NONE.
*/
enum glsl_interp_qualifier InterpQualifier[FRAG_ATTRIB_MAX];
+
+ /**
+ * Bitfield indicating, for each fragment shader input, 1 if that input
+ * uses centroid interpolation, 0 otherwise. Unused inputs are 0.
+ */
+ GLbitfield64 IsCentroid;
};
diff --git a/mesalib/src/mesa/main/transformfeedback.c b/mesalib/src/mesa/main/transformfeedback.c
index 84c409185..d02b6a056 100644
--- a/mesalib/src/mesa/main/transformfeedback.c
+++ b/mesalib/src/mesa/main/transformfeedback.c
@@ -428,6 +428,7 @@ bind_buffer_range(struct gl_context *ctx, GLuint index,
/**
* Specify a buffer object to receive vertex shader results. Plus,
* specify the starting offset to place the results, and max size.
+ * Called from the glBindBufferRange() function.
*/
void
_mesa_bind_buffer_range_transform_feedback(struct gl_context *ctx,
@@ -471,6 +472,7 @@ _mesa_bind_buffer_range_transform_feedback(struct gl_context *ctx,
/**
* Specify a buffer object to receive vertex shader results.
* As above, but start at offset = 0.
+ * Called from the glBindBufferBase() function.
*/
void
_mesa_bind_buffer_base_transform_feedback(struct gl_context *ctx,
diff --git a/mesalib/src/mesa/state_tracker/st_cb_fbo.c b/mesalib/src/mesa/state_tracker/st_cb_fbo.c
index aeb5ac7fb..10f4e09cf 100644
--- a/mesalib/src/mesa/state_tracker/st_cb_fbo.c
+++ b/mesalib/src/mesa/state_tracker/st_cb_fbo.c
@@ -57,6 +57,10 @@
#include "util/u_surface.h"
+/** Set to 1 to enable extra debug code */
+#define ST_DEBUG_FBO 0
+
+
static GLboolean
st_renderbuffer_alloc_sw_storage(struct gl_context * ctx,
struct gl_renderbuffer *rb,
@@ -472,6 +476,16 @@ st_finish_render_texture(struct gl_context *ctx,
}
+/** Debug helper */
+static void
+st_fbo_invalid(const char *reason)
+{
+#if ST_DEBUG_FBO
+ debug_printf("Invalid FBO: %s\n", reason);
+#endif
+}
+
+
/**
* Validate a renderbuffer attachment for a particular set of bindings.
*/
@@ -484,6 +498,7 @@ st_validate_attachment(struct gl_context *ctx,
const struct st_texture_object *stObj = st_texture_object(att->Texture);
enum pipe_format format;
gl_format texFormat;
+ GLboolean valid;
/* Only validate texture attachments for now, since
* st_renderbuffer_alloc_storage makes sure that
@@ -507,9 +522,14 @@ st_validate_attachment(struct gl_context *ctx,
format = st_mesa_format_to_pipe_format(linearFormat);
}
- return screen->is_format_supported(screen, format,
+ valid = screen->is_format_supported(screen, format,
PIPE_TEXTURE_2D,
stObj->pt->nr_samples, bindings);
+ if (!valid) {
+ st_fbo_invalid("Invalid format");
+ }
+
+ return valid;
}
@@ -558,12 +578,14 @@ st_validate_framebuffer(struct gl_context *ctx, struct gl_framebuffer *fb)
screen->get_param(screen, PIPE_CAP_MIXED_COLORBUFFER_FORMATS) != 0;
if (depth->Type && stencil->Type && depth->Type != stencil->Type) {
+ st_fbo_invalid("Different Depth/Stencil buffer formats");
fb->_Status = GL_FRAMEBUFFER_UNSUPPORTED_EXT;
return;
}
if (depth->Type == GL_RENDERBUFFER_EXT &&
stencil->Type == GL_RENDERBUFFER_EXT &&
depth->Renderbuffer != stencil->Renderbuffer) {
+ st_fbo_invalid("Separate Depth/Stencil buffers");
fb->_Status = GL_FRAMEBUFFER_UNSUPPORTED_EXT;
return;
}
@@ -571,6 +593,7 @@ st_validate_framebuffer(struct gl_context *ctx, struct gl_framebuffer *fb)
stencil->Type == GL_TEXTURE &&
depth->Texture != stencil->Texture) {
fb->_Status = GL_FRAMEBUFFER_UNSUPPORTED_EXT;
+ st_fbo_invalid("Different Depth/Stencil textures");
return;
}
@@ -613,6 +636,7 @@ st_validate_framebuffer(struct gl_context *ctx, struct gl_framebuffer *fb)
first_format = format;
} else if (format != first_format) {
fb->_Status = GL_FRAMEBUFFER_UNSUPPORTED_EXT;
+ st_fbo_invalid("Mixed color formats");
return;
}
}
diff --git a/mesalib/src/mesa/tnl/t_vb_light.c b/mesalib/src/mesa/tnl/t_vb_light.c
index 39467fac7..854887c8f 100644
--- a/mesalib/src/mesa/tnl/t_vb_light.c
+++ b/mesalib/src/mesa/tnl/t_vb_light.c
@@ -227,12 +227,12 @@ prepare_materials(struct gl_context *ctx,
store->mat_count = 0;
store->mat_bitmask = 0;
- /* Examine the ColorMaterialBitmask to determine which materials
+ /* Examine the _ColorMaterialBitmask to determine which materials
* track vertex color. Override the material attribute's pointer
* with the color pointer for each one.
*/
if (ctx->Light.ColorMaterialEnabled) {
- const GLuint bitmask = ctx->Light.ColorMaterialBitmask;
+ const GLuint bitmask = ctx->Light._ColorMaterialBitmask;
for (i = 0 ; i < MAT_ATTRIB_MAX ; i++)
if (bitmask & (1<<i))
VB->AttribPtr[_TNL_ATTRIB_MAT_FRONT_AMBIENT + i] = VB->AttribPtr[_TNL_ATTRIB_COLOR0];
diff --git a/mesalib/src/mesa/vbo/vbo_exec_api.c b/mesalib/src/mesa/vbo/vbo_exec_api.c
index bfa1b1db8..fc7e40692 100644
--- a/mesalib/src/mesa/vbo/vbo_exec_api.c
+++ b/mesalib/src/mesa/vbo/vbo_exec_api.c
@@ -450,7 +450,7 @@ vbo_Materialfv(GLenum face, GLenum pname, const GLfloat *params)
* indicating which material attributes can actually be updated below.
*/
if (ctx->Light.ColorMaterialEnabled) {
- updateMats = ~ctx->Light.ColorMaterialBitmask;
+ updateMats = ~ctx->Light._ColorMaterialBitmask;
}
else {
/* GL_COLOR_MATERIAL is disabled so don't skip any material updates */
diff --git a/mesalib/src/mesa/vbo/vbo_exec_array.c b/mesalib/src/mesa/vbo/vbo_exec_array.c
index ebf008536..6f6a2983a 100644
--- a/mesalib/src/mesa/vbo/vbo_exec_array.c
+++ b/mesalib/src/mesa/vbo/vbo_exec_array.c
@@ -1149,7 +1149,8 @@ vbo_exec_DrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count,
static void
vbo_validated_multidrawelements(struct gl_context *ctx, GLenum mode,
const GLsizei *count, GLenum type,
- const GLvoid **indices, GLsizei primcount,
+ const GLvoid * const *indices,
+ GLsizei primcount,
const GLint *basevertex)
{
struct vbo_context *vbo = vbo_context(ctx);
@@ -1290,7 +1291,7 @@ vbo_exec_MultiDrawElements(GLenum mode,
static void GLAPIENTRY
vbo_exec_MultiDrawElementsBaseVertex(GLenum mode,
const GLsizei *count, GLenum type,
- const GLvoid **indices,
+ const GLvoid * const *indices,
GLsizei primcount,
const GLsizei *basevertex)
{
diff --git a/mesalib/src/mesa/vbo/vbo_noop.c b/mesalib/src/mesa/vbo/vbo_noop.c
index 430011207..2f472c21c 100644
--- a/mesalib/src/mesa/vbo/vbo_noop.c
+++ b/mesalib/src/mesa/vbo/vbo_noop.c
@@ -404,7 +404,7 @@ _mesa_noop_DrawRangeElementsBaseVertex(GLenum mode,
static void GLAPIENTRY
_mesa_noop_MultiDrawElementsBaseVertex(GLenum mode, const GLsizei * count,
GLenum type,
- const GLvoid ** indices,
+ const GLvoid * const *indices,
GLsizei primcount,
const GLint * basevertex)
{
diff --git a/mesalib/src/mesa/vbo/vbo_save_api.c b/mesalib/src/mesa/vbo/vbo_save_api.c
index b2c9dd5f0..d27525812 100644
--- a/mesalib/src/mesa/vbo/vbo_save_api.c
+++ b/mesalib/src/mesa/vbo/vbo_save_api.c
@@ -1042,7 +1042,7 @@ _save_MultiDrawElements(GLenum mode, const GLsizei *count, GLenum type,
static void GLAPIENTRY
_save_MultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count,
- GLenum type, const GLvoid **indices,
+ GLenum type, const GLvoid * const *indices,
GLsizei primcount, const GLint *basevertex)
{
GET_CURRENT_CONTEXT(ctx);
@@ -1255,7 +1255,7 @@ _save_OBE_MultiDrawElements(GLenum mode, const GLsizei *count, GLenum type,
static void GLAPIENTRY
_save_OBE_MultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count,
GLenum type,
- const GLvoid **indices,
+ const GLvoid * const *indices,
GLsizei primcount,
const GLint *basevertex)
{
diff --git a/mesalib/src/mesa/x86/Makefile.am b/mesalib/src/mesa/x86/Makefile.am
index f241de505..5976bb47c 100644
--- a/mesalib/src/mesa/x86/Makefile.am
+++ b/mesalib/src/mesa/x86/Makefile.am
@@ -22,6 +22,7 @@
if HAVE_X86_ASM
AM_CPPFLAGS = \
+ -I$(top_srcdir)/include \
-I$(top_srcdir)/src/mesa \
-I$(top_srcdir)/src/mapi \
$(API_DEFINES) \
diff --git a/mesalib/src/mesa/x86/gen_matypes.c b/mesalib/src/mesa/x86/gen_matypes.c
index 4fe99e799..a1d8ee67d 100644
--- a/mesalib/src/mesa/x86/gen_matypes.c
+++ b/mesalib/src/mesa/x86/gen_matypes.c
@@ -99,7 +99,7 @@ int main( int argc, char **argv )
OFFSET( "CTX_LIGHT_SHADE_MODEL ", struct gl_context, Light.ShadeModel );
OFFSET( "CTX_LIGHT_COLOR_MAT_FACE ", struct gl_context, Light.ColorMaterialFace );
OFFSET( "CTX_LIGHT_COLOR_MAT_MODE ", struct gl_context, Light.ColorMaterialMode );
- OFFSET( "CTX_LIGHT_COLOR_MAT_MASK ", struct gl_context, Light.ColorMaterialBitmask );
+ OFFSET( "CTX_LIGHT_COLOR_MAT_MASK ", struct gl_context, Light._ColorMaterialBitmask );
OFFSET( "CTX_LIGHT_COLOR_MAT_ENABLED ", struct gl_context, Light.ColorMaterialEnabled );
OFFSET( "CTX_LIGHT_ENABLED_LIST ", struct gl_context, Light.EnabledList );
OFFSET( "CTX_LIGHT_NEED_VERTS ", struct gl_context, Light._NeedVertices );