summaryrefslogtreecommitdiffstats
path: root/src/compositor/hardware_integration/qwlclientbufferintegration_p.h
diff options
context:
space:
mode:
authorJørgen Lind <jorgen.lind@theqtcompany.com>2015-07-29 14:58:54 +0200
committerJørgen Lind <jorgen.lind@theqtcompany.com>2015-08-28 13:09:41 +0200
commita327ca8d8a1f6e0a44a3aa6bd4dac716911c434e (patch)
treeae4c432c495a7baee8f97737160836cbb2e38476 /src/compositor/hardware_integration/qwlclientbufferintegration_p.h
parent6c9c54587c6cd1059d5de652d06e248456832ab6 (diff)
Move the texture ownership from the QWaylandSurface
to the respective QWaylandSurfaceView. For all GL applications this will have no significant impact, but will cause a memory regression for shm surfaces with multiple views. This is done to simplify the creation and destruction of textures, especially in multi-threaded environments. Also the same patch removes the y_inverted property and replaces it with a origin property. Its done in the same patch as a lot of the code was overlapping. Change-Id: I4bce50c614c9ac3ba0580e0560339476eac03433
Diffstat (limited to 'src/compositor/hardware_integration/qwlclientbufferintegration_p.h')
-rw-r--r--src/compositor/hardware_integration/qwlclientbufferintegration_p.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/compositor/hardware_integration/qwlclientbufferintegration_p.h b/src/compositor/hardware_integration/qwlclientbufferintegration_p.h
index f03d5ad2c..9d684553a 100644
--- a/src/compositor/hardware_integration/qwlclientbufferintegration_p.h
+++ b/src/compositor/hardware_integration/qwlclientbufferintegration_p.h
@@ -38,6 +38,7 @@
#define QWAYLANDCLIENTBUFFERINTEGRATION_H
#include <QtCompositor/qwaylandexport.h>
+#include <QtCompositor/qwaylandsurface.h>
#include <QtCore/QSize>
#include <QtGui/qopengl.h>
#include <QtGui/QOpenGLContext>
@@ -68,7 +69,7 @@ public:
// Called with the texture bound.
virtual void bindTextureToBuffer(struct ::wl_resource *buffer) = 0;
- virtual bool isYInverted(struct ::wl_resource *) const { return true; }
+ virtual QWaylandSurface::Origin origin(struct ::wl_resource *) const { return QWaylandSurface::OriginBottomLeft; }
virtual void *lockNativeBuffer(struct ::wl_resource *) const { return 0; }
virtual void unlockNativeBuffer(void *) const { return; }