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. Memory usage increases with window size?
Qt 6.11 is out! See what's new in the release blog

Memory usage increases with window size?

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 3 Posters 996 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.
  • oPryzeLPO Offline
    oPryzeLPO Offline
    oPryzeLP
    wrote on last edited by oPryzeLP
    #1

    I've noticed that memory usage on Qt applications increases proportionally to the size of the window. For example, maximizing a window on a 4k screen increases memory usage by ~30Mb. I found a stackoverflow question on this same topic but it is dated for 2013 and I believe is outdated (https://stackoverflow.com/questions/14211976/qt5-memory-usage-depends-on-window-size).

    The answers simply explains it away as a 'Qt thing' due to how Qt draws things, which is fair, however I noticed that other applications don't do this, even though they are graphically 'heavier'. I'm guessing they employ some newer tech that I'm unaware of (I'm using Qt 5.6 for clarification.)

    What is the difference between Qt applications and other applications (notepad++, photoshop, game launchers, vs code, basically I haven't found another application that behaves like a Qt app) that causes this memory-expensive behavior? Bonus points if I could make it go away haha.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      The answer is likely the raster engine of the widgets module and the age of your Qt version.

      You should consider updating to something more recent that has high DPI support to compare.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      oPryzeLPO 1 Reply Last reply
      0
      • JoeCFDJ Offline
        JoeCFDJ Offline
        JoeCFD
        wrote on last edited by JoeCFD
        #3

        Just tested it. I started my app with different window sizes on the same machine and did see memory use up with bigger display. Are you bothered by 30MB more memory use? It is not much.

        oPryzeLPO 1 Reply Last reply
        0
        • SGaistS SGaist

          Hi,

          The answer is likely the raster engine of the widgets module and the age of your Qt version.

          You should consider updating to something more recent that has high DPI support to compare.

          oPryzeLPO Offline
          oPryzeLPO Offline
          oPryzeLP
          wrote on last edited by
          #4

          @SGaist said in Memory usage increases with window size?:

          Hi,

          The answer is likely the raster engine of the widgets module and the age of your Qt version.

          You should consider updating to something more recent that has high DPI support to compare.

          I can't, I need to compile with MSVC2010 and 5.6 is the latest version that supports it from what I've read.

          1 Reply Last reply
          0
          • JoeCFDJ JoeCFD

            Just tested it. I started my app with different window sizes on the same machine and did see memory use up with bigger display. Are you bothered by 30MB more memory use? It is not much.

            oPryzeLPO Offline
            oPryzeLPO Offline
            oPryzeLP
            wrote on last edited by
            #5
            This post is deleted!
            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