From 368bd1dd8f19e0e6db9889f616e1cf88224ca3fe Mon Sep 17 00:00:00 2001 From: Laszlo Agocs Date: Fri, 19 Jun 2020 17:52:14 +0200 Subject: Add getters for rendertarget/device/config All the classes are implicitly shared, as is the Qt standard, so just return them as is by value. This is useful when applications split up their logic and so certain settings are set from different places. (we see this a lot in practice with QSurfaceFormat for instance) In this case it is helpful if they can query what they previously stored via the setter. Change-Id: Id133df8a48d22b896754e6e47a4047ba374597ef Reviewed-by: Andy Nichols --- src/quick/items/qquickwindow.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/quick/items/qquickwindow.h') diff --git a/src/quick/items/qquickwindow.h b/src/quick/items/qquickwindow.h index 88b3772048..fd4fb28cbe 100644 --- a/src/quick/items/qquickwindow.h +++ b/src/quick/items/qquickwindow.h @@ -137,6 +137,7 @@ public: QImage grabWindow(); void setRenderTarget(const QQuickRenderTarget &target); + QQuickRenderTarget renderTarget() const; struct GraphicsStateInfo { int currentFrameSlot; @@ -186,8 +187,10 @@ public: static QString sceneGraphBackend(); void setGraphicsDevice(const QQuickGraphicsDevice &device); + QQuickGraphicsDevice graphicsDevice() const; void setGraphicsConfiguration(const QQuickGraphicsConfiguration &config); + QQuickGraphicsConfiguration graphicsConfiguration() const; QSGRectangleNode *createRectangleNode() const; QSGImageNode *createImageNode() const; -- cgit v1.2.3