diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2020-06-19 17:52:14 +0200 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2020-06-19 20:22:58 +0200 |
commit | 368bd1dd8f19e0e6db9889f616e1cf88224ca3fe (patch) | |
tree | 5b6ede1c662830062f10e396bc334cc650a44471 /src/quick/items/qquickwindow.h | |
parent | 7c6f53b128d57cfb746509b10b1abdcd5b65205e (diff) |
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 <andy.nichols@qt.io>
Diffstat (limited to 'src/quick/items/qquickwindow.h')
-rw-r--r-- | src/quick/items/qquickwindow.h | 3 |
1 files changed, 3 insertions, 0 deletions
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; |