aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickshadereffect_p.h
diff options
context:
space:
mode:
authorGunnar Sletta <gunnar.sletta@nokia.com>2011-12-20 00:50:15 +0100
committerQt by Nokia <qt-info@nokia.com>2012-01-03 17:58:59 +0100
commit42d6acd0a3ea5fa5cf7ab69f1f8f2206559107ea (patch)
tree84377465ecf6dbc45634656631c72f24e0e77f51 /src/quick/items/qquickshadereffect_p.h
parenta9b103d02831a03e8f3815af2b7d043c5cf4eae6 (diff)
Introduce layerering support (ShaderEffectSource) directly in Item
This is enabled by doing "Item.layer.enabled: true". The implementation is solely based on the existing shader effect (source) and simply swaps in a sibling next to the item when enabled. This change also adds the QSGTextureProvider to the public API, as it is now a natural part of the QQuickItem API since all items can be textures. Change-Id: I26705c11e92d5623a5121300acc123782b784077 Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
Diffstat (limited to 'src/quick/items/qquickshadereffect_p.h')
-rw-r--r--src/quick/items/qquickshadereffect_p.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/quick/items/qquickshadereffect_p.h b/src/quick/items/qquickshadereffect_p.h
index ca67a6a242..7536b42a73 100644
--- a/src/quick/items/qquickshadereffect_p.h
+++ b/src/quick/items/qquickshadereffect_p.h
@@ -83,8 +83,6 @@ public:
QQuickShaderEffect(QQuickItem *parent = 0);
~QQuickShaderEffect();
- virtual void componentComplete();
-
QByteArray fragmentShader() const { return m_source.fragmentCode; }
void setFragmentShader(const QByteArray &code);
@@ -100,6 +98,8 @@ public:
CullMode cullMode() const { return m_cullMode; }
void setCullMode(CullMode face);
+ void ensureCompleted();
+
Q_SIGNALS:
void fragmentShaderChanged();
void vertexShaderChanged();
@@ -148,6 +148,8 @@ private:
uint m_programDirty : 1;
uint m_dirtyMesh : 1;
uint m_dirtyGeometry : 1;
+
+ uint m_complete : 1;
};
QT_END_NAMESPACE