Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-32298

The canvas component method getImageData() will not release the frame buffer from system memory.

    XMLWordPrintable

Details

    Description

      The below snippet will eat memory every time the timer is triggered. Garbage collection is not acting as a mediator either.

      import QtQuick 2.0
      
      Item {
          width: 400
          height: 400
      
          Canvas {
              id: canvas
              renderStrategy: Canvas.Immediate
              anchors.fill: parent
              onPaint: { }
          }
      
          Timer {
              running: true
              interval: 100
              repeat: true
              onTriggered: canvas.getContext("2d").getImageData(0, 0, canvas.width, canvas.height)
          }
      }
      

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            surgemcgee Robert Steckroth
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes