[SOLVED] QQmlApplicationEngine/QQuickWindow slower than qmlscene



  • I have an application that sets some dynamic properties in a qml scene. The qml document has several nested XmlListModels. When the window is shown, the data seems to stream in and layout slowly, while qmlscene on the same files is quite a bit faster. I notice qmlscene CPU usage hits 13% which is spiking one cpu core, while the slower application goes up to 25%, spiking two cpu cores. At first glance Qt Creator QML profiler doesn't appear to show anything out of the ordinary. This is a bit of the code, the rest of the application is too large to post here. Is there something common I should watch out for here? Thanks!

    @
    QQmlApplicationEngine* engine = new QQmlApplicationEngine(this);
    engine->load(QUrl("qrc:/ReportViewer.qml"));
    QObject *topLevel = engine->rootObjects().value(0);
    QQuickWindow window = qobject_cast<QQuickWindow >(topLevel);
    window->setProperty("report", "qrc:/Report.qml");
    QObject
    item = window->findChild<QObject
    >("reportObject");
    item->setProperty("dataSource", "data.xml");
    window->show();
    @



  • I think it was just the qml debugger running under Qt Creator. Once I ran a release build it was quick again.


  • Moderators

    If you need no more help on this issue, please add [solved] to the topic so everyone can see that this problem is solved. You can do that by editing your first post.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.