mesa: Use assert() instead of ASSERT wrapper.
Acked-by: Eric Anholt <eric@anholt.net>
This commit is contained in:
@@ -58,9 +58,9 @@ _mesa_fetch_state(struct gl_context *ctx, const gl_state_index state[],
|
||||
/* state[1] is either 0=front or 1=back side */
|
||||
const GLuint face = (GLuint) state[1];
|
||||
const struct gl_material *mat = &ctx->Light.Material;
|
||||
ASSERT(face == 0 || face == 1);
|
||||
assert(face == 0 || face == 1);
|
||||
/* we rely on tokens numbered so that _BACK_ == _FRONT_+ 1 */
|
||||
ASSERT(MAT_ATTRIB_FRONT_AMBIENT + 1 == MAT_ATTRIB_BACK_AMBIENT);
|
||||
assert(MAT_ATTRIB_FRONT_AMBIENT + 1 == MAT_ATTRIB_BACK_AMBIENT);
|
||||
/* XXX we could get rid of this switch entirely with a little
|
||||
* work in arbprogparse.c's parse_state_single_item().
|
||||
*/
|
||||
@@ -170,7 +170,7 @@ _mesa_fetch_state(struct gl_context *ctx, const gl_state_index state[],
|
||||
const GLuint ln = (GLuint) state[1];
|
||||
const GLuint face = (GLuint) state[2];
|
||||
GLint i;
|
||||
ASSERT(face == 0 || face == 1);
|
||||
assert(face == 0 || face == 1);
|
||||
switch (state[3]) {
|
||||
case STATE_AMBIENT:
|
||||
for (i = 0; i < 3; i++) {
|
||||
@@ -295,8 +295,8 @@ _mesa_fetch_state(struct gl_context *ctx, const gl_state_index state[],
|
||||
const gl_state_index modifier = state[4];
|
||||
const GLfloat *m;
|
||||
GLuint row, i;
|
||||
ASSERT(firstRow < 4);
|
||||
ASSERT(lastRow < 4);
|
||||
assert(firstRow < 4);
|
||||
assert(lastRow < 4);
|
||||
if (mat == STATE_MODELVIEW_MATRIX) {
|
||||
matrix = ctx->ModelviewMatrixStack.Top;
|
||||
}
|
||||
@@ -307,11 +307,11 @@ _mesa_fetch_state(struct gl_context *ctx, const gl_state_index state[],
|
||||
matrix = &ctx->_ModelProjectMatrix;
|
||||
}
|
||||
else if (mat == STATE_TEXTURE_MATRIX) {
|
||||
ASSERT(index < Elements(ctx->TextureMatrixStack));
|
||||
assert(index < Elements(ctx->TextureMatrixStack));
|
||||
matrix = ctx->TextureMatrixStack[index].Top;
|
||||
}
|
||||
else if (mat == STATE_PROGRAM_MATRIX) {
|
||||
ASSERT(index < Elements(ctx->ProgramMatrixStack));
|
||||
assert(index < Elements(ctx->ProgramMatrixStack));
|
||||
matrix = ctx->ProgramMatrixStack[index].Top;
|
||||
}
|
||||
else {
|
||||
|
Reference in New Issue
Block a user