24class Q_QUICK_EXPORT QSGDefaultContext :
public QSGContext,
public QSGRendererInterface
27 QSGDefaultContext(QObject *parent =
nullptr);
30 void renderContextInitialized(QSGRenderContext *renderContext) override;
31 void renderContextInvalidated(QSGRenderContext *) override;
32 QSGRenderContext *createRenderContext() override;
33 QSGInternalRectangleNode *createInternalRectangleNode() override;
34 QSGInternalImageNode *createInternalImageNode(QSGRenderContext *renderContext) override;
35 QSGPainterNode *createPainterNode(QQuickPaintedItem *item) override;
36 QSGGlyphNode *createGlyphNode(QSGRenderContext *rc, QSGTextNode::RenderType renderType,
int renderTypeQuality) override;
37 QSGInternalTextNode *createInternalTextNode(QSGRenderContext *renderContext) override;
38 QSGLayer *createLayer(QSGRenderContext *renderContext) override;
39 QSurfaceFormat defaultSurfaceFormat()
const override;
40 QSGRendererInterface *rendererInterface(QSGRenderContext *renderContext) override;
41 QSGRectangleNode *createRectangleNode() override;
42 QSGImageNode *createImageNode() override;
43 QSGNinePatchNode *createNinePatchNode() override;
44#if QT_CONFIG(quick_sprite)
45 QSGSpriteNode *createSpriteNode() override;
47 QSGGuiThreadShaderEffectManager *createGuiThreadShaderEffectManager() override;
48 QSGShaderEffectNode *createShaderEffectNode(QSGRenderContext *renderContext) override;
50 void setDistanceFieldEnabled(
bool enabled);
51 bool isDistanceFieldEnabled()
const;
53 GraphicsApi graphicsApi()
const override;
54 void *getResource(QQuickWindow *window, Resource resource)
const override;
55 ShaderType shaderType()
const override;
56 ShaderCompilationTypes shaderCompilationType()
const override;
57 ShaderSourceTypes shaderSourceType()
const override;
61 QSGContext::AntialiasingMethod m_antialiasingMethod;
62 bool m_distanceFieldDisabled;
63 QSGDistanceFieldGlyphNode::AntialiasingMode m_distanceFieldAntialiasing;
64 bool m_distanceFieldAntialiasingDecided;