projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ee8d182
)
Use proper source row stride when getting depth/stencil texels.
author
Michel Dänzer
<daenzer@vmware.com>
Wed, 30 Mar 2011 07:02:21 +0000
(09:02 +0200)
committer
Michel Dänzer
<daenzer@vmware.com>
Wed, 30 Mar 2011 07:31:21 +0000
(09:31 +0200)
src/mesa/main/texgetimage.c
patch
|
blob
|
history
diff --git
a/src/mesa/main/texgetimage.c
b/src/mesa/main/texgetimage.c
index 21d9140c5507d48fc8b490ef8c4a82b171c00fa2..db2cc840e5e2c13cad19f277099453de158f0396 100644
(file)
--- a/
src/mesa/main/texgetimage.c
+++ b/
src/mesa/main/texgetimage.c
@@
-159,6
+159,7
@@
get_tex_depth_stencil(struct gl_context *ctx, GLuint dimensions,
const GLint width = texImage->Width;
const GLint height = texImage->Height;
const GLint depth = texImage->Depth;
+ const GLint rowstride = texImage->RowStride;
const GLuint *src = (const GLuint *) texImage->Data;
GLint img, row;
@@
-172,7
+173,7
@@
get_tex_depth_stencil(struct gl_context *ctx, GLuint dimensions,
_mesa_swap4((GLuint *) dest, width);
}
- src +=
width * row + width * height * img
;
+ src +=
rowstride
;
}
}
}