projects
/
profile
/
ivi
/
qtdeclarative.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c0da786
)
Set bind options before uploading to give hints to the driver
author
Gunnar Sletta
<gunnar.sletta@nokia.com>
Thu, 1 Mar 2012 11:34:48 +0000
(12:34 +0100)
committer
Qt by Nokia
<qt-info@nokia.com>
Thu, 1 Mar 2012 12:26:10 +0000
(13:26 +0100)
This can prevent allocation of unused mipmap levels on some
drivers.
Change-Id: I2d730c04e120872367078b17a344c01b4d4aa87a
Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
src/quick/scenegraph/util/qsgtexture.cpp
patch
|
blob
|
history
diff --git
a/src/quick/scenegraph/util/qsgtexture.cpp
b/src/quick/scenegraph/util/qsgtexture.cpp
index
7ccedc4
..
4dff1b2
100644
(file)
--- a/
src/quick/scenegraph/util/qsgtexture.cpp
+++ b/
src/quick/scenegraph/util/qsgtexture.cpp
@@
-496,6
+496,8
@@
void QSGPlainTexture::bind()
? m_image
: m_image.convertToFormat(QImage::Format_ARGB32_Premultiplied);
+ updateBindOptions(m_dirty_bind_options);
+
#ifdef QT_OPENGL_ES
swizzleBGRAToRGBA(&tmp);
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, w, h, 0, GL_RGBA, GL_UNSIGNED_BYTE, tmp.constBits());
@@
-512,7
+514,6
@@
void QSGPlainTexture::bind()
m_texture_size = QSize(w, h);
m_texture_rect = QRectF(0, 0, 1, 1);
- updateBindOptions(m_dirty_bind_options);
m_dirty_bind_options = false;
}