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. Set maximum frame rate in QML Animation
Qt 6.11 is out! See what's new in the release blog

Set maximum frame rate in QML Animation

Scheduled Pinned Locked Moved QML and Qt Quick
3 Posts 2 Posters 5.5k 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
    apap_
    wrote on last edited by
    #1

    Is it possible to set a maximum frame rate when using QML Animation ?
    This would be very useful (especially on embedded platform).

    1 Reply Last reply
    0
    • L Offline
      L Offline
      ludde
      wrote on last edited by
      #2

      Been thinking about this too. I guess a maximum frame rate setting is kind of hard to support. But, if there was a way to control animations so that you could somehow tell the animation how many intermediate values to use, this would be a way to indirectly control the frame rate. Haven't found any way to do that either, though...

      1 Reply Last reply
      0
      • L Offline
        L Offline
        ludde
        wrote on last edited by
        #3

        Had another look at this, and found that QTimeLine (which is used by the animation framework, which I assume is what QML uses for animations) has an updateInterval property, which is the time between two value updates / frames. By default it is 40ms, which gives a frame rate of 25 fps. Sadly, I have not found a way to control the corresponding updateInterval of QML animations.

        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