From 741dc64436a5c244742b8a631b2a5f72107ecd2a Mon Sep 17 00:00:00 2001 From: Miikka Heikkinen <miikka.heikkinen@qt.io> Date: Mon, 25 May 2020 17:27:21 +0300 Subject: [PATCH] Add designer support for effects MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Added item library items for effects and enable the effects and light probe properties of SceneEnvironment to be edited. Pick-to: 5.15 Change-Id: Iba83a23fda36075c30d2472368634aa749aed92e Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io> Reviewed-by: Andy Nichols <andy.nichols@qt.io> --- .../designer/AdditiveColorGradientSection.qml | 60 +++ .../AdditiveColorGradientSpecifics.qml | 40 ++ .../effectlib/designer/BlurSection.qml | 57 +++ .../effectlib/designer/BlurSpecifics.qml | 40 ++ .../designer/BrushStrokesSection.qml | 103 +++++ .../designer/BrushStrokesSpecifics.qml | 40 ++ .../designer/ChromaticAberrationSection.qml | 90 ++++ .../designer/ChromaticAberrationSpecifics.qml | 40 ++ .../effectlib/designer/ColorMasterSection.qml | 96 +++++ .../designer/ColorMasterSpecifics.qml | 40 ++ .../designer/DepthOfFieldHQBlurSection.qml | 83 ++++ .../designer/DepthOfFieldHQBlurSpecifics.qml | 40 ++ .../effectlib/designer/DesaturateSection.qml | 57 +++ .../designer/DesaturateSpecifics.qml | 40 ++ .../designer/DistortionRippleSection.qml | 148 +++++++ .../designer/DistortionRippleSpecifics.qml | 40 ++ .../designer/DistortionSphereSection.qml | 122 ++++++ .../designer/DistortionSphereSpecifics.qml | 40 ++ .../designer/DistortionSpiralSection.qml | 122 ++++++ .../designer/DistortionSpiralSpecifics.qml | 40 ++ .../effectlib/designer/EdgeDetectSection.qml | 57 +++ .../designer/EdgeDetectSpecifics.qml | 40 ++ .../effectlib/designer/EmbossSection.qml | 57 +++ .../effectlib/designer/EmbossSpecifics.qml | 40 ++ .../effectlib/designer/FlipSection.qml | 66 +++ .../effectlib/designer/FlipSpecifics.qml | 40 ++ .../effectlib/designer/FxaaSection.qml | 38 ++ .../effectlib/designer/FxaaSpecifics.qml | 40 ++ .../designer/GaussianBlurSection.qml | 57 +++ .../designer/GaussianBlurSpecifics.qml | 40 ++ .../designer/HDRBloomTonemapSection.qml | 122 ++++++ .../designer/HDRBloomTonemapSpecifics.qml | 40 ++ src/imports/effectlib/designer/IdComboBox.qml | 117 +++++ .../effectlib/designer/MotionBlurSection.qml | 70 +++ .../designer/MotionBlurSpecifics.qml | 40 ++ .../designer/SCurveTonemapSection.qml | 179 ++++++++ .../designer/SCurveTonemapSpecifics.qml | 40 ++ .../effectlib/designer/ScatterSection.qml | 101 +++++ .../effectlib/designer/ScatterSpecifics.qml | 40 ++ .../effectlib/designer/TiltShiftSection.qml | 105 +++++ .../effectlib/designer/TiltShiftSpecifics.qml | 40 ++ .../effectlib/designer/VignetteSection.qml | 82 ++++ .../effectlib/designer/VignetteSpecifics.qml | 40 ++ src/imports/effectlib/designer/designer.pri | 52 +++ .../effectlib/designer/effectlib.metainfo | 401 ++++++++++++++++++ .../effectlib/designer/images/effect.png | Bin 0 -> 375 bytes .../effectlib/designer/images/effect16.png | Bin 0 -> 253 bytes .../effectlib/designer/images/effect@2x.png | Bin 0 -> 499 bytes src/imports/effectlib/plugin.pro | 2 + .../designer/SceneEnvironmentSection.qml | 28 +- 50 files changed, 3311 insertions(+), 1 deletion(-) create mode 100644 src/imports/effectlib/designer/AdditiveColorGradientSection.qml create mode 100644 src/imports/effectlib/designer/AdditiveColorGradientSpecifics.qml create mode 100644 src/imports/effectlib/designer/BlurSection.qml create mode 100644 src/imports/effectlib/designer/BlurSpecifics.qml create mode 100644 src/imports/effectlib/designer/BrushStrokesSection.qml create mode 100644 src/imports/effectlib/designer/BrushStrokesSpecifics.qml create mode 100644 src/imports/effectlib/designer/ChromaticAberrationSection.qml create mode 100644 src/imports/effectlib/designer/ChromaticAberrationSpecifics.qml create mode 100644 src/imports/effectlib/designer/ColorMasterSection.qml create mode 100644 src/imports/effectlib/designer/ColorMasterSpecifics.qml create mode 100644 src/imports/effectlib/designer/DepthOfFieldHQBlurSection.qml create mode 100644 src/imports/effectlib/designer/DepthOfFieldHQBlurSpecifics.qml create mode 100644 src/imports/effectlib/designer/DesaturateSection.qml create mode 100644 src/imports/effectlib/designer/DesaturateSpecifics.qml create mode 100644 src/imports/effectlib/designer/DistortionRippleSection.qml create mode 100644 src/imports/effectlib/designer/DistortionRippleSpecifics.qml create mode 100644 src/imports/effectlib/designer/DistortionSphereSection.qml create mode 100644 src/imports/effectlib/designer/DistortionSphereSpecifics.qml create mode 100644 src/imports/effectlib/designer/DistortionSpiralSection.qml create mode 100644 src/imports/effectlib/designer/DistortionSpiralSpecifics.qml create mode 100644 src/imports/effectlib/designer/EdgeDetectSection.qml create mode 100644 src/imports/effectlib/designer/EdgeDetectSpecifics.qml create mode 100644 src/imports/effectlib/designer/EmbossSection.qml create mode 100644 src/imports/effectlib/designer/EmbossSpecifics.qml create mode 100644 src/imports/effectlib/designer/FlipSection.qml create mode 100644 src/imports/effectlib/designer/FlipSpecifics.qml create mode 100644 src/imports/effectlib/designer/FxaaSection.qml create mode 100644 src/imports/effectlib/designer/FxaaSpecifics.qml create mode 100644 src/imports/effectlib/designer/GaussianBlurSection.qml create mode 100644 src/imports/effectlib/designer/GaussianBlurSpecifics.qml create mode 100644 src/imports/effectlib/designer/HDRBloomTonemapSection.qml create mode 100644 src/imports/effectlib/designer/HDRBloomTonemapSpecifics.qml create mode 100644 src/imports/effectlib/designer/IdComboBox.qml create mode 100644 src/imports/effectlib/designer/MotionBlurSection.qml create mode 100644 src/imports/effectlib/designer/MotionBlurSpecifics.qml create mode 100644 src/imports/effectlib/designer/SCurveTonemapSection.qml create mode 100644 src/imports/effectlib/designer/SCurveTonemapSpecifics.qml create mode 100644 src/imports/effectlib/designer/ScatterSection.qml create mode 100644 src/imports/effectlib/designer/ScatterSpecifics.qml create mode 100644 src/imports/effectlib/designer/TiltShiftSection.qml create mode 100644 src/imports/effectlib/designer/TiltShiftSpecifics.qml create mode 100644 src/imports/effectlib/designer/VignetteSection.qml create mode 100644 src/imports/effectlib/designer/VignetteSpecifics.qml create mode 100644 src/imports/effectlib/designer/designer.pri create mode 100644 src/imports/effectlib/designer/effectlib.metainfo create mode 100644 src/imports/effectlib/designer/images/effect.png create mode 100644 src/imports/effectlib/designer/images/effect16.png create mode 100644 src/imports/effectlib/designer/images/effect@2x.png diff --git a/src/imports/effectlib/designer/AdditiveColorGradientSection.qml b/src/imports/effectlib/designer/AdditiveColorGradientSection.qml new file mode 100644 index 000000000..e41508d71 --- /dev/null +++ b/src/imports/effectlib/designer/AdditiveColorGradientSection.qml @@ -0,0 +1,60 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Top Color") + width: parent.width + ColorEditor { + caption: qsTr("Top Color") + backendValue: backendValues.topColor + supportGradient: false + isVector3D: true + Layout.fillWidth: true + } + } + + Section { + caption: qsTr("Bottom Color") + width: parent.width + ColorEditor { + caption: qsTr("Bottom Color") + backendValue: backendValues.bottomColor + supportGradient: false + isVector3D: true + Layout.fillWidth: true + } + } +} diff --git a/src/imports/effectlib/designer/AdditiveColorGradientSpecifics.qml b/src/imports/effectlib/designer/AdditiveColorGradientSpecifics.qml new file mode 100644 index 000000000..d912265b5 --- /dev/null +++ b/src/imports/effectlib/designer/AdditiveColorGradientSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + AdditiveColorGradientSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/BlurSection.qml b/src/imports/effectlib/designer/BlurSection.qml new file mode 100644 index 000000000..9dd4b7dff --- /dev/null +++ b/src/imports/effectlib/designer/BlurSection.qml @@ -0,0 +1,57 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Blur") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Amount") + tooltip: qsTr("Strength of the blur.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 0.1 + minimumValue: 0 + decimals: 3 + backendValue: backendValues.amount + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/BlurSpecifics.qml b/src/imports/effectlib/designer/BlurSpecifics.qml new file mode 100644 index 000000000..064d0f80f --- /dev/null +++ b/src/imports/effectlib/designer/BlurSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + BlurSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/BrushStrokesSection.qml b/src/imports/effectlib/designer/BrushStrokesSection.qml new file mode 100644 index 000000000..93da273e5 --- /dev/null +++ b/src/imports/effectlib/designer/BrushStrokesSection.qml @@ -0,0 +1,103 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + // TODO: Proper support for TextureInput properties +// Section { +// caption: qsTr("Noise") +// width: parent.width + +// SectionLayout { +// Label { +// text: qsTr("Noise Sample Texture") +// tooltip: qsTr("Defines a texture for noise samples.") +// } +// SecondColumnLayout { +// IdComboBox { +// typeFilter: "QtQuick3D.Texture" +// Layout.fillWidth: true +// backendValue: backendValues.noiseSample.texture +// } +// } +// } +// } + + Section { + caption: qsTr("Brush") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Length") + tooltip: qsTr("Length of the brush.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 3 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.brushLength + Layout.fillWidth: true + } + } + Label { + text: qsTr("Size") + tooltip: qsTr("Size of the brush.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 200 + minimumValue: 10 + decimals: 0 + backendValue: backendValues.brushSize + Layout.fillWidth: true + } + } + Label { + text: qsTr("Angle") + tooltip: qsTr("Angle of the brush") + } + SecondColumnLayout { + SpinBox { + maximumValue: 360 + minimumValue: 0 + decimals: 0 + backendValue: backendValues.brushAngle + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/BrushStrokesSpecifics.qml b/src/imports/effectlib/designer/BrushStrokesSpecifics.qml new file mode 100644 index 000000000..584253c7c --- /dev/null +++ b/src/imports/effectlib/designer/BrushStrokesSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + BrushStrokesSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/ChromaticAberrationSection.qml b/src/imports/effectlib/designer/ChromaticAberrationSection.qml new file mode 100644 index 000000000..b8e468dc9 --- /dev/null +++ b/src/imports/effectlib/designer/ChromaticAberrationSection.qml @@ -0,0 +1,90 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + // TODO: Proper support for TextureInput properties +// Section { +// caption: qsTr("Mask") +// width: parent.width + +// SectionLayout { +// Label { +// text: qsTr("Mask Texture") +// tooltip: qsTr("Defines a texture for mask.") +// } +// SecondColumnLayout { +// IdComboBox { +// typeFilter: "QtQuick3D.Texture" +// Layout.fillWidth: true +// backendValue: backendValues.maskTexture.texture +// } +// } +// } +// } + + Section { + caption: qsTr("Aberration") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Amount") + tooltip: qsTr("Amount of aberration.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1000 + minimumValue: -1000 + decimals: 0 + backendValue: backendValues.aberrationAmount + Layout.fillWidth: true + } + } + Label { + text: qsTr("Focus Depth") + tooltip: qsTr("Focus depth of the aberration.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 10000 + minimumValue: 0 + decimals: 0 + backendValue: backendValues.focusDepth + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/ChromaticAberrationSpecifics.qml b/src/imports/effectlib/designer/ChromaticAberrationSpecifics.qml new file mode 100644 index 000000000..57f4ac6b1 --- /dev/null +++ b/src/imports/effectlib/designer/ChromaticAberrationSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + ChromaticAberrationSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/ColorMasterSection.qml b/src/imports/effectlib/designer/ColorMasterSection.qml new file mode 100644 index 000000000..c83f90026 --- /dev/null +++ b/src/imports/effectlib/designer/ColorMasterSection.qml @@ -0,0 +1,96 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Colors") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Red Strength") + tooltip: qsTr("Red strength.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 2 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.redStrength + Layout.fillWidth: true + } + } + Label { + text: qsTr("Green Strength") + tooltip: qsTr("Green strength.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 2 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.greenStrength + Layout.fillWidth: true + } + } + Label { + text: qsTr("Blue Strength") + tooltip: qsTr("Blue strength.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 2 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.blueStrength + Layout.fillWidth: true + } + } + Label { + text: qsTr("Saturation") + tooltip: qsTr("Color saturation.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: -1 + decimals: 2 + backendValue: backendValues.saturation + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/ColorMasterSpecifics.qml b/src/imports/effectlib/designer/ColorMasterSpecifics.qml new file mode 100644 index 000000000..4d622f9d0 --- /dev/null +++ b/src/imports/effectlib/designer/ColorMasterSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + ColorMasterSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/DepthOfFieldHQBlurSection.qml b/src/imports/effectlib/designer/DepthOfFieldHQBlurSection.qml new file mode 100644 index 000000000..304483ae3 --- /dev/null +++ b/src/imports/effectlib/designer/DepthOfFieldHQBlurSection.qml @@ -0,0 +1,83 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Blur") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Blur Amount") + tooltip: qsTr("Amount of blur.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 50 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.blurAmount + Layout.fillWidth: true + } + } + Label { + text: qsTr("Focus Distance") + tooltip: qsTr("Focus distance of the blur.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 5000 + minimumValue: 0 + decimals: 0 + backendValue: backendValues.focusDistance + Layout.fillWidth: true + } + } + Label { + text: qsTr("Focus Range") + tooltip: qsTr("Focus range of the blur.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 5000 + minimumValue: 0 + decimals: 0 + backendValue: backendValues.focusRange + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/DepthOfFieldHQBlurSpecifics.qml b/src/imports/effectlib/designer/DepthOfFieldHQBlurSpecifics.qml new file mode 100644 index 000000000..94b1674fa --- /dev/null +++ b/src/imports/effectlib/designer/DepthOfFieldHQBlurSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + DepthOfFieldHQBlurSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/DesaturateSection.qml b/src/imports/effectlib/designer/DesaturateSection.qml new file mode 100644 index 000000000..1c03b792e --- /dev/null +++ b/src/imports/effectlib/designer/DesaturateSection.qml @@ -0,0 +1,57 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Desaturate") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Amount") + tooltip: qsTr("Strength of the desaturate.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: -1 + decimals: 2 + backendValue: backendValues.amount + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/DesaturateSpecifics.qml b/src/imports/effectlib/designer/DesaturateSpecifics.qml new file mode 100644 index 000000000..f2536139f --- /dev/null +++ b/src/imports/effectlib/designer/DesaturateSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + DesaturateSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/DistortionRippleSection.qml b/src/imports/effectlib/designer/DistortionRippleSection.qml new file mode 100644 index 000000000..a67c3e8f9 --- /dev/null +++ b/src/imports/effectlib/designer/DistortionRippleSection.qml @@ -0,0 +1,148 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Distortion") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Radius") + tooltip: qsTr("Radius of the effect.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 100 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.radius + Layout.fillWidth: true + } + } + Label { + text: qsTr("Width") + tooltip: qsTr("Width of the distortion.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 100 + minimumValue: 2 + decimals: 2 + backendValue: backendValues.distortionWidth + Layout.fillWidth: true + } + } + Label { + text: qsTr("Height") + tooltip: qsTr("Height of the distortion.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 100 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.distortionHeight + Layout.fillWidth: true + } + } + Label { + text: qsTr("Phase") + tooltip: qsTr("Phase of the distortion.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 360 + minimumValue: 0 + decimals: 0 + backendValue: backendValues.distortionPhase + Layout.fillWidth: true + } + } + } + } + + Section { + id: centerSection + width: parent.width + caption: qsTr("Position") + + property int labelWidth: 10 + property int labelSpinBoxSpacing: 0 + property int spinBoxMinimumWidth: 120 + + ColumnLayout { + width: parent.width - 16 + + Label { + width: 100 + text: qsTr("Center") + tooltip: qsTr("Center of the distortion.") + } + RowLayout { + spacing: centerSection.labelSpinBoxSpacing + + Label { + text: qsTr("X") + width: centerSection.labelWidth + } + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.center_x + Layout.fillWidth: true + Layout.minimumWidth: centerSection.spinBoxMinimumWidth + } + } + RowLayout { + spacing: centerSection.labelSpinBoxSpacing + + Label { + text: qsTr("Y") + width: centerSection.labelWidth + } + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.center_y + Layout.fillWidth: true + Layout.minimumWidth: centerSection.spinBoxMinimumWidth + } + } + } + } +} diff --git a/src/imports/effectlib/designer/DistortionRippleSpecifics.qml b/src/imports/effectlib/designer/DistortionRippleSpecifics.qml new file mode 100644 index 000000000..f653eb8b8 --- /dev/null +++ b/src/imports/effectlib/designer/DistortionRippleSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + DistortionRippleSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/DistortionSphereSection.qml b/src/imports/effectlib/designer/DistortionSphereSection.qml new file mode 100644 index 000000000..b77246af5 --- /dev/null +++ b/src/imports/effectlib/designer/DistortionSphereSection.qml @@ -0,0 +1,122 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Distortion") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Radius") + tooltip: qsTr("Radius of the effect.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.radius + Layout.fillWidth: true + } + } + Label { + text: qsTr("Height") + tooltip: qsTr("Height of the distortion.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: -1 + decimals: 2 + backendValue: backendValues.distortionHeight + Layout.fillWidth: true + } + } + } + } + + Section { + id: centerSection + width: parent.width + caption: qsTr("Position") + + property int labelWidth: 10 + property int labelSpinBoxSpacing: 0 + property int spinBoxMinimumWidth: 120 + + ColumnLayout { + width: parent.width - 16 + + Label { + width: 100 + text: qsTr("Center") + tooltip: qsTr("Center of the distortion.") + } + RowLayout { + spacing: centerSection.labelSpinBoxSpacing + + Label { + text: qsTr("X") + width: centerSection.labelWidth + } + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.center_x + Layout.fillWidth: true + Layout.minimumWidth: centerSection.spinBoxMinimumWidth + } + } + RowLayout { + spacing: centerSection.labelSpinBoxSpacing + + Label { + text: qsTr("Y") + width: centerSection.labelWidth + } + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.center_y + Layout.fillWidth: true + Layout.minimumWidth: centerSection.spinBoxMinimumWidth + } + } + } + } +} diff --git a/src/imports/effectlib/designer/DistortionSphereSpecifics.qml b/src/imports/effectlib/designer/DistortionSphereSpecifics.qml new file mode 100644 index 000000000..1fc3e4c22 --- /dev/null +++ b/src/imports/effectlib/designer/DistortionSphereSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + DistortionSphereSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/DistortionSpiralSection.qml b/src/imports/effectlib/designer/DistortionSpiralSection.qml new file mode 100644 index 000000000..b6d523448 --- /dev/null +++ b/src/imports/effectlib/designer/DistortionSpiralSection.qml @@ -0,0 +1,122 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Distortion") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Radius") + tooltip: qsTr("Radius of the effect.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.radius + Layout.fillWidth: true + } + } + Label { + text: qsTr("Strength") + tooltip: qsTr("Strength of the distortion.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 10 + minimumValue: -10 + decimals: 2 + backendValue: backendValues.distortionStrength + Layout.fillWidth: true + } + } + } + } + + Section { + id: centerSection + width: parent.width + caption: qsTr("Position") + + property int labelWidth: 10 + property int labelSpinBoxSpacing: 0 + property int spinBoxMinimumWidth: 120 + + ColumnLayout { + width: parent.width - 16 + + Label { + width: 100 + text: qsTr("Center") + tooltip: qsTr("Center of the distortion.") + } + RowLayout { + spacing: centerSection.labelSpinBoxSpacing + + Label { + text: qsTr("X") + width: centerSection.labelWidth + } + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.center_x + Layout.fillWidth: true + Layout.minimumWidth: centerSection.spinBoxMinimumWidth + } + } + RowLayout { + spacing: centerSection.labelSpinBoxSpacing + + Label { + text: qsTr("Y") + width: centerSection.labelWidth + } + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.center_y + Layout.fillWidth: true + Layout.minimumWidth: centerSection.spinBoxMinimumWidth + } + } + } + } +} diff --git a/src/imports/effectlib/designer/DistortionSpiralSpecifics.qml b/src/imports/effectlib/designer/DistortionSpiralSpecifics.qml new file mode 100644 index 000000000..5efe14958 --- /dev/null +++ b/src/imports/effectlib/designer/DistortionSpiralSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + DistortionSpiralSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/EdgeDetectSection.qml b/src/imports/effectlib/designer/EdgeDetectSection.qml new file mode 100644 index 000000000..f2b6dc91d --- /dev/null +++ b/src/imports/effectlib/designer/EdgeDetectSection.qml @@ -0,0 +1,57 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Edge") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Strength") + tooltip: qsTr("Strength of the edge.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.edgeStrength + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/EdgeDetectSpecifics.qml b/src/imports/effectlib/designer/EdgeDetectSpecifics.qml new file mode 100644 index 000000000..a5e76852b --- /dev/null +++ b/src/imports/effectlib/designer/EdgeDetectSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + EdgeDetectSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/EmbossSection.qml b/src/imports/effectlib/designer/EmbossSection.qml new file mode 100644 index 000000000..e500a536a --- /dev/null +++ b/src/imports/effectlib/designer/EmbossSection.qml @@ -0,0 +1,57 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Emboss") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Amount") + tooltip: qsTr("Strength of the emboss.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 0.01 + minimumValue: 0 + decimals: 4 + backendValue: backendValues.amount + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/EmbossSpecifics.qml b/src/imports/effectlib/designer/EmbossSpecifics.qml new file mode 100644 index 000000000..781d78b9f --- /dev/null +++ b/src/imports/effectlib/designer/EmbossSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + EmbossSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/FlipSection.qml b/src/imports/effectlib/designer/FlipSection.qml new file mode 100644 index 000000000..a2f494d2e --- /dev/null +++ b/src/imports/effectlib/designer/FlipSection.qml @@ -0,0 +1,66 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Flip") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Horizontal") + tooltip: qsTr("Flip horizontally.") + } + SecondColumnLayout { + CheckBox { + text: backendValues.flipHorizontally.valueToString + backendValue: backendValues.flipHorizontally + Layout.fillWidth: true + } + } + Label { + text: qsTr("Vertical") + tooltip: qsTr("Flip vertically.") + } + SecondColumnLayout { + CheckBox { + text: backendValues.flipVertically.valueToString + backendValue: backendValues.flipVertically + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/FlipSpecifics.qml b/src/imports/effectlib/designer/FlipSpecifics.qml new file mode 100644 index 000000000..05b203e7d --- /dev/null +++ b/src/imports/effectlib/designer/FlipSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + FlipSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/FxaaSection.qml b/src/imports/effectlib/designer/FxaaSection.qml new file mode 100644 index 000000000..b3468d3b8 --- /dev/null +++ b/src/imports/effectlib/designer/FxaaSection.qml @@ -0,0 +1,38 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + // Fxaa effect has no modifiable properties +} diff --git a/src/imports/effectlib/designer/FxaaSpecifics.qml b/src/imports/effectlib/designer/FxaaSpecifics.qml new file mode 100644 index 000000000..621e69be9 --- /dev/null +++ b/src/imports/effectlib/designer/FxaaSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + FxaaSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/GaussianBlurSection.qml b/src/imports/effectlib/designer/GaussianBlurSection.qml new file mode 100644 index 000000000..b4536cd5d --- /dev/null +++ b/src/imports/effectlib/designer/GaussianBlurSection.qml @@ -0,0 +1,57 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Blur") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Amount") + tooltip: qsTr("Strength of the blur.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 10 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.amount + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/GaussianBlurSpecifics.qml b/src/imports/effectlib/designer/GaussianBlurSpecifics.qml new file mode 100644 index 000000000..114bac691 --- /dev/null +++ b/src/imports/effectlib/designer/GaussianBlurSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + GaussianBlurSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/HDRBloomTonemapSection.qml b/src/imports/effectlib/designer/HDRBloomTonemapSection.qml new file mode 100644 index 000000000..e6489b43e --- /dev/null +++ b/src/imports/effectlib/designer/HDRBloomTonemapSection.qml @@ -0,0 +1,122 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Tonemap") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Gamma") + tooltip: qsTr("Amount of gamma.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 4 + minimumValue: 0.1 + decimals: 2 + backendValue: backendValues.gamma + Layout.fillWidth: true + } + } + Label { + text: qsTr("Exposure") + tooltip: qsTr("Amount of exposure.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 9 + minimumValue: -9 + decimals: 2 + backendValue: backendValues.exposure + Layout.fillWidth: true + } + } + Label { + text: qsTr("Blur Falloff") + tooltip: qsTr("Amount of blur falloff.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 10 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.blurFalloff + Layout.fillWidth: true + } + } + Label { + text: qsTr("Tonemapping Lerp") + tooltip: qsTr("Tonemapping linear interpolation value.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.tonemappingLerp + Layout.fillWidth: true + } + } + Label { + text: qsTr("Bloom Threshold") + tooltip: qsTr("Bloom color threshold value.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 3 + backendValue: backendValues.bloomThreshold + Layout.fillWidth: true + } + } + Label { + text: qsTr("Channel Threshold") + tooltip: qsTr("Channel color threshold value.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 3 + backendValue: backendValues.channelThreshold + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/HDRBloomTonemapSpecifics.qml b/src/imports/effectlib/designer/HDRBloomTonemapSpecifics.qml new file mode 100644 index 000000000..a4411299a --- /dev/null +++ b/src/imports/effectlib/designer/HDRBloomTonemapSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + HDRBloomTonemapSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/IdComboBox.qml b/src/imports/effectlib/designer/IdComboBox.qml new file mode 100644 index 000000000..16fda808c --- /dev/null +++ b/src/imports/effectlib/designer/IdComboBox.qml @@ -0,0 +1,117 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 as HelperWidgets + +HelperWidgets.ComboBox { + id: comboBox + + property alias typeFilter: itemFilterModel.typeFilter + + manualMapping: true + editable: true + model: comboBox.addDefaultItem(itemFilterModel.itemModel) + + textInput.validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ } + + HelperWidgets.ItemFilterModel { + id: itemFilterModel + modelNodeBackendProperty: modelNodeBackend + } + + property string defaultItem: qsTr("[None]") + property string textValue: comboBox.backendValue.expression + property bool block: false + property bool dirty: true + property var editRegExp: /^[a-z_]\w*|^\[None\]$/ + + onTextValueChanged: { + if (comboBox.block) + return + + comboBox.setCurrentText(comboBox.textValue) + } + onModelChanged: comboBox.setCurrentText(comboBox.textValue) + onCompressedActivated: comboBox.handleActivate(index) + Component.onCompleted: comboBox.setCurrentText(comboBox.textValue) + + onEditTextChanged: { + comboBox.dirty = true + colorLogic.errorState = !(editRegExp.exec(comboBox.editText) !== null) + } + onFocusChanged: { + if (comboBox.dirty) + comboBox.handleActivate(comboBox.currentIndex) + } + + function handleActivate(index) + { + if (!comboBox.__isCompleted || comboBox.backendValue === undefined) + return + + var cText = (index === -1) ? comboBox.editText : comboBox.textAt(index) + comboBox.block = true + comboBox.setCurrentText(cText) + comboBox.block = false + } + + function setCurrentText(text) + { + if (!comboBox.__isCompleted || comboBox.backendValue === undefined) + return + + comboBox.currentIndex = comboBox.find(text) + + if (text === "") { + comboBox.currentIndex = 0 + comboBox.editText = comboBox.defaultItem + } else { + if (comboBox.currentIndex === -1) + comboBox.editText = text + else if (comboBox.currentIndex === 0) + comboBox.editText = comboBox.defaultItem + } + + if (comboBox.currentIndex === 0) { + comboBox.backendValue.resetValue() + } else { + if (comboBox.backendValue.expression !== comboBox.editText) + comboBox.backendValue.expression = comboBox.editText + } + comboBox.dirty = false + } + + function addDefaultItem(arr) + { + var copy = arr.slice() + copy.unshift(comboBox.defaultItem) + return copy + } +} diff --git a/src/imports/effectlib/designer/MotionBlurSection.qml b/src/imports/effectlib/designer/MotionBlurSection.qml new file mode 100644 index 000000000..f00bb702c --- /dev/null +++ b/src/imports/effectlib/designer/MotionBlurSection.qml @@ -0,0 +1,70 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Blur") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Fade Amount") + tooltip: qsTr("Specifies how much the blur fades away each frame.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.fadeAmount + Layout.fillWidth: true + } + } + Label { + text: qsTr("Quality") + tooltip: qsTr("Blur quality.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0.1 + decimals: 2 + backendValue: backendValues.blurQuality + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/MotionBlurSpecifics.qml b/src/imports/effectlib/designer/MotionBlurSpecifics.qml new file mode 100644 index 000000000..2746f1b88 --- /dev/null +++ b/src/imports/effectlib/designer/MotionBlurSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + MotionBlurSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/SCurveTonemapSection.qml b/src/imports/effectlib/designer/SCurveTonemapSection.qml new file mode 100644 index 000000000..158b48816 --- /dev/null +++ b/src/imports/effectlib/designer/SCurveTonemapSection.qml @@ -0,0 +1,179 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Curve") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Shoulder Slope") + tooltip: qsTr("Set the slope of the curve shoulder.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 3 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.shoulderSlope + Layout.fillWidth: true + } + } + Label { + text: qsTr("Shoulder Emphasis") + tooltip: qsTr("Set the emphasis of the curve shoulder.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: -1 + decimals: 2 + backendValue: backendValues.shoulderEmphasis + Layout.fillWidth: true + } + } + Label { + text: qsTr("Toe Slope") + tooltip: qsTr("Set the slope of the curve toe.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 3 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.toeSlope + Layout.fillWidth: true + } + } + Label { + text: qsTr("Toe Emphasis") + tooltip: qsTr("Set the emphasis of the curve toe.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: -1 + decimals: 2 + backendValue: backendValues.toeEmphasis + Layout.fillWidth: true + } + } + } + } + Section { + caption: qsTr("Color") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Contrast Boost") + tooltip: qsTr("Set the contrast boost amount.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 2 + minimumValue: -1 + decimals: 2 + backendValue: backendValues.contrastBoost + Layout.fillWidth: true + } + } + Label { + text: qsTr("Saturation Level") + tooltip: qsTr("Set the color saturation level.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 2 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.saturationLevel + Layout.fillWidth: true + } + } + Label { + text: qsTr("Gamma") + tooltip: qsTr("Set the gamma value.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 8 + minimumValue: 0.1 + decimals: 2 + backendValue: backendValues.gammaValue + Layout.fillWidth: true + } + } + Label { + text: qsTr("Use Exposure") + tooltip: qsTr("Specifies if the exposure or white point should be used.") + } + SecondColumnLayout { + CheckBox { + text: backendValues.useExposure.valueToString + backendValue: backendValues.useExposure + Layout.fillWidth: true + } + } + Label { + text: qsTr("White Point") + tooltip: qsTr("Set the white point value.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 128 + minimumValue: 0.01 + decimals: 2 + backendValue: backendValues.whitePoint + Layout.fillWidth: true + } + } + Label { + text: qsTr("Exposure") + tooltip: qsTr("Set the exposure value.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 16 + minimumValue: 0.01 + decimals: 2 + backendValue: backendValues.exposureValue + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/SCurveTonemapSpecifics.qml b/src/imports/effectlib/designer/SCurveTonemapSpecifics.qml new file mode 100644 index 000000000..ab56628df --- /dev/null +++ b/src/imports/effectlib/designer/SCurveTonemapSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + SCurveTonemapSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/ScatterSection.qml b/src/imports/effectlib/designer/ScatterSection.qml new file mode 100644 index 000000000..28e9b0556 --- /dev/null +++ b/src/imports/effectlib/designer/ScatterSection.qml @@ -0,0 +1,101 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + // TODO: Proper support for TextureInput properties +// Section { +// caption: qsTr("Noise") +// width: parent.width + +// SectionLayout { +// Label { +// text: qsTr("Noise Sample Texture") +// tooltip: qsTr("Defines a texture for noise samples.") +// } +// SecondColumnLayout { +// IdComboBox { +// typeFilter: "QtQuick3D.Texture" +// Layout.fillWidth: true +// backendValue: backendValues.noiseSample_texture +// } +// } +// } +// } + + Section { + caption: qsTr("Scatter") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Amount") + tooltip: qsTr("Amount of scatter.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 127 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.amount + Layout.fillWidth: true + } + } + Label { + text: qsTr("Direction") + tooltip: qsTr("Direction of scatter. 0 = both, 1 = horizontal, 2 = vertical.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 2 + minimumValue: 0 + decimals: 0 + backendValue: backendValues.direction + Layout.fillWidth: true + } + } + Label { + text: qsTr("Randomize") + tooltip: qsTr("Specifies if the scatter is random.") + } + SecondColumnLayout { + CheckBox { + text: backendValues.randomize.valueToString + backendValue: backendValues.randomize + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/ScatterSpecifics.qml b/src/imports/effectlib/designer/ScatterSpecifics.qml new file mode 100644 index 000000000..df84649f3 --- /dev/null +++ b/src/imports/effectlib/designer/ScatterSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + ScatterSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/TiltShiftSection.qml b/src/imports/effectlib/designer/TiltShiftSection.qml new file mode 100644 index 000000000..d3f08427e --- /dev/null +++ b/src/imports/effectlib/designer/TiltShiftSection.qml @@ -0,0 +1,105 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Tilt Shift") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Focus Position") + tooltip: qsTr("Set the focus position.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.focusPosition + Layout.fillWidth: true + } + } + Label { + text: qsTr("Focus Width") + tooltip: qsTr("Set the focus width.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 1 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.focusWidth + Layout.fillWidth: true + } + } + Label { + text: qsTr("Blur Amount") + tooltip: qsTr("Set the blur amount.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 10 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.blurAmount + Layout.fillWidth: true + } + } + Label { + text: qsTr("Vertical") + tooltip: qsTr("Specifies if the tilt shift is vertical.") + } + SecondColumnLayout { + CheckBox { + text: backendValues.isVertical.valueToString + backendValue: backendValues.isVertical + Layout.fillWidth: true + } + } + Label { + text: qsTr("Inverted") + tooltip: qsTr("Specifies if the tilt shift is inverted.") + } + SecondColumnLayout { + CheckBox { + text: backendValues.isInverted.valueToString + backendValue: backendValues.isInverted + Layout.fillWidth: true + } + } + } + } +} diff --git a/src/imports/effectlib/designer/TiltShiftSpecifics.qml b/src/imports/effectlib/designer/TiltShiftSpecifics.qml new file mode 100644 index 000000000..014fe65d8 --- /dev/null +++ b/src/imports/effectlib/designer/TiltShiftSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + TiltShiftSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/VignetteSection.qml b/src/imports/effectlib/designer/VignetteSection.qml new file mode 100644 index 000000000..9910b8d89 --- /dev/null +++ b/src/imports/effectlib/designer/VignetteSection.qml @@ -0,0 +1,82 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + Section { + caption: qsTr("Vignette") + width: parent.width + + SectionLayout { + Label { + text: qsTr("Strength") + tooltip: qsTr("Set the vignette strength.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 15 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.vignetteStrength + Layout.fillWidth: true + } + } + Label { + text: qsTr("Radius") + tooltip: qsTr("Set the vignette radius.") + } + SecondColumnLayout { + SpinBox { + maximumValue: 5 + minimumValue: 0 + decimals: 2 + backendValue: backendValues.vignetteRadius + Layout.fillWidth: true + } + } + } + } + + Section { + caption: qsTr("Color") + width: parent.width + ColorEditor { + caption: qsTr("Vignette Color") + backendValue: backendValues.vignetteColor + supportGradient: false + isVector3D: true + Layout.fillWidth: true + } + } +} diff --git a/src/imports/effectlib/designer/VignetteSpecifics.qml b/src/imports/effectlib/designer/VignetteSpecifics.qml new file mode 100644 index 000000000..022cee3f8 --- /dev/null +++ b/src/imports/effectlib/designer/VignetteSpecifics.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2020 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick 3D. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import HelperWidgets 2.0 +import QtQuick.Layouts 1.12 + +Column { + width: parent.width + + VignetteSection { + width: parent.width + } +} diff --git a/src/imports/effectlib/designer/designer.pri b/src/imports/effectlib/designer/designer.pri new file mode 100644 index 000000000..fbb22802f --- /dev/null +++ b/src/imports/effectlib/designer/designer.pri @@ -0,0 +1,52 @@ +AUX_QML_FILES += \ + $$PWD/effectlib.metainfo + +AUX_QML_FILES += \ + $$PWD/IdComboBox.qml \ + $$PWD/AdditiveColorGradientSection.qml \ + $$PWD/AdditiveColorGradientSpecifics.qml \ + $$PWD/BlurSection.qml \ + $$PWD/BlurSpecifics.qml \ + $$PWD/BrushStrokesSection.qml \ + $$PWD/BrushStrokesSpecifics.qml \ + $$PWD/ChromaticAberrationSection.qml \ + $$PWD/ChromaticAberrationSpecifics.qml \ + $$PWD/ColorMasterSection.qml \ + $$PWD/ColorMasterSpecifics.qml \ + $$PWD/DepthOfFieldHQBlurSection.qml \ + $$PWD/DepthOfFieldHQBlurSpecifics.qml \ + $$PWD/DesaturateSection.qml \ + $$PWD/DesaturateSpecifics.qml \ + $$PWD/DistortionRippleSection.qml \ + $$PWD/DistortionRippleSpecifics.qml \ + $$PWD/DistortionSphereSection.qml \ + $$PWD/DistortionSphereSpecifics.qml \ + $$PWD/DistortionSpiralSection.qml \ + $$PWD/DistortionSpiralSpecifics.qml \ + $$PWD/EdgeDetectSection.qml \ + $$PWD/EdgeDetectSpecifics.qml \ + $$PWD/EmbossSection.qml \ + $$PWD/EmbossSpecifics.qml \ + $$PWD/FlipSection.qml \ + $$PWD/FlipSpecifics.qml \ + $$PWD/FxaaSection.qml \ + $$PWD/FxaaSpecifics.qml \ + $$PWD/GaussianBlurSection.qml \ + $$PWD/GaussianBlurSpecifics.qml \ + $$PWD/HDRBloomTonemapSection.qml \ + $$PWD/HDRBloomTonemapSpecifics.qml \ + $$PWD/MotionBlurSection.qml \ + $$PWD/MotionBlurSpecifics.qml \ + $$PWD/ScatterSection.qml \ + $$PWD/ScatterSpecifics.qml \ + $$PWD/SCurveTonemapSection.qml \ + $$PWD/SCurveTonemapSpecifics.qml \ + $$PWD/TiltShiftSection.qml \ + $$PWD/TiltShiftSpecifics.qml \ + $$PWD/VignetteSection.qml \ + $$PWD/VignetteSpecifics.qml + +AUX_QML_FILES += \ + $$PWD/images/effect.png \ + $$PWD/images/effect@2x.png \ + $$PWD/images/effect16.png diff --git a/src/imports/effectlib/designer/effectlib.metainfo b/src/imports/effectlib/designer/effectlib.metainfo new file mode 100644 index 000000000..b64948714 --- /dev/null +++ b/src/imports/effectlib/designer/effectlib.metainfo @@ -0,0 +1,401 @@ +MetaInfo { + Type { + name: "QtQuick3D.Effects.AdditiveColorGradient" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Additive Color Gradient" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.Blur" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Blur" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.BrushStrokes" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Brush Strokes" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.ChromaticAberration" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Chromatic Aberration" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.ColorMaster" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Color Master" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.DepthOfFieldHQBlur" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Depth of Field HQ Blur" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.Desaturate" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Desaturate" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.DistortionRipple" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Distortion Ripple" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.DistortionSphere" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Distortion Sphere" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.DistortionSpiral" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Distortion Spiral" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.EdgeDetect" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Edge Detect" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.Emboss" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Emboss" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.Flip" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Flip" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.Fxaa" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Fxaa" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.GaussianBlur" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Gaussian Blur" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.HDRBloomTonemap" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "HDR Bloom Tonemap" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.MotionBlur" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Motion Blur" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.Scatter" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Scatter" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.SCurveTonemap" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "SCurve Tonemap" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.TiltShift" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Tilt Shift" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } + Type { + name: "QtQuick3D.Effects.Vignette" + icon: "images/effect16.png" + + Hints { + visibleInNavigator: true + canBeDroppedInNavigator: true + canBeDroppedInFormEditor: false + canBeDroppedInView3D: false + } + + ItemLibraryEntry { + name: "Vignette" + category: "Qt Quick 3D Effects" + libraryIcon: "images/effect.png" + version: "1.15" + requiredImport: "QtQuick3D.Effects" + } + } +} diff --git a/src/imports/effectlib/designer/images/effect.png b/src/imports/effectlib/designer/images/effect.png new file mode 100644 index 0000000000000000000000000000000000000000..a3b6c7f6f243d86dd4ada0db8f709a0a5adeaa9c GIT binary patch literal 375 zcmV--0f_#IP)<h;3K|Lk000e1NJLTq000;O000;W1^@s6;CDUv0003#Nkl<ZNQv#! zJ!@1^6oug@Dg+}~i18yt5KW~Jv6E4dRQU&CrSKPsklG@Rod{xYBM5Fnz(xc`FbD~0 z>_w~+f?yL6L=+K=xxz5a9TQNnn73Se?YquBtiy;A{|!~OFi1btV!n!5oW&2k#(I*k zLo)7RrC&VIVm^gkJjW((;Qo-0w=%XDQ&mmi9cGezZ?uCrk4b#Qn<Ufyy92Li08<#( zy)IRC9M7<YZJfa2L5r;cRdoT!a0WNAl;meKp2y21%RT<BeFdO{i#UnXecle94%z*4 zK$3?&r#p)6s(O*+6RzOSUIN-$)F1X4Yq-=S&-}H3sv5^-Y&6mbT<e*SX=!BJLwka6 z*wJmr93Ch6(pc_dwW;a^&f&;@{@@lK=svPn=p?!Qdzj=cuH!u(C0W#M)`$`RfL}vw VQ8G$FYIpzu002ovPDHLkV1nj8r2GH? literal 0 HcmV?d00001 diff --git a/src/imports/effectlib/designer/images/effect16.png b/src/imports/effectlib/designer/images/effect16.png new file mode 100644 index 0000000000000000000000000000000000000000..de8906a724d67a95b221c5d11f2d20cd5bd42a0c GIT binary patch literal 253 zcmV<Z00RGsP)<h;3K|Lk000e1NJLTq000mG000mO1^@s6AM^iV0002QNkl<ZIF0Sk zy(-3W7{>9>BL+oT#Do-+W1wWTiSA=yGa8iQBpkt&Qj}ReHj_ni3U;LoSbl^4&&vsL zP50~fx^Mn9pd`H{(_{MeJD=<{x3G;~l4TrK)q97ri3|l)RUiEZJHQTZlFVQqbC?== zL0eqGJa%!?%9l9D8!pBIuz{r(&n8*Kb5*@GgRilGs=8}~57@&sK8F|$0+KAW;g9yh zBVKWwWCCm5orw-`9fvr@6Yi_(8&^2PDsD$z^H=o);-@*CW3=in00000NkvXXu0mjf D3aM%B literal 0 HcmV?d00001 diff --git a/src/imports/effectlib/designer/images/effect@2x.png b/src/imports/effectlib/designer/images/effect@2x.png new file mode 100644 index 0000000000000000000000000000000000000000..7ca04a01eaa5a247ee96d385f0ad7b188af6cd71 GIT binary patch literal 499 zcmV<P0Sx|$P)<h;3K|Lk000e1NJLTq001BW001Be1^@s6b9#F80005HNkl<ZScUD? zKWG$D5P<Ptj0%bnJw$Q=#S|i12^I<>NU8`5+UT<p(LzWmHYwFkFr@*BU?WT`SZE^> zY%T0<l=zQ?s3bu+6JxP2ava&?mY_EKHT&MqFz@3rvrA1)P0e2>A`V5wj<WdX9*gv& zi5BKkO1~;NOyeS6R1(OCKEp8fVHw-77!i{gPbsZb5LuT^Wr1A$4o;(yQrezH#&9D) z{|^!IG$NjKiTAawXCq>yEVri~SciG+>Ns=@Zs8mbM8pC<bmnbXAR-18O?9&)^bp5z z9d8u<(p1uXJqtv{5$w;~qqv4i+;7Vn!X=ERlwRi7U-2;_S{o9;2+rp9K{POfeymNw z@m%Y55A~`Eq?9Hw!JpAQi76b$)toknw<)D>RRv1Nuta7hU-1KswsreXMZ;C5l0X}; z6b-gJ?>}SDzZ5u+Ma<>>dkjZJqiUgUpW*?WP+aYdV)pmq46fi&N@+ExPiKj{5iy3J zipjZvfo=lbZlH<Vc#c{8z&qT-V~npQrj%N^j8j;^7sZ$^;X789&{q~{CnC0Hp=Eq3 p`y1vd8Nz%@X{ndmH8nLgzX1p^gzT>@;oJZK002ovPDHLkV1nMB*LnZ| literal 0 HcmV?d00001 diff --git a/src/imports/effectlib/plugin.pro b/src/imports/effectlib/plugin.pro index a981fb1e7..24a7bcd21 100644 --- a/src/imports/effectlib/plugin.pro +++ b/src/imports/effectlib/plugin.pro @@ -43,4 +43,6 @@ DISTFILES += \ RESOURCES += \ qteffectlibrary.qrc +!static: qtConfig(quick-designer): include(designer/designer.pri) + load(qml_plugin) diff --git a/src/imports/quick3d/designer/SceneEnvironmentSection.qml b/src/imports/quick3d/designer/SceneEnvironmentSection.qml index c6539695c..3c672309c 100644 --- a/src/imports/quick3d/designer/SceneEnvironmentSection.qml +++ b/src/imports/quick3d/designer/SceneEnvironmentSection.qml @@ -121,6 +121,22 @@ Column { Layout.fillWidth: true } } + Label { + text: qsTr("Effect") + tooltip: qsTr("A post-processing effect applied to this scene.") + } + SecondColumnLayout { + EditableListView { + backendValue: backendValues.effects + model: backendValues.effects.expressionAsList + Layout.fillWidth: true + typeFilter: "QtQuick3D.Effect" + + onAdd: function(value) { backendValues.effects.idListAdd(value) } + onRemove: function(idx) { backendValues.effects.idListRemove(idx) } + onReplace: function (idx, value) { backendValues.effects.idListReplace(idx, value) } + } + } } } @@ -230,7 +246,17 @@ Column { caption: qsTr("Image Based Lighting") width: parent.width SectionLayout { - // ### lightProbe + Label { + text: qsTr("Light Probe") + tooltip: qsTr("Defines a texture for overriding or setting an image based lighting texture for use with the skybox of this scene.") + } + SecondColumnLayout { + IdComboBox { + typeFilter: "QtQuick3D.Texture" + Layout.fillWidth: true + backendValue: backendValues.lightProbe + } + } Label { text: qsTr("Probe Brightness") tooltip: qsTr("Sets the amount of light emitted by the light probe.") -- GitLab