summaryrefslogtreecommitdiffstats
path: root/examples/multimedia/video/qmlvideofx/qml/qmlvideofx/EffectBlackAndWhite.qml
diff options
context:
space:
mode:
Diffstat (limited to 'examples/multimedia/video/qmlvideofx/qml/qmlvideofx/EffectBlackAndWhite.qml')
-rw-r--r--examples/multimedia/video/qmlvideofx/qml/qmlvideofx/EffectBlackAndWhite.qml7
1 files changed, 6 insertions, 1 deletions
diff --git a/examples/multimedia/video/qmlvideofx/qml/qmlvideofx/EffectBlackAndWhite.qml b/examples/multimedia/video/qmlvideofx/qml/qmlvideofx/EffectBlackAndWhite.qml
index 8cfe5a78a..f1e53e005 100644
--- a/examples/multimedia/video/qmlvideofx/qml/qmlvideofx/EffectBlackAndWhite.qml
+++ b/examples/multimedia/video/qmlvideofx/qml/qmlvideofx/EffectBlackAndWhite.qml
@@ -39,10 +39,15 @@ Effect {
name: "Threshold"
value: 0.5
}
+ onDataChanged: updateThreshold()
}
+ function updateThreshold()
+ {
+ threshold = parameters.get(0).value;
+ }
// Transform slider values, and bind result to shader uniforms
- property real threshold: parameters.get(0).value
+ property real threshold: 0.5
fragmentShaderFilename: "blackandwhite.fsh"
}