[solved] Qt Quick 2 performance issues
-
Hello, I started a new project in which I need to render Qml content on an WQHD display (2560 x 1440).
And I'm still trying to get a pretty basic qml test to run fluently. But on the full resolution the rendering performance drops way below 10 fps.
The target system runs a AMD G-T56N dual core processor 1,6 GHz 3,5 GiB ram and a dedicated AMD Radeon HD 6310 graphics card.My qml Test is nothing more than this:
@import QtQuick 2.0Item {
id: grid_view
width: 800
height: 600Rectangle { id: grid_view_bg anchors.fill: parent ListModel { id: employee_model ListElement { name: "User 1"; } ListElement { name: "User 2"; } ListElement { name: "User 3"; } ListElement { name: "User 4"; } ListElement { name: "User 5"; } ListElement { name: "User 6"; } ListElement { name: "User 7"; } ListElement { name: "User 8"; } ListElement { name: "User 9"; } ListElement { name: "User 10"; } } Component { id: employeeDelegate Item { id:employeeContainer width: 180; height: 200 Rectangle { id:employeeBody anchors.fill: parent anchors.rightMargin: 5 color: "red" border.color: "black" Rectangle { id: employeeHeader z:101 color: "#bbdbf3" anchors.horizontalCenter: parent.horizontalCenter width: parent.width height: 40 Text { anchors.centerIn: parent text: '<b>Name:</b> ' + name } border.color: "black" } } } } ListView { anchors.fill: parent model: employee_model orientation: Qt.Horizontal delegate: employeeDelegate } }
}@
The main.cpp:
@QGuiApplication app(argc, argv);QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/untitled/main.qml")); viewer.show();
@
So I just used the predefined QtQuick 2 Application example to start with.
Even on my development system running an intel quad core with dedicated ATI Radeon HD 3450 the performance start to decrease at a 1920 x 1080 resolution. The higher the resolution gets the worse is the performance. At the full WQHD resolution it is just unusable.What might be the problem here ?
I would expect that qt is capable of a way better performance than what i get right now.
Both cards support at least OpenGL 3 or higher.
What can i do to get the qml animation on the list scrolling to run smooth.I could need some help with this one.
Thank you for any help. -
Are you using Qt 5.2? What OS are you on? Have you compiled Qt yourself (or maybe we are talking about an ANGLE build)?
I think in Qt 5.2 you can bump the version number to QtQuick 2.1, BTW.
-
Hi,
I'm using Qt 5.1.1 compiled by myself on Ubuntu on both systems.
May there be any performance difference between 5.1.1 and 5.2 ? -
Yes, the rendering engine has been significantly optimised (see "this":http://blog.qt.digia.com/blog/2013/09/02/new-scene-graph-renderer/ blog entry).
If possible, compile Qt with "-opengl desktop" flag. It will make the most of your GPU.
-
Ok thanks I'm going to compile Qt 5.2 with the opengl desktop flag and see what happens.
-
Hey thanks for the hint sierdzio.
It's amazing. On Qt5.2 the example runs so much better then with 5.1.1.
Awesome piece the new scene graph.Thumbs up.
-
hey, great! I'm happy that it helped you :)