summaryrefslogtreecommitdiff
path: root/src/mesa/swrast/s_readpix.c
diff options
context:
space:
mode:
authorBrian <brian@yutani.localnet.net>2007-02-22 08:53:33 -0700
committerBrian <brian@yutani.localnet.net>2007-02-22 08:53:33 -0700
commit29c471aafc6a3fef23d553e31a555d1782854a77 (patch)
tree335385fd55d510118346136c6feb4daa707988b6 /src/mesa/swrast/s_readpix.c
parent6d4cf6be4e79c3a6ab18272577df17389e3834a6 (diff)
parenta4b344baa2484c65a1618f3cce3a94c91dea8ef7 (diff)
Merge branch 'origin' into glsl-compiler-1
Conflicts: src/mesa/main/state.c src/mesa/shader/program.c src/mesa/shader/program.h src/mesa/shader/programopt.c src/mesa/shader/slang/slang_execute.c src/mesa/sources src/mesa/swrast/s_arbshader.c src/mesa/swrast/s_context.c src/mesa/swrast/s_span.c src/mesa/swrast/s_zoom.c src/mesa/tnl/t_context.c src/mesa/tnl/t_save_api.c src/mesa/tnl/t_vb_arbprogram.c src/mesa/tnl/t_vp_build.c src/mesa/tnl/t_vtx_eval.c
Diffstat (limited to 'src/mesa/swrast/s_readpix.c')
-rw-r--r--src/mesa/swrast/s_readpix.c23
1 files changed, 13 insertions, 10 deletions
diff --git a/src/mesa/swrast/s_readpix.c b/src/mesa/swrast/s_readpix.c
index 75134ab462..a7b25a4633 100644
--- a/src/mesa/swrast/s_readpix.c
+++ b/src/mesa/swrast/s_readpix.c
@@ -94,8 +94,8 @@ read_depth_pixels( GLcontext *ctx,
/* clipping should have been done already */
ASSERT(x >= 0);
ASSERT(y >= 0);
- ASSERT(x + width <= rb->Width);
- ASSERT(y + height <= rb->Height);
+ ASSERT(x + width <= (GLint) rb->Width);
+ ASSERT(y + height <= (GLint) rb->Height);
/* width should never be > MAX_WIDTH since we did clipping earlier */
ASSERT(width <= MAX_WIDTH);
@@ -210,8 +210,8 @@ fast_read_rgba_pixels( GLcontext *ctx,
ASSERT(rb->_BaseFormat == GL_RGBA || rb->_BaseFormat == GL_RGB);
/* clipping should have already been done */
- ASSERT(x + width <= rb->Width);
- ASSERT(y + height <= rb->Height);
+ ASSERT(x + width <= (GLint) rb->Width);
+ ASSERT(y + height <= (GLint) rb->Height);
/* check for things we can't handle here */
if (transferOps ||
@@ -223,8 +223,9 @@ fast_read_rgba_pixels( GLcontext *ctx,
if (format == GL_RGBA && rb->DataType == type) {
const GLint dstStride = _mesa_image_row_stride(packing, width,
format, type);
- GLubyte *dest = _mesa_image_address2d(packing, pixels, width, height,
- format, type, 0, 0);
+ GLubyte *dest
+ = (GLubyte *) _mesa_image_address2d(packing, pixels, width, height,
+ format, type, 0, 0);
GLint row;
ASSERT(rb->GetRow);
for (row = 0; row < height; row++) {
@@ -239,8 +240,9 @@ fast_read_rgba_pixels( GLcontext *ctx,
type == GL_UNSIGNED_BYTE) {
const GLint dstStride = _mesa_image_row_stride(packing, width,
format, type);
- GLubyte *dest = _mesa_image_address2d(packing, pixels, width, height,
- format, type, 0, 0);
+ GLubyte *dest
+ = (GLubyte *) _mesa_image_address2d(packing, pixels, width, height,
+ format, type, 0, 0);
GLint row;
ASSERT(rb->GetRow);
for (row = 0; row < height; row++) {
@@ -396,8 +398,9 @@ read_rgba_pixels( GLcontext *ctx,
= _mesa_image_row_stride(packing, width, format, type);
GLfloat (*rgba)[4] = swrast->SpanArrays->attribs[FRAG_ATTRIB_COL0];
GLint row;
- GLubyte *dst = _mesa_image_address2d(packing, pixels, width, height,
- format, type, 0, 0);
+ GLubyte *dst
+ = (GLubyte *) _mesa_image_address2d(packing, pixels, width, height,
+ format, type, 0, 0);
for (row = 0; row < height; row++, y++) {