qtdeclarative-5.0.2: Add 4 patches for runtime issues
* 3 backports from newer qtdeclarative: System Hang while moving App Ribbon Fix for segfault in some ListView Cases Make use of BGRA texture format to improve image upload time * 1 pending fix: Fix for ViewTransitions not working in horizontal ListViews Signed-off-by: Florian Haenel <florian.haenel@lge.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
This commit is contained in:
parent
46626d15cd
commit
e1223d648c
|
@ -0,0 +1,32 @@
|
|||
From eb11863cc40048e84cb383ae9e29b5929170a63d Mon Sep 17 00:00:00 2001
|
||||
From: Guenter Schwann <guenter.schwann@canonical.com>
|
||||
Date: Wed, 27 Feb 2013 15:52:03 +0100
|
||||
Subject: [PATCH 2/5] Fix displacement transition bug for horizontal case
|
||||
|
||||
Task-number: QTBUG-29944
|
||||
|
||||
Upstream-Status: Backport https://codereview.qt-project.org/49226
|
||||
Signed-off-by: Florian Haenel <florian.haenel@lge.com>
|
||||
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
|
||||
|
||||
Change-Id: I23381f7a1d2c8d3c6df007b5b11c12b0db3bb1e9
|
||||
---
|
||||
src/quick/items/qquickitemview.cpp | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/quick/items/qquickitemview.cpp b/src/quick/items/qquickitemview.cpp
|
||||
index b73fb8c..1c74288 100644
|
||||
--- a/src/quick/items/qquickitemview.cpp
|
||||
+++ b/src/quick/items/qquickitemview.cpp
|
||||
@@ -2115,7 +2115,7 @@ void QQuickItemViewPrivate::prepareVisibleItemTransitions()
|
||||
return;
|
||||
|
||||
// must call for every visible item to init or discard transitions
|
||||
- QRectF viewBounds(0, position(), q->width(), q->height());
|
||||
+ QRectF viewBounds(q->contentX(), q->contentY(), q->width(), q->height());
|
||||
for (int i=0; i<visibleItems.count(); i++)
|
||||
visibleItems[i]->prepareTransition(transitioner, viewBounds);
|
||||
}
|
||||
--
|
||||
1.8.2.1
|
||||
|
|
@ -0,0 +1,41 @@
|
|||
From 3dfa028b27e171cb2494b22f0346be1390310ea6 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20H=C3=A4nel?= <florian.haenel@basyskom.com>
|
||||
Date: Wed, 5 Jun 2013 19:23:32 +0200
|
||||
Subject: [PATCH 3/5] Fix wrong calculation of viewPort for transitions
|
||||
|
||||
Viewport is calculated wrong for horizontal layout in a second instance
|
||||
|
||||
Task-number: QTBUG-29944
|
||||
Task-Number: QTBUG-31546
|
||||
|
||||
Upstream-Status: Pending
|
||||
|
||||
Looks like backport of https://codereview.qt-project.org/49226 but this
|
||||
one was applied in previous patch, this change looks the same but is
|
||||
in different part of qquickitemview.cpp and ISN'T applied yet in dev
|
||||
branch.
|
||||
|
||||
Signed-off-by: Florian Haenel <florian.haenel@lge.com>
|
||||
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
|
||||
|
||||
Change-Id: I136ae4484278d14f796613505e3f38c65ec51ebe
|
||||
---
|
||||
src/quick/items/qquickitemview.cpp | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/quick/items/qquickitemview.cpp b/src/quick/items/qquickitemview.cpp
|
||||
index 1c74288..b316af9 100644
|
||||
--- a/src/quick/items/qquickitemview.cpp
|
||||
+++ b/src/quick/items/qquickitemview.cpp
|
||||
@@ -1816,7 +1816,7 @@ void QQuickItemViewPrivate::layout()
|
||||
|
||||
prepareVisibleItemTransitions();
|
||||
|
||||
- QRectF viewBounds(0, position(), q->width(), q->height());
|
||||
+ QRectF viewBounds(q->contentX(), q->contentY(), q->width(), q->height());
|
||||
for (QList<FxViewItem*>::Iterator it = releasePendingTransition.begin();
|
||||
it != releasePendingTransition.end(); ) {
|
||||
FxViewItem *item = *it;
|
||||
--
|
||||
1.8.2.1
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
From adb69cabeacbe14a4439473107000d6e94d8d033 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20H=C3=A4nel?= <florian.haenel@basyskom.com>
|
||||
Date: Mon, 3 Jun 2013 13:40:09 +0200
|
||||
Subject: [PATCH 4/5] Fix null-pointer access in QQuickVisualDataModelPrivate
|
||||
|
||||
I observed null cachItem->contextData which lead to null-pointer access
|
||||
on cacheItem->contextData->destroy().
|
||||
|
||||
Task-number: QTBUG-31439
|
||||
|
||||
Upstream-Status: Backport https://codereview.qt-project.org/57789
|
||||
|
||||
Signed-of-by: Florian Haenel <florian.haenel@lge.com>
|
||||
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
|
||||
|
||||
Change-Id: I91f28a3ee1ac83446ecde1801a1cb7962fb883f3
|
||||
---
|
||||
src/quick/items/qquickvisualdatamodel.cpp | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/quick/items/qquickvisualdatamodel.cpp b/src/quick/items/qquickvisualdatamodel.cpp
|
||||
index d2e50e8..a460e7f 100644
|
||||
--- a/src/quick/items/qquickvisualdatamodel.cpp
|
||||
+++ b/src/quick/items/qquickvisualdatamodel.cpp
|
||||
@@ -817,7 +817,8 @@ void QQuickVisualDataModelPrivate::incubatorStatusChanged(QVDMIncubationTask *in
|
||||
delete cacheItem->object;
|
||||
cacheItem->object = 0;
|
||||
cacheItem->scriptRef -= 1;
|
||||
- cacheItem->contextData->destroy();
|
||||
+ if (cacheItem->contextData)
|
||||
+ cacheItem->contextData->destroy();
|
||||
cacheItem->contextData = 0;
|
||||
if (!cacheItem->isReferenced()) {
|
||||
removeCacheItem(cacheItem);
|
||||
--
|
||||
1.8.2.1
|
||||
|
|
@ -0,0 +1,88 @@
|
|||
From 9d85c3c5823c6f73db245d4de786d911fd96edfd Mon Sep 17 00:00:00 2001
|
||||
From: Florian Haenel <florian.haenel@lge.com>
|
||||
Date: Sat, 8 Jun 2013 00:34:35 +0200
|
||||
Subject: [PATCH 5/5] Avoid swizzling on OpenGL ES when possible
|
||||
|
||||
Add support for APPLE_texture_format_BGRA8888,
|
||||
IMG_texture_format_BGRA8888,
|
||||
EXT_texture_format_BGRA8888 and EXT_bgra. The apple one acts
|
||||
just like the desktop EXT_bgra one, so they need slightly
|
||||
different handling than the ES extensions.
|
||||
|
||||
This change also has the benefit that we no longer have a dedicated
|
||||
ES path.
|
||||
|
||||
Upstream-Status: Backport https://codereview.qt-project.org/46549
|
||||
Signed-off-by: Florian Haenel <florian.haenel@lge.com>
|
||||
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
|
||||
|
||||
Change-Id: I5ecb0a02c3a7bd984d6752fa87163726118b93de
|
||||
---
|
||||
src/quick/scenegraph/util/qsgtexture.cpp | 28 ++++++++++++++++++++++------
|
||||
1 file changed, 22 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/src/quick/scenegraph/util/qsgtexture.cpp b/src/quick/scenegraph/util/qsgtexture.cpp
|
||||
index 16cc461..3d574f3 100644
|
||||
--- a/src/quick/scenegraph/util/qsgtexture.cpp
|
||||
+++ b/src/quick/scenegraph/util/qsgtexture.cpp
|
||||
@@ -65,6 +65,10 @@
|
||||
#include <QHash>
|
||||
#endif
|
||||
|
||||
+#ifndef GL_BGRA
|
||||
+#define GL_BGRA 0x80E1
|
||||
+#endif
|
||||
+
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
inline static bool isPowerOfTwo(int x)
|
||||
@@ -523,7 +527,6 @@ QSGPlainTexture::~QSGPlainTexture()
|
||||
glDeleteTextures(1, &m_texture_id);
|
||||
}
|
||||
|
||||
-#ifdef QT_OPENGL_ES
|
||||
void qsg_swizzleBGRAToRGBA(QImage *image)
|
||||
{
|
||||
const int width = image->width();
|
||||
@@ -534,7 +537,6 @@ void qsg_swizzleBGRAToRGBA(QImage *image)
|
||||
p[x] = ((p[x] << 16) & 0xff0000) | ((p[x] >> 16) & 0xff) | (p[x] & 0xff00ff00);
|
||||
}
|
||||
}
|
||||
-#endif
|
||||
|
||||
void QSGPlainTexture::setImage(const QImage &image)
|
||||
{
|
||||
@@ -621,12 +623,26 @@ void QSGPlainTexture::bind()
|
||||
|
||||
updateBindOptions(m_dirty_bind_options);
|
||||
|
||||
+ GLenum externalFormat = GL_RGBA;
|
||||
+ GLenum internalFormat = GL_RGBA;
|
||||
+
|
||||
+ const char *extensions = (const char *) glGetString(GL_EXTENSIONS);
|
||||
+ if (strstr(extensions, "GL_EXT_bgra")) {
|
||||
+ externalFormat = GL_BGRA;
|
||||
#ifdef QT_OPENGL_ES
|
||||
- qsg_swizzleBGRAToRGBA(&tmp);
|
||||
- glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, w, h, 0, GL_RGBA, GL_UNSIGNED_BYTE, tmp.constBits());
|
||||
-#else
|
||||
- glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, w, h, 0, GL_BGRA, GL_UNSIGNED_BYTE, tmp.constBits());
|
||||
+ internalFormat = GL_BGRA;
|
||||
#endif
|
||||
+ } else if (strstr(extensions, "GL_APPLE_texture_format_BGRA8888")) {
|
||||
+ externalFormat = GL_BGRA;
|
||||
+ } else if (strstr(extensions, "GL_EXT_texture_format_BGRA8888")
|
||||
+ || strstr(extensions, "GL_IMG_texture_format_BGRA8888")) {
|
||||
+ externalFormat = GL_BGRA;
|
||||
+ internalFormat = GL_BGRA;
|
||||
+ } else {
|
||||
+ qsg_swizzleBGRAToRGBA(&tmp);
|
||||
+ }
|
||||
+
|
||||
+ glTexImage2D(GL_TEXTURE_2D, 0, internalFormat, w, h, 0, externalFormat, GL_UNSIGNED_BYTE, tmp.constBits());
|
||||
|
||||
if (m_has_mipmaps) {
|
||||
QOpenGLContext *ctx = QOpenGLContext::currentContext();
|
||||
--
|
||||
1.8.2.1
|
||||
|
|
@ -5,6 +5,10 @@ PR = "${INC_PR}.0"
|
|||
|
||||
SRC_URI += " \
|
||||
file://0001-qmltestexample-fix-link.patch \
|
||||
file://0002-Fix-displacement-transition-bug-for-horizontal-case.patch \
|
||||
file://0003-Fix-wrong-calculation-of-viewPort-for-transitions.patch \
|
||||
file://0004-Fix-null-pointer-access-in-QQuickVisualDataModelPriv.patch \
|
||||
file://0005-Avoid-swizzling-on-OpenGL-ES-when-possible.patch \
|
||||
"
|
||||
|
||||
SRC_URI[md5sum] = "55ab45a7a17db5b202b225603a35a37c"
|
||||
|
|
Loading…
Reference in New Issue