Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-1572

Request for QPainter.drawPixmapNp(PyArrayObject*, QPixmap)

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Out of scope
    • Not Evaluated
    • None
    • None
    • PySide
    • None
    • All

    Description

      Greetings PySide Developers from PyQtGraph land.

       

      Reading your blog post for the PySide 6.1 release with experimental support for numpy specific methods for plotting, naturally caught our attention.  As you can imagine, pyqtgraph deals a lot with bridging the gap from numpy arrays to GraphicsView plots; and given that interactivity of pyqtgraph is the big selling point, anything we can do to speed up that migration of numpy data into QPainter methods is something we have a vested interest in.

       

      This issue/suggestion here specifically requests the addition of QPainter.drawPixmapNp method.   We use QPainter.drawPixmap presently for scatter plots.  Here is a link to how we handle this now.  As you can see, it is a bit ugly.  

       

      What would be great, is we can pass a numpy array in directly, that has the shape (4, n) (or (n, 4)) where each element of n would consist of (x, y, w, h) along with a QPixmap object to draw at the associated location.  The signature would be QPainter.drawPixmapNp(PyArrayObject*, QPixmap) .

       

      Would this be feasible, and if so, is there anything we can do to assist in this effort?  Thanks!

       

      Ogi

      Attachments

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

        Activity

          People

            crmaurei Cristian Maureira-Fredes
            j9ac9k Ognyan Moore
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes