summaryrefslogtreecommitdiffstats
path: root/examples/datavisualization/qmlsurfacelayers/qml/qmlsurfacelayers/main.qml
diff options
context:
space:
mode:
authorTomi Korpipää <tomi.korpipaa@digia.com>2014-02-18 12:56:10 +0200
committerMiikka Heikkinen <miikka.heikkinen@digia.com>2014-02-18 12:56:54 +0200
commit5bd455cbd04a61b251c466dd641e3ef31fcbe93b (patch)
tree36c13c892305e98c5c4225013f7c53fe8aa536f1 /examples/datavisualization/qmlsurfacelayers/qml/qmlsurfacelayers/main.qml
parentd91e065526fe084374b206b6e7c9f0d628abb93d (diff)
Crash fix
Also fixes messing up the quick controls when switching between rendering modes. Change-Id: I8c383ee948b0ba363d09a93b35f14028702296d3 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Diffstat (limited to 'examples/datavisualization/qmlsurfacelayers/qml/qmlsurfacelayers/main.qml')
-rw-r--r--examples/datavisualization/qmlsurfacelayers/qml/qmlsurfacelayers/main.qml23
1 files changed, 23 insertions, 0 deletions
diff --git a/examples/datavisualization/qmlsurfacelayers/qml/qmlsurfacelayers/main.qml b/examples/datavisualization/qmlsurfacelayers/qml/qmlsurfacelayers/main.qml
index 22c527a2..65378660 100644
--- a/examples/datavisualization/qmlsurfacelayers/qml/qmlsurfacelayers/main.qml
+++ b/examples/datavisualization/qmlsurfacelayers/qml/qmlsurfacelayers/main.qml
@@ -230,5 +230,28 @@ Item {
}
}
}
+
+ NewButton {
+ id: aaButton
+ text: "Disable Antialiasing"
+ Layout.fillWidth: true
+ Layout.minimumHeight: 40
+ visible: false
+ onClicked: {
+ if (surfaceLayers.renderingMode === AbstractGraph3D.Indirect_NoAA) {
+ surfaceLayers.renderingMode = AbstractGraph3D.DirectToBackground
+ text = "Disable Antialiasing"
+ } else {
+ surfaceLayers.renderingMode = AbstractGraph3D.Indirect_NoAA
+ text = "Enable Antialiasing"
+ }
+ }
+ }
+
+ Component.onCompleted: {
+ if (surfaceLayers.antialiasing) {
+ aaButton.visible = true
+ }
+ }
}
}