diff options
author | Thomas Hindoe Paaboel Andersen <[email protected]> | 2016-02-22 15:58:00 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2016-02-23 08:55:35 -0700 |
commit | 1807806add36327ba1e713c49554b61b2855d5f9 (patch) | |
tree | b91e7eff55d5b886568e17336c9f374bd118e322 /src/mesa/main/readpix.c | |
parent | 190a291b03f799471110f95ae8a4d519d309696d (diff) |
mesa: use sizeof on the correct type
Before the luminance stride was based on the size of GL_FLOAT
which is just the type constant (0x1406). Change it to use the
size of GLfloat.
Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'src/mesa/main/readpix.c')
-rw-r--r-- | src/mesa/main/readpix.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/main/readpix.c b/src/mesa/main/readpix.c index 470182ab23d..882d863c1c7 100644 --- a/src/mesa/main/readpix.c +++ b/src/mesa/main/readpix.c @@ -582,7 +582,7 @@ read_rgba_pixels( struct gl_context *ctx, void *luminance; uint32_t luminance_format; - luminance_stride = width * sizeof(GL_FLOAT); + luminance_stride = width * sizeof(GLfloat); if (format == GL_LUMINANCE_ALPHA) luminance_stride *= 2; luminance_bytes = height * luminance_stride; |