![]() |
ACloudViewer
3.9.4
A Modern Library for 3D Data Processing
|
A paint buffer based on QPixmap, using software raster rendering. More...
#include <qcustomplot.h>


Public Member Functions | |
| QCPPaintBufferPixmap (const QSize &size, double devicePixelRatio) | |
| virtual | ~QCPPaintBufferPixmap () |
| virtual QCPPainter * | startPainting () |
| virtual void | draw (QCPPainter *painter) const |
| void | clear (const QColor &color) |
Public Member Functions inherited from QCPAbstractPaintBuffer | |
| QCPAbstractPaintBuffer (const QSize &size, double devicePixelRatio) | |
| virtual | ~QCPAbstractPaintBuffer () |
| QSize | size () const |
| bool | invalidated () const |
| double | devicePixelRatio () const |
| void | setSize (const QSize &size) |
| void | setInvalidated (bool invalidated=true) |
| void | setDevicePixelRatio (double ratio) |
| virtual void | donePainting () |
Protected Member Functions | |
| virtual void | reallocateBuffer () |
Protected Attributes | |
| QPixmap | mBuffer |
Protected Attributes inherited from QCPAbstractPaintBuffer | |
| QSize | mSize |
| double | mDevicePixelRatio |
| bool | mInvalidated |
A paint buffer based on QPixmap, using software raster rendering.
This paint buffer is the default and fall-back paint buffer which uses software rendering and QPixmap as internal buffer. It is used if QCustomPlot::setOpenGl is false.
Definition at line 743 of file qcustomplot.h.
|
explicit |
Creates a pixmap paint buffer instancen with the specified size and devicePixelRatio, if applicable.
Definition at line 618 of file qcustomplot.cpp.
References reallocateBuffer().
|
virtual |
Definition at line 624 of file qcustomplot.cpp.
|
virtual |
Fills the entire buffer with the provided color. To have an empty transparent buffer, use the named color Qt::transparent.
This method must not be called if there is currently a painter (acquired with startPainting) active.
Implements QCPAbstractPaintBuffer.
Definition at line 642 of file qcustomplot.cpp.
|
virtual |
Draws the contents of this buffer with the provided painter. This is the method that is used to finally join all paint buffers and draw them onto the screen.
Implements QCPAbstractPaintBuffer.
Definition at line 634 of file qcustomplot.cpp.
References mBuffer.
|
protectedvirtual |
Reallocates the internal buffer with the currently configured size (setSize) and device pixel ratio, if applicable (setDevicePixelRatio). It is called as soon as any of those properties are changed on this paint buffer.
Implements QCPAbstractPaintBuffer.
Definition at line 645 of file qcustomplot.cpp.
References mBuffer, QCPAbstractPaintBuffer::mDevicePixelRatio, QCPAbstractPaintBuffer::mSize, and QCPAbstractPaintBuffer::setInvalidated().
Referenced by QCPPaintBufferPixmap().
|
virtual |
Returns a QCPPainter which is ready to draw to this buffer. The ownership and thus the responsibility to delete the painter after the painting operations are complete is given to the caller of this method.
Once you are done using the painter, delete the painter and call donePainting.
While a painter generated with this method is active, you must not call setSize, setDevicePixelRatio or clear.
This method may return 0, if a painter couldn't be activated on the buffer. This usually indicates a problem with the respective painting backend.
Implements QCPAbstractPaintBuffer.
Definition at line 627 of file qcustomplot.cpp.
|
protected |
Definition at line 755 of file qcustomplot.h.
Referenced by clear(), draw(), reallocateBuffer(), and startPainting().