aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/scenegraph/qsgcontext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/quick/scenegraph/qsgcontext.cpp')
-rw-r--r--src/quick/scenegraph/qsgcontext.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/quick/scenegraph/qsgcontext.cpp b/src/quick/scenegraph/qsgcontext.cpp
index 202ae91ac3..dd00f75fae 100644
--- a/src/quick/scenegraph/qsgcontext.cpp
+++ b/src/quick/scenegraph/qsgcontext.cpp
@@ -174,6 +174,11 @@ QSGContext::~QSGContext()
{
}
+QSGRenderContext *QSGContext::createRenderContext()
+{
+ return new QSGRenderContext(this);
+}
+
/*!
* This function is used by the Qt WebEngine to set up context sharing
* across multiple windows. Do not use it for any other purpose.
@@ -423,6 +428,20 @@ void QSGRenderContext::registerFontengineForCleanup(QFontEngine *engine)
}
/*!
+ compile/initialize are protected member functions of QSGMaterialShader.
+ We expose them here for custom renderers.
+ */
+void QSGRenderContext::compileShader(QSGMaterialShader *shader)
+{
+ shader->compile();
+}
+
+void QSGRenderContext::initializeShader(QSGMaterialShader *shader)
+{
+ shader->initialize();
+}
+
+/*!
Initializes the scene graph render context with the GL context \a context. This also
emits the ready() signal so that the QML graph can start building scene graph nodes.
*/