4#ifndef QOPENGL_PAINTDEVICE_P_H
5#define QOPENGL_PAINTDEVICE_P_H
18#include <qopenglpaintdevice.h>
19#include <private/qglobal_p.h>
29 QOpenGLPaintDevicePrivate(
const QSize &size);
30 virtual ~QOpenGLPaintDevicePrivate();
32 static QOpenGLPaintDevicePrivate *get(QOpenGLPaintDevice *dev) {
return dev->d_func(); }
34 virtual void beginPaint() { }
35 virtual void endPaint() { }
43 qreal devicePixelRatio;
void updateBrushUniforms()
void updateCompositionMode()
void updateTexture(GLenum textureUnit, const T &texture, GLenum wrapMode, GLenum filterMode, TextureUpdateMode updateMode=UpdateIfNeeded)
void systemStateChanged() override
void transferMode(EngineMode newMode)
~QOpenGL2PaintEngineExPrivate()
void composite(const QOpenGLRect &boundingRect)
bool prepareForCachedGlyphDraw(const QFontEngineGlyphCache &cache)
void stroke(const QVectorPath &path, const QPen &pen)
void updateBrushTexture()
GLuint bindTexture(const ImageWithBindOptions &imageWithOptions, bool *newTextureCreated)
void activateTextureUnit(GLenum textureUnit)
bool compositionModeDirty
void setVertexAttribArrayEnabled(int arrayIndex, bool enabled=true)
void fill(const QVectorPath &path)
void drawPixmapFragments(const QPainter::PixmapFragment *fragments, int fragmentCount, const QPixmap &pixmap, QPainter::PixmapFragmentHints hints)
bool prepareForDraw(bool srcPixelsAreOpaque)
void drawCachedGlyphs(QFontEngine::GlyphFormat glyphFormat, QStaticTextItem *staticTextItem)
void fillStencilWithVertexArray(const float *data, int count, int *stops, int stopCount, const QOpenGLRect &bounds, StencilFillMode mode)
void setBrush(const QBrush &brush)
void drawVertexArrays(const float *data, int *stops, int stopCount, GLenum primitive)
GLuint bindTexture(const GLuint &textureId, bool *newTextureCreated)
void setScissor(const QRect &rect)
bool vertexAttributeArraysEnabledState[QT_GL_VERTEX_ARRAY_TRACKED_COUNT]
void updateClipScissorTest()
QOpenGL2PaintEngineState()
QOpenGL2PaintEngineState(const QOpenGL2PaintEngineState &other)
~QOpenGL2PaintEngineState()
friend class QPaintEngine
#define GL_BLEND_ADVANCED_COHERENT_KHR
#define GL_DIFFERENCE_KHR
#define GL_COLORDODGE_KHR
static void setCoords(GLfloat *coords, const QOpenGLRect &rect)
static bool isPowerOfTwo(int x)
static const QRectF scaleRect(const QRectF &r, qreal sx, qreal sy)
QColor qt_premultiplyColor(QColor c, GLfloat opacity)
#define QT_GL_VERTEX_ARRAY_TRACKED_COUNT
#define QT_UNKNOWN_TEXTURE_UNIT
#define QT_MASK_TEXTURE_UNIT
#define QT_IMAGE_TEXTURE_UNIT
#define QT_DEFAULT_TEXTURE_UNIT
#define QT_BRUSH_TEXTURE_UNIT
#define GL_STENCIL_HIGH_BIT
Q_GUI_EXPORT bool qt_scaleForTransform(const QTransform &transform, qreal *scale)
QOpenGLTextureUploader::BindOptions options