Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Bad ApplicationWindow dragging performance

Bad ApplicationWindow dragging performance

Scheduled Pinned Locked Moved Solved QML and Qt Quick
2 Posts 2 Posters 448 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.
  • A Offline
    A Offline
    aworl
    wrote on last edited by
    #1

    Application windows in Qt 6 (I believe this didn't happen before) have abysmal dragging performance, being very noticeably laggy (maybe around 20 fps but with very inconsistent timings). This was tested on Qt 6 on Windows, on a default "Hello world" Qt Quick project, altough it happens with every single project I've tested. It does not happen on Qt Widgets at all.
    When I went to record the behaviour as well as a comparison to the expected behaviour as seen in Qt Widgets, I realised the problem temporarily goes away when recording with GPU acceleration using ShadowPlay. So it doesn't happen when the GPU is seeing continuous load, nor with Widgets (as it doesn't do GPU rendering) so it's probably something about the GPU falling into a lower power mode while dragging the window.
    Is this a known issue? Is there any way to fix it?

    Chris KawaC 1 Reply Last reply
    0
    • A aworl

      Application windows in Qt 6 (I believe this didn't happen before) have abysmal dragging performance, being very noticeably laggy (maybe around 20 fps but with very inconsistent timings). This was tested on Qt 6 on Windows, on a default "Hello world" Qt Quick project, altough it happens with every single project I've tested. It does not happen on Qt Widgets at all.
      When I went to record the behaviour as well as a comparison to the expected behaviour as seen in Qt Widgets, I realised the problem temporarily goes away when recording with GPU acceleration using ShadowPlay. So it doesn't happen when the GPU is seeing continuous load, nor with Widgets (as it doesn't do GPU rendering) so it's probably something about the GPU falling into a lower power mode while dragging the window.
      Is this a known issue? Is there any way to fix it?

      Chris KawaC Offline
      Chris KawaC Offline
      Chris Kawa
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Widgets use software rendering while QML is GPU accelerated.
      Are you maybe running your app on a CPU with integrated graphics? If that's the case then it probably defaults to using that instead of the discrete one. When using ShadowPlay it forces NVIDIA GPU, as that's what ShadowPlay works with.

      You can open NVIDIA control panel and set the preferred GPU either globally for all apps or just for yours. There's also performance and power saving settings options there that might be affecting you.

      Also, if you're using MSVC, you can add this magic incantation at the start of the app:

      extern "C" 
      {
        __declspec(dllexport) unsigned long NvOptimusEnablement = 1;
        __declspec(dllexport) int AmdPowerXpressRequestHighPerformance = 1;
      }
      

      This is the NVIDIA and AMD suggested way of hinting to the drivers that you want to use discrete GPU if multiple graphics processors are available.

      1 Reply Last reply
      1
      • A aworl has marked this topic as solved on

      • Login

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