<div dir="ltr">Hi Phil,<br><br>I am one of the maintainers of pyqtgraph, I'd like to request that you enable some of the function signatures for QPainter methods that accept pointers.  The following two would be more beneficial for us:<br><br>QPainter::drawLines(const QLineF *lines, int lineCount)<br>QPainter::drawPixmapFragments(const QPainter::PixmapFragment *fragments, int fragmentCount, const QPixmap &pixmap, QPainter::PixmapFragmentHints hints = PixmapFragmentHints())<br><br>If it would not be too much trouble, enabling some of the other QPainter methods that enabled referencing pointers could also be beneficial, but these won't have the same impact as the ones above<br><br>QPainter::drawConvexPolygon(const QPointF *points, int pointCount)<br>QPainter::drawPoints(const QPointF *points, int pointCount)<br>QPainter::drawPolygon(const QPointF *points, int pointCount, Qt::FillRule fillRule = Qt::OddEvenFill)<br>QPainter::drawRects(const QRectF *rectangles, int rectCount)<div>QPainter::drawPolyline(const QPointF *points, int pointCount)<br><br>To demonstrate our usage, I'll highlight what we do with the PySide bindings.  For the QPainter::drawPixmapFragments we're able to do something resembling the following<br><br>        import numpy as np<br>    size = 1_000<br>  arr = np.empty((size, 10), dtype=np.float64)<br>  ptrs = shiboken6.wrapInstance(arr.ctypes.data, QtGui.QPainter.PixmapFragment)</div><div>...<br>       QPainter.drawPixmapFragments(ptrs, size, pixmap)<br><br>For the equivalent functionality with PyQt bindings<br><br>     ptrs = list(map(sip.wrapInstance,<br>         itertools.count(arr.ctypes.data, arr.strides[0]),<br>           itertools.repeat(QtGui.QPainter.PixmapFragment, arr.shape[0])))<br> QPainter.drawPixmapFragments(ptrs[:size], pixmap)<br><br><br>We do this right now with QImage, and in a round-about way with QPolygonF construction.<br><br>Thanks,<br>Ogi<br></div></div>