Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt 6.8 QML resize Jitter, bad performance

Qt 6.8 QML resize Jitter, bad performance

Scheduled Pinned Locked Moved Unsolved General and Desktop
1 Posts 1 Posters 258 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    Edoardo_P
    wrote on last edited by
    #1

    Hi,
    I am developing on windows 10 a Qt 6.8 application with Qt Quick and I am encountering some problems. I wrote the following code, but I can't get it to work properly and it gives me the error you can see in the gif below:

    video-ezgif.com-video-to-gif-converter (3).gif

    I'm using windows 10 and this is the full code:
    main.qml

    import QtQuick
    import QtQuick.Window
    import QtQuick.Controls
    Window {
        color: "white"
    
    
        width: 1280
        height: 720
    
        visible: true
    
    }
    

    main.cpp

    #include <QApplication>
    #include <QDateTime>
    #include <QDir>
    #include <QGuiApplication>
    #include <QQmlApplicationEngine>
    #include <QQmlContext>
    #include <QStandardPaths>
    #include <QString>
    #include <QTextStream>
    #include <QVector>
    
    int main(int argc, char *argv[])
    {
    #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
        QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
        QCoreApplication::setAttribute(Qt::AA_UseHighDpiPixmaps); //HiDPI pixmaps
    #endif
        QApplication app(argc, argv);
    
        QQmlApplicationEngine engine;
    
        const QUrl url(QStringLiteral("qrc:/main.qml"));
    
        QObject::connect(&engine, &QQmlApplicationEngine::objectCreated,
                         &app, [url](QObject *obj, const QUrl &objUrl) {
            if (!obj && url == objUrl)
                QCoreApplication::exit(-1);
        }, Qt::QueuedConnection);
    
        engine.load(url);
        return app.exec();
    }
    
    

    project.pro

    QT      += quick
    CONFIG  += c++17
    QT      += qml
    QT      += network
    QT      += quickcontrols2
    QT      += widgets
    QT      += core gui
    QT      += multimedia
    
    
    DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x050F00
    
    # You can make your code fail to compile if it uses deprecated APIs.
    # In order to do so, uncomment the following line.
    #DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0
    
    CONFIG += app_bundle
    
    
    
    SOURCES += \
            main.cpp 
    
    RESOURCES   += ui.qrc
    
    # Additional import path used to resolve QML modules in Qt Creator's code model
    QML_IMPORT_PATH =
    
    # Additional import path used to resolve QML modules just for Qt Quick Designer
    QML_DESIGNER_IMPORT_PATH =
    
    # Default rules for deployment.
    qnx: target.path = /tmp/$${TARGET}/bin
    else: unix:!android: target.path = /opt/$${TARGET}/bin
    !isEmpty(target.path): INSTALLS += target
    
    HEADERS += 
    
    
    
    
    

    Do you have any suggestions on what I can correct or improve? Thank you in advance!

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved