aboutsummaryrefslogtreecommitdiffstats
path: root/tests/baseline/data/effects/distortion2.qml
blob: cc96332f57e2121b2648f10be962488fdb88d2cd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
// Copyright (C) 2020 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only

import QtQuick
import QtQuick3D
import QtQuick3D.Effects

GridView {
    width: 400
    height: 400
    cellWidth: 200
    cellHeight: 200

    model: 4

    Texture {
        id: myNoise
        source: "../shared/maps/checkers2.png"
        tilingModeHorizontal: Texture.Repeat
        tilingModeVertical: Texture.Repeat
    }

    DistortionSpiral { id: e0 }
    DistortionSpiral { id: e1; center: Qt.vector2d(0.4, 0.8); distortionStrength: -10 }
    Scatter { id: e2; randomize: false }
    Scatter { id: e3; randomize: false; amount: 40; direction: 2; noiseSample: TextureInput { texture: myNoise } }

    delegate: PlainView {
        effect: index == 0 ? e0 : index == 1 ? e1 : index == 2 ? e2 : e3
    }
}