diff options
author | Kenneth Graunke <kenneth@whitecape.org> | 2011-10-07 12:26:50 -0700 |
---|---|---|
committer | Kenneth Graunke <kenneth@whitecape.org> | 2011-10-18 11:38:39 -0700 |
commit | 2e5a1a254ed81b1d3efa6064f48183eefac784d0 (patch) | |
tree | 0aba873855392f49ad3123c91f97ac2b3789a8eb /src/mesa/drivers/dri/intel/intel_tex_copy.c | |
parent | 1b45d68c117d716adb488dcaac16e0834e2471ba (diff) |
intel: Convert from GLboolean to 'bool' from stdbool.h.
I initially produced the patch using this bash command:
for file in {intel,i915,i965}/*.{c,cpp,h}; do [ ! -h $file ] && sed -i
's/GLboolean/bool/g' $file && sed -i 's/GL_TRUE/true/g' $file && sed -i
's/GL_FALSE/false/g' $file; done
Then I manually added #include <stdbool.h> to fix compilation errors,
and converted a few functions back to GLboolean that were used in core
Mesa's function pointer table to avoid "incompatible pointer" warnings.
Finally, I cleaned up some whitespace issues introduced by the change.
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Chad Versace <chad@chad-versace.us>
Acked-by: Paul Berry <stereotype441@gmail.com>
Diffstat (limited to 'src/mesa/drivers/dri/intel/intel_tex_copy.c')
-rw-r--r-- | src/mesa/drivers/dri/intel/intel_tex_copy.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_tex_copy.c b/src/mesa/drivers/dri/intel/intel_tex_copy.c index 907ce7f9b10..2df4ef6a7f6 100644 --- a/src/mesa/drivers/dri/intel/intel_tex_copy.c +++ b/src/mesa/drivers/dri/intel/intel_tex_copy.c @@ -63,7 +63,7 @@ get_teximage_readbuffer(struct intel_context *intel, GLenum internalFormat) } -GLboolean +bool intel_copy_texsubimage(struct intel_context *intel, struct intel_texture_image *intelImage, GLint dstx, GLint dsty, @@ -82,7 +82,7 @@ intel_copy_texsubimage(struct intel_context *intel, if (unlikely(INTEL_DEBUG & DEBUG_FALLBACKS)) fprintf(stderr, "%s fail %p %p (0x%08x)\n", __FUNCTION__, intelImage->mt, irb, internalFormat); - return GL_FALSE; + return false; } copy_supported = intelImage->base.Base.TexFormat == irb->Base.Format; @@ -105,7 +105,7 @@ intel_copy_texsubimage(struct intel_context *intel, __FUNCTION__, _mesa_get_format_name(intelImage->base.Base.TexFormat), _mesa_get_format_name(irb->Base.Format)); - return GL_FALSE; + return false; } { @@ -121,7 +121,7 @@ intel_copy_texsubimage(struct intel_context *intel, /* The blitter can't handle Y-tiled buffers. */ if (intelImage->mt->region->tiling == I915_TILING_Y) { - return GL_FALSE; + return false; } if (ctx->ReadBuffer->Name == 0) { @@ -148,14 +148,14 @@ intel_copy_texsubimage(struct intel_context *intel, image_x + dstx, image_y + dsty, width, height, GL_COPY)) { - return GL_FALSE; + return false; } } if (copy_supported_with_alpha_override) intel_set_teximage_alpha_to_one(ctx, intelImage); - return GL_TRUE; + return true; } |