casts to fix some -pedantic warnings
This commit is contained in:
@@ -391,6 +391,8 @@ test_attachment_completeness(const GLcontext *ctx, GLenum format,
|
|||||||
static void
|
static void
|
||||||
fbo_incomplete(const char *msg, int index)
|
fbo_incomplete(const char *msg, int index)
|
||||||
{
|
{
|
||||||
|
(void) msg;
|
||||||
|
(void) index;
|
||||||
/*
|
/*
|
||||||
_mesa_debug(NULL, "FBO Incomplete: %s [%d]\n", msg, index);
|
_mesa_debug(NULL, "FBO Incomplete: %s [%d]\n", msg, index);
|
||||||
*/
|
*/
|
||||||
@@ -751,12 +753,12 @@ _mesa_RenderbufferStorageEXT(GLenum target, GLenum internalFormat,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (width < 1 || width > ctx->Const.MaxRenderbufferSize) {
|
if (width < 1 || width > (GLsizei) ctx->Const.MaxRenderbufferSize) {
|
||||||
_mesa_error(ctx, GL_INVALID_VALUE, "glRenderbufferStorageEXT(width)");
|
_mesa_error(ctx, GL_INVALID_VALUE, "glRenderbufferStorageEXT(width)");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (height < 1 || height > ctx->Const.MaxRenderbufferSize) {
|
if (height < 1 || height > (GLsizei) ctx->Const.MaxRenderbufferSize) {
|
||||||
_mesa_error(ctx, GL_INVALID_VALUE, "glRenderbufferStorageEXT(height)");
|
_mesa_error(ctx, GL_INVALID_VALUE, "glRenderbufferStorageEXT(height)");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -771,8 +773,8 @@ _mesa_RenderbufferStorageEXT(GLenum target, GLenum internalFormat,
|
|||||||
FLUSH_VERTICES(ctx, _NEW_BUFFERS);
|
FLUSH_VERTICES(ctx, _NEW_BUFFERS);
|
||||||
|
|
||||||
if (rb->InternalFormat == internalFormat &&
|
if (rb->InternalFormat == internalFormat &&
|
||||||
rb->Width == width &&
|
rb->Width == (GLuint) width &&
|
||||||
rb->Height == height) {
|
rb->Height == (GLuint) height) {
|
||||||
/* no change in allocation needed */
|
/* no change in allocation needed */
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -792,8 +794,8 @@ _mesa_RenderbufferStorageEXT(GLenum target, GLenum internalFormat,
|
|||||||
if (rb->AllocStorage(ctx, rb, internalFormat, width, height)) {
|
if (rb->AllocStorage(ctx, rb, internalFormat, width, height)) {
|
||||||
/* No error - check/set fields now */
|
/* No error - check/set fields now */
|
||||||
assert(rb->_ActualFormat);
|
assert(rb->_ActualFormat);
|
||||||
assert(rb->Width == width);
|
assert(rb->Width == (GLuint) width);
|
||||||
assert(rb->Height == height);
|
assert(rb->Height == (GLuint) height);
|
||||||
assert(rb->RedBits || rb->GreenBits || rb->BlueBits || rb->AlphaBits ||
|
assert(rb->RedBits || rb->GreenBits || rb->BlueBits || rb->AlphaBits ||
|
||||||
rb->DepthBits || rb->StencilBits || rb->IndexBits);
|
rb->DepthBits || rb->StencilBits || rb->IndexBits);
|
||||||
rb->InternalFormat = internalFormat;
|
rb->InternalFormat = internalFormat;
|
||||||
|
@@ -259,7 +259,7 @@ struct ureg {
|
|||||||
GLuint pad:5;
|
GLuint pad:5;
|
||||||
};
|
};
|
||||||
|
|
||||||
const static struct ureg undef = {
|
static const struct ureg undef = {
|
||||||
~0,
|
~0,
|
||||||
~0,
|
~0,
|
||||||
0,
|
0,
|
||||||
@@ -342,7 +342,7 @@ static GLboolean is_undef( struct ureg reg )
|
|||||||
|
|
||||||
static struct ureg get_temp( struct texenv_fragment_program *p )
|
static struct ureg get_temp( struct texenv_fragment_program *p )
|
||||||
{
|
{
|
||||||
int bit;
|
GLint bit;
|
||||||
|
|
||||||
/* First try and reuse temps which have been used already:
|
/* First try and reuse temps which have been used already:
|
||||||
*/
|
*/
|
||||||
@@ -358,7 +358,7 @@ static struct ureg get_temp( struct texenv_fragment_program *p )
|
|||||||
_mesa_exit(1);
|
_mesa_exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bit > p->program->Base.NumTemporaries)
|
if ((GLuint) bit > p->program->Base.NumTemporaries)
|
||||||
p->program->Base.NumTemporaries = bit;
|
p->program->Base.NumTemporaries = bit;
|
||||||
|
|
||||||
p->temp_in_use |= 1<<(bit-1);
|
p->temp_in_use |= 1<<(bit-1);
|
||||||
@@ -386,7 +386,7 @@ static struct ureg get_tex_temp( struct texenv_fragment_program *p )
|
|||||||
_mesa_exit(1);
|
_mesa_exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bit > p->program->Base.NumTemporaries)
|
if ((GLuint) bit > p->program->Base.NumTemporaries)
|
||||||
p->program->Base.NumTemporaries = bit;
|
p->program->Base.NumTemporaries = bit;
|
||||||
|
|
||||||
p->temp_in_use |= 1<<(bit-1);
|
p->temp_in_use |= 1<<(bit-1);
|
||||||
|
Reference in New Issue
Block a user