tests/manual/graphicaleffects5/ThresholdMaskEffect.qml
raw| 1 | // Copyright (C) 2020 The Qt Company Ltd. |
| 2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only |
| 3 | |
| 4 | import QtQuick |
| 5 | import Qt5Compat.GraphicalEffects |
| 6 | |
| 7 | Item { |
| 8 | Image { |
| 9 | id: mask |
| 10 | source: "images/fog.png" |
| 11 | sourceSize: Qt.size(parent.width, parent.height) |
| 12 | smooth: true |
| 13 | visible: false |
| 14 | } |
| 15 | |
| 16 | ThresholdMask { |
| 17 | anchors.fill: parent |
| 18 | source: bug |
| 19 | maskSource: mask |
| 20 | threshold: 0.4 |
| 21 | spread: 0.2 |
| 22 | } |
| 23 | } |