summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-02-24 04:45:58 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-02-24 04:45:58 (GMT)
commita87b7b965a68fbb3171ffedeb3354f14c60d1751 (patch)
tree9943e846fd652867c842ae37d7e329ab45d86e67
parenta3a55ff296a15ec0c69990f3526eaa652a216d2f (diff)
parent97b2bfdbe1b242b2d7cdd88ce3648388e8764e1c (diff)
downloadQt-a87b7b965a68fbb3171ffedeb3354f14c60d1751.zip
Qt-a87b7b965a68fbb3171ffedeb3354f14c60d1751.tar.gz
Qt-a87b7b965a68fbb3171ffedeb3354f14c60d1751.tar.bz2
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.6-integration
* '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-2: Fix off-by-one error in mipmap count when loading PVRTC files
-rw-r--r--src/opengl/qgl.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/opengl/qgl.cpp b/src/opengl/qgl.cpp
index 22b0602..ca898c7 100644
--- a/src/opengl/qgl.cpp
+++ b/src/opengl/qgl.cpp
@@ -5451,7 +5451,7 @@ QSize QGLTexture::bindCompressedTexturePVR(const char *buf, int len)
quint32 level = 0;
quint32 width = pvrHeader->width;
quint32 height = pvrHeader->height;
- while (bufferSize > 0 && level < pvrHeader->mipMapCount) {
+ while (bufferSize > 0 && level <= pvrHeader->mipMapCount) {
quint32 size =
(qMax(width, minWidth) * qMax(height, minHeight) *
pvrHeader->bitsPerPixel) / 8;