This commit is contained in:
Sven Riwoldt
2024-10-19 12:31:37 +02:00
commit f7f8c52455
10176 changed files with 1619386 additions and 0 deletions

View File

@@ -0,0 +1,104 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real roughness: 0.3
property vector3d base_color: Qt.vector3d(0.7, 0.7, 0.7)
property real intensity: 1.0
property vector3d emission_color: Qt.vector3d(0, 0, 0)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy
}
property TextureInput emissive_texture: TextureInput {
id: emissiveTexture
enabled: true
texture: Texture {
id: emissiveImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/emissive.png"
}
}
property TextureInput emissive_mask_texture: TextureInput {
id: emissiveMaskTexture
enabled: true
texture: Texture {
id: emissiveMaskImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/emissive_mask.png"
}
}
property TextureInput uEnvironmentTexture: TextureInput {
id: uEnvironmentTexture
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/shadow.png"
}
}
Shader {
id: aluminumAnodizedEmissiveShader
stage: Shader.Fragment
shader: "shaders/aluminumAnodizedEmissive.frag"
}
passes: [
Pass {
shaders: aluminumAnodizedEmissiveShader
}
]
}

View File

@@ -0,0 +1,77 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real roughness: 0.3
property vector3d base_color: Qt.vector3d(0.7, 0.7, 0.7)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
id: uEnvironmentTexture
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/shadow.png"
}
}
Shader {
id: aluminumAnodizedShader
stage: Shader.Fragment
shader: "shaders/aluminumAnodized.frag"
}
passes: [
Pass {
shaders: aluminumAnodizedShader
}
]
}

View File

@@ -0,0 +1,126 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property vector3d tiling: Qt.vector3d(3, 3, 3)
property real brushing_strength: 0.5
property real reflection_stretch: 0.5
property vector3d metal_color: Qt.vector3d(0.95, 0.95, 0.95)
property real bump_amount: 0.4
// <Property formalName="Roughness Map U" name="roughness_texture_u" description="Horizontal roughness texture" type="Texture" filter="linear" minfilter="linearMipmapLinear" clamp="repeat" usage="roughness" default="./maps/materials/brushed_full_contrast.png" category="Material"/>
// <Property formalName="Roughness Map V" name="roughness_texture_v" description="Vertical roughness texture" type="Texture" filter="linear" minfilter="linearMipmapLinear" clamp="repeat" usage="roughness" default="./maps/materials/brushed_full_contrast.png" category="Material"/>
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
id: uEnvironmentTexture
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/shadow.png"
}
}
property TextureInput brush_texture: TextureInput {
enabled: true
texture: Texture {
id: brushTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/brushed_full_contrast.png"
}
}
property TextureInput roughness_texture_u: TextureInput {
enabled: true
texture: Texture {
id: roughnessUTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/brushed_full_contrast.png"
}
}
property TextureInput roughness_texture_v: TextureInput {
enabled: true
texture: Texture {
id: roughnessVTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/brushed_full_contrast.png"
}
}
property TextureInput bump_texture: TextureInput {
enabled: true
texture: Texture {
id: bumpTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/brushed_a.png"
}
}
Shader {
id: aluminumBrushedFragShader
stage: Shader.Fragment
shader: "shaders/aluminumBrushed.frag"
}
passes: [
Pass {
shaders: aluminumBrushedFragShader
}
]
}

View File

@@ -0,0 +1,137 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real reflection_map_offset: 0.5
property real reflection_map_scale: 0.3
property vector3d tiling: Qt.vector3d(1, 1, 1)
property real roughness_map_offset: 0.16
property real roughness_map_scale: 0.4
property vector3d metal_color: Qt.vector3d(0.95, 0.95, 0.95)
property real intensity: 1.0
property vector3d emission_color: Qt.vector3d(0, 0, 0)
property vector3d emissive_mask_offset: Qt.vector3d(0, 0, 0)
property real bump_amount: 0.5
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
id: uEnvironmentTexture
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/shadow.png"
}
}
property TextureInput reflection_texture: TextureInput {
enabled: true
texture: Texture {
id: reflectionTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/grunge_b.png"
}
}
property TextureInput roughness_texture: TextureInput {
enabled: true
texture: Texture {
id: roughnessTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/grunge_d.png"
}
}
property TextureInput emissive_texture: TextureInput {
id: emissiveTexture
enabled: true
texture: Texture {
id: emissiveImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/emissive.png"
}
}
property TextureInput emissive_mask_texture: TextureInput {
id: emissiveMaskTexture
enabled: true
texture: Texture {
id: emissiveMaskImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/emissive_mask.png"
}
}
property TextureInput bump_texture: TextureInput {
enabled: true
texture: Texture {
id: bumpTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/grunge_d.png"
}
}
Shader {
id: aluminumEmissiveShader
stage: Shader.Fragment
shader: "shaders/aluminumEmissive.frag"
}
passes: [
Pass {
shaders: aluminumEmissiveShader
}
]
}

View File

@@ -0,0 +1,109 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
property real reflection_map_offset: 0.5
property real reflection_map_scale: 0.3
property real roughness_map_offset: 0.16
property real roughness_map_scale: 0.4
property real bump_amount: 0.5
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property vector3d tiling: Qt.vector3d(1, 1, 1)
property vector3d metal_color: Qt.vector3d(0.95, 0.95, 0.95)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
id: uEnvironmentTexture
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/shadow.png"
}
}
property TextureInput reflection_texture: TextureInput {
enabled: true
texture: Texture {
id: reflectionTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/grunge_b.png"
}
}
property TextureInput roughness_texture: TextureInput {
enabled: true
texture: Texture {
id: roughnessTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/grunge_d.png"
}
}
property TextureInput bump_texture: TextureInput {
enabled: true
texture: Texture {
id: bumpTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/grunge_d.png"
}
}
Shader {
id: aluminumFragShader
stage: Shader.Fragment
shader: "shaders/aluminum.frag"
}
passes: [
Pass {
shaders: aluminumFragShader
}
]
}

View File

@@ -0,0 +1,72 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
// These properties names need to match the ones in the shader code!
property bool uEnvironmentMappingEnabled: false
property bool uShadowMappingEnabled: false
property real roughness: 0.0
property vector3d metal_color: Qt.vector3d(0.805, 0.395, 0.305)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
Shader {
id: copperFragShader
stage: Shader.Fragment
shader: "shaders/copper.frag"
}
passes: [ Pass {
shaders: copperFragShader
}
]
}

View File

@@ -0,0 +1,236 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
// These properties names need to match the ones in the shader code!
property real roughness: 0.0
property real blur_size: 8.0
property real refract_depth: 5
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real glass_bfactor: 0.0
property bool glass_binside: false
property real uFresnelPower: 1.0
property real reflectivity_amount: 1.0
property real glass_ior: 1.5
property real intLightFall: 2.0
property real intLightRot: 0.0
property real intLightBrt: 0.0
property real bumpScale: 0.5
property int bumpBands: 1
property vector3d bumpCoords: Qt.vector3d(1.0, 1.0, 1.0)
property vector2d intLightPos: Qt.vector2d(0.5, 0.0)
property vector3d glass_color: Qt.vector3d(0.9, 0.9, 0.9)
property vector3d intLightCol: Qt.vector3d(0.9, 0.9, 0.9)
hasTransparency: true
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Refraction | ShaderInfo.Glossy
}
property TextureInput glass_bump: TextureInput {
enabled: true
texture: Texture {
id: glassBumpMap
source: "maps/spherical_checker.png"
}
}
property TextureInput uEnvironmentTexture: TextureInput {
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
property TextureInput randomGradient1D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient1D.png"
}
}
property TextureInput randomGradient2D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient2D.png"
}
}
property TextureInput randomGradient3D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient3D.png"
}
}
property TextureInput randomGradient4D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient4D.png"
}
}
Shader {
id: mainShader
stage: Shader.Fragment
shader: "shaders/frostedThinGlass.frag"
}
Shader {
id: noopShader
stage: Shader.Fragment
shader: "shaders/frostedThinGlassNoop.frag"
}
Shader {
id: preBlurShader
stage: Shader.Fragment
shader: "shaders/frostedThinGlassPreBlur.frag"
}
Shader {
id: blurXShader
stage: Shader.Fragment
shader: "shaders/frostedThinGlassBlurX.frag"
}
Shader {
id: blurYShader
stage: Shader.Fragment
shader: "shaders/frostedThinGlassBlurY.frag"
}
Buffer {
id: frameBuffer
name: "frameBuffer"
format: Buffer.Unknown
textureFilterOperation: Buffer.Linear
textureCoordOperation: Buffer.ClampToEdge
sizeMultiplier: 1.0
bufferFlags: Buffer.None // aka frame
}
Buffer {
id: dummyBuffer
name: "dummyBuffer"
format: Buffer.RGBA8
textureFilterOperation: Buffer.Linear
textureCoordOperation: Buffer.ClampToEdge
sizeMultiplier: 1.0
bufferFlags: Buffer.None // aka frame
}
Buffer {
id: tempBuffer
name: "tempBuffer"
format: Buffer.RGBA16F
textureFilterOperation: Buffer.Linear
textureCoordOperation: Buffer.ClampToEdge
sizeMultiplier: 0.5
bufferFlags: Buffer.None // aka frame
}
Buffer {
id: blurYBuffer
name: "tempBlurY"
format: Buffer.RGBA16F
textureFilterOperation: Buffer.Linear
textureCoordOperation: Buffer.ClampToEdge
sizeMultiplier: 0.5
bufferFlags: Buffer.None // aka frame
}
Buffer {
id: blurXBuffer
name: "tempBlurX"
format: Buffer.RGBA16F
textureFilterOperation: Buffer.Linear
textureCoordOperation: Buffer.ClampToEdge
sizeMultiplier: 0.5
bufferFlags: Buffer.None // aka frame
}
passes: [ Pass {
shaders: noopShader
output: dummyBuffer
commands: [ BufferBlit {
destination: frameBuffer
}
]
}, Pass {
shaders: preBlurShader
output: tempBuffer
commands: [ BufferInput {
buffer: frameBuffer
param: "OriginBuffer"
}
]
}, Pass {
shaders: blurXShader
output: blurXBuffer
commands: [ BufferInput {
buffer: tempBuffer
param: "BlurBuffer"
}
]
}, Pass {
shaders: blurYShader
output: blurYBuffer
commands: [ BufferInput {
buffer: blurXBuffer
param: "BlurBuffer"
}, BufferInput {
buffer: tempBuffer
param: "OriginBuffer"
}
]
}, Pass {
shaders: mainShader
commands: [BufferInput {
buffer: blurYBuffer
param: "refractiveTexture"
}, Blending {
srcBlending: Blending.SrcAlpha
destBlending: Blending.OneMinusSrcAlpha
}
]
}
]
}

View File

@@ -0,0 +1,129 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
property real roughness: 0.0
property real blur_size: 8.0
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real uFresnelPower: 1.0
property real reflectivity_amount: 1.0
property real glass_ior: 1.5
property real bumpScale: 0.5
property real noiseScale: 2.0
property int bumpBands: 1
property vector3d noiseCoords: Qt.vector3d(1.0, 1.0, 1.0)
property vector3d bumpCoords: Qt.vector3d(1.0, 1.0, 1.0)
property vector3d glass_color: Qt.vector3d(0.9, 0.9, 0.9)
hasTransparency: true
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Refraction | ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
property TextureInput randomGradient1D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient1D.png"
}
}
property TextureInput randomGradient2D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient2D.png"
}
}
property TextureInput randomGradient3D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient3D.png"
}
}
property TextureInput randomGradient4D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient4D.png"
}
}
Shader {
id: frostedGlassSpFragShader
stage: Shader.Fragment
shader: "shaders/frostedThinGlassSp.frag"
}
Buffer {
id: tempBuffer
name: "temp_buffer"
format: Buffer.Unknown
textureFilterOperation: Buffer.Linear
textureCoordOperation: Buffer.ClampToEdge
sizeMultiplier: 1.0
bufferFlags: Buffer.None // aka frame
}
passes: [ Pass {
shaders: frostedGlassSpFragShader
commands: [ BufferBlit {
destination: tempBuffer
}, BufferInput {
buffer: tempBuffer
param: "refractiveTexture"
}, Blending {
srcBlending: Blending.SrcAlpha
destBlending: Blending.OneMinusSrcAlpha
}
]
}
]
}

View File

@@ -0,0 +1,81 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
// These properties names need to match the ones in the shader code!
property bool uEnvironmentMappingEnabled: false
property bool uShadowMappingEnabled: false
property real uFresnelPower: 1.0
property real uMinOpacity: 0.5
property real reflectivity_amount: 0.5
property real glass_ior: 1.5
property vector3d glass_color: Qt.vector3d(0.6, 0.6, 0.6)
hasTransparency: true
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Transparent | ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
Shader {
id: simpleGlassFragShader
stage: Shader.Fragment
shader: "shaders/simpleGlass.frag"
}
passes: [ Pass {
shaders: simpleGlassFragShader
commands: [ Blending {
srcBlending: Blending.SrcAlpha
destBlending: Blending.OneMinusSrcAlpha
}
]
}
]
}

View File

@@ -0,0 +1,96 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
// These properties names need to match the ones in the shader code!
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real uFresnelPower: 1.0
property real reflectivity_amount: 1.0
property real glass_ior: 1.5
property real roughness: 0.0
property vector3d glass_color: Qt.vector3d(0.9, 0.9, 0.9)
hasTransparency: true
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Refraction | ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
Shader {
id: simpleGlassRefractiveFragShader
stage: Shader.Fragment
shader: "shaders/simpleGlassRefractive.frag"
}
Buffer {
id: tempBuffer
name: "temp_buffer"
format: Buffer.Unknown
textureFilterOperation: Buffer.Linear
textureCoordOperation: Buffer.ClampToEdge
sizeMultiplier: 1.0
bufferFlags: Buffer.None // aka frame
}
passes: [ Pass {
shaders: simpleGlassRefractiveFragShader
commands: [ BufferBlit {
destination: tempBuffer
}, BufferInput {
buffer: tempBuffer
param: "refractiveTexture"
}, Blending {
srcBlending: Blending.SrcAlpha
destBlending: Blending.OneMinusSrcAlpha
}
]
}
]
}

View File

@@ -0,0 +1,101 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
// These properties names need to match the ones in the shader code!
property bool uEnvironmentMappingEnabled: false
property bool uShadowMappingEnabled: false
property real bump_amount: 0.5
property real uTranslucentFalloff: 0.0
property real uDiffuseLightWrap: 0.0
property real uOpacity: 100.0
property real transmission_weight: 0.2
property real reflection_weight: 0.8
property vector2d texture_tiling: Qt.vector2d(5.0, 5.0)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Transmissive | ShaderInfo.Diffuse
}
property TextureInput uEnvironmentTexture: TextureInput {
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
property TextureInput diffuse_texture: TextureInput {
enabled: true
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/paper_diffuse.png"
}
}
property TextureInput bump_texture: TextureInput {
enabled: true
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/art_paper_normal.png"
}
}
property TextureInput transmission_texture: TextureInput {
enabled: true
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/art_paper_trans.png"
}
}
Shader {
id: paperArtisticFragShader
stage: Shader.Fragment
shader: "shaders/paperArtistic.frag"
}
passes: [ Pass {
shaders: paperArtisticFragShader
}
]
}

View File

@@ -0,0 +1,94 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
// These properties names need to match the ones in the shader code!
property bool uShadowMappingEnabled: false
property real bump_amount: 0.5
property real uTranslucentFalloff: 0.0
property real uDiffuseLightWrap: 0.0
property real uOpacity: 100.0
property real transmission_weight: 0.2
property real reflection_weight: 0.8
property vector2d texture_tiling: Qt.vector2d(1.0, 1.0)
property vector3d paper_color: Qt.vector3d(0.531, 0.531, 0.531)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Transmissive | ShaderInfo.Diffuse
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
property TextureInput diffuse_texture: TextureInput {
enabled: true
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/paper_diffuse.png"
}
}
property TextureInput bump_texture: TextureInput {
enabled: true
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/paper_diffuse.png"
}
}
property TextureInput transmission_texture: TextureInput {
enabled: true
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/paper_trans.png"
}
}
Shader {
id: paperOfficeFragShader
stage: Shader.Fragment
shader: "shaders/paperOffice.frag"
}
passes: [ Pass {
shaders: paperOfficeFragShader
}
]
}

View File

@@ -0,0 +1,125 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
// These properties names need to match the ones in the shader code!
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real roughness: 0.25
property real material_ior: 1.46
property real intensity: 1.0
property real texture_scaling: 0.1
property real bump_factor: 0.4
property vector3d diffuse_color: Qt.vector3d(0.451, 0.04, 0.035)
property vector3d emission_color: Qt.vector3d(0.0, 0.0, 0.0)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy | ShaderInfo.Diffuse
}
property TextureInput uEnvironmentTexture: TextureInput {
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
property TextureInput emissive_texture: TextureInput {
id: emissiveTexture
enabled: true
texture: Texture {
id: emissiveImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/emissive.png"
}
}
property TextureInput emissive_mask_texture: TextureInput {
id: emissiveMaskTexture
enabled: true
texture: Texture {
id: emissiveMaskImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/emissive_mask.png"
}
}
property TextureInput randomGradient1D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient1D.png"
}
}
property TextureInput randomGradient2D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient2D.png"
}
}
property TextureInput randomGradient3D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient3D.png"
}
}
property TextureInput randomGradient4D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient4D.png"
}
}
Shader {
id: plasticStructuredRedEmissiveFragShader
stage: Shader.Fragment
shader: "shaders/plasticStructuredRedEmissive.frag"
}
passes: [ Pass {
shaders: plasticStructuredRedEmissiveFragShader
}
]
}

View File

@@ -0,0 +1,104 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
// These properties names need to match the ones in the shader code!
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real roughness: 0.25
property real material_ior: 1.46
property real intensity: 1.0
property real texture_scaling: 0.1
property real bump_factor: 0.4
property vector3d diffuse_color: Qt.vector3d(0.451, 0.04, 0.035)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy | ShaderInfo.Diffuse
}
property TextureInput uEnvironmentTexture: TextureInput {
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
source: "maps/shadow.png"
}
}
property TextureInput randomGradient1D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient1D.png"
}
}
property TextureInput randomGradient2D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient2D.png"
}
}
property TextureInput randomGradient3D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient3D.png"
}
}
property TextureInput randomGradient4D: TextureInput {
texture: Texture {
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/randomGradient4D.png"
}
}
Shader {
id: plasticStructuredRedFragShader
stage: Shader.Fragment
shader: "shaders/plasticStructuredRed.frag"
}
passes: [ Pass {
shaders: plasticStructuredRedFragShader
}
]
}

View File

@@ -0,0 +1,96 @@
/****************************************************************************
**
** Copyright (C) 2019 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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
property bool uEnvironmentMappingEnabled: true
property bool uShadowMappingEnabled: false
property real material_ior: 2.5
property real anisotropy: 0.8
property vector2d texture_tiling: Qt.vector2d(8, 5)
shaderInfo: ShaderInfo {
version: "330"
type: "GLSL"
shaderKey: ShaderInfo.Glossy
}
property TextureInput uEnvironmentTexture: TextureInput {
id: uEnvironmentTexture
enabled: uEnvironmentMappingEnabled
texture: Texture {
id: envImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/spherical_checker.png"
}
}
property TextureInput uBakedShadowTexture: TextureInput {
enabled: uShadowMappingEnabled
texture: Texture {
id: shadowImage
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/shadow.png"
}
}
property TextureInput diffuse_texture: TextureInput {
enabled: true
texture: Texture {
id: diffuseTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/concentric_milled_steel.png"
}
}
property TextureInput anisotropy_rot_texture: TextureInput {
enabled: true
texture: Texture {
id: anisoTexture
tilingModeHorizontal: Texture.Repeat
tilingModeVertical: Texture.Repeat
source: "maps/concentric_milled_steel_aniso.png"
}
}
Shader {
id: steelMilledConcentricFragShader
stage: Shader.Fragment
shader: "shaders/steelMilledConcentric.frag"
}
passes: [
Pass {
shaders: steelMilledConcentricFragShader
}
]
}

View File

@@ -0,0 +1,139 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Emission")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Intensity")
tooltip: qsTr("Set the emission intensity.")
}
SecondColumnLayout {
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.intensity
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Map Texture")
tooltip: qsTr("Defines a texture for emissive map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.emissive_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("MaskTexture")
tooltip: qsTr("Defines a texture for emissive mask.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.emissive_mask_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel { text: qsTr("Emission Color") }
ColorEditor {
backendValue: backendValues.emission_color
supportGradient: false
isVector3D: true
}
}
}
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Base Color") }
ColorEditor {
backendValue: backendValues.base_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Roughness")
tooltip: qsTr("Set the material roughness.")
}
SecondColumnLayout {
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
AluminumAnodizedEmissiveMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,71 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Base Color") }
ColorEditor {
backendValue: backendValues.base_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Roughness")
tooltip: qsTr("Set the material roughness.")
}
SecondColumnLayout {
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
AluminumAnodizedMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,268 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
id: materialRoot
width: parent.width
Section {
caption: qsTr("Roughness")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Metal Color") }
ColorEditor {
backendValue: backendValues.metal_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a horizontal texture for roughness map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.roughness_texture_u_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a vertical texture for roughness map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.roughness_texture_v_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Reflection")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Stretch")
tooltip: qsTr("Set the material reflection stretch.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflection_stretch
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a vertical texture for roughness map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.roughness_texture_v_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Brush")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Strength")
tooltip: qsTr("Set the strength of the brush strokes.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.brushing_strength
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Tiling")
tooltip: qsTr("Sets the tiling repeat of the brush map.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_x
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "X"
color: StudioTheme.Values.theme3DAxisXColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_y
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Y"
color: StudioTheme.Values.theme3DAxisYColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_z
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Z"
color: StudioTheme.Values.theme3DAxisZColor
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Bump")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Amount")
tooltip: qsTr("Set the bump map bumpiness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 2
decimals: 2
stepSize: 0.1
backendValue: backendValues.bump_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for bump map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.bump_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
AluminumBrushedMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,421 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Emission")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Emission Color") }
ColorEditor {
backendValue: backendValues.emission_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Intensity")
tooltip: qsTr("Set the emission intensity.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.intensity
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Map Texture")
tooltip: qsTr("Defines a texture for emissive map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.emissive_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("MaskTexture")
tooltip: qsTr("Defines a texture for emissive mask.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.emissive_mask_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Mask Offset")
tooltip: qsTr("Sets the mask offset of emissive map.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.emissive_mask_offset_x
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "X"
color: StudioTheme.Values.theme3DAxisXColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.emissive_mask_offset_y
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Y"
color: StudioTheme.Values.theme3DAxisYColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.emissive_mask_offset_z
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Z"
color: StudioTheme.Values.theme3DAxisZColor
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Roughness")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Metal Color") }
ColorEditor {
backendValue: backendValues.metal_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Map Offset")
tooltip: qsTr("Set the material roughness map offset.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness_map_offset
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Map scale")
tooltip: qsTr("Set the material roughness map scale.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness_map_scale
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for roughness map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.roughness_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Reflection")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Map Offset")
tooltip: qsTr("Set the material reclection map offset.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflection_map_offset
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Map scale")
tooltip: qsTr("Set the material reclection map scale.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflection_map_scale
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for reflection map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.reflection_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Tiling")
tooltip: qsTr("Sets the tiling repeat of the reflection map.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_x
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "X"
color: StudioTheme.Values.theme3DAxisXColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_y
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Y"
color: StudioTheme.Values.theme3DAxisYColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_z
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Z"
color: StudioTheme.Values.theme3DAxisZColor
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Bump")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Amount")
tooltip: qsTr("Set the bump map bumpiness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 2
decimals: 2
stepSize: 0.1
backendValue: backendValues.bump_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for bump map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.bump_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
AluminumEmissiveMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,281 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Roughness")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Metal Color") }
ColorEditor {
backendValue: backendValues.metal_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Map Offset")
tooltip: qsTr("Set the material roughness map offset.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness_map_offset
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Map scale")
tooltip: qsTr("Set the material roughness map scale.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness_map_scale
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for roughness map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.roughness_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Reflection")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Map Offset")
tooltip: qsTr("Set the material reclection map offset.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflection_map_offset
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Map scale")
tooltip: qsTr("Set the material reclection map scale.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflection_map_scale
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for reflection map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.reflection_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Tiling")
tooltip: qsTr("Sets the tiling repeat of the reflection map.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_x
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "X"
color: StudioTheme.Values.theme3DAxisXColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_y
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Y"
color: StudioTheme.Values.theme3DAxisYColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.tiling_z
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Z"
color: StudioTheme.Values.theme3DAxisZColor
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Bump")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Amount")
tooltip: qsTr("Set the bump map bumpiness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 2
decimals: 2
stepSize: 0.1
backendValue: backendValues.bump_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for bump map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.bump_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
AluminumMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,71 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Metal Color") }
ColorEditor {
backendValue: backendValues.metal_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Roughness")
tooltip: qsTr("Set the material roughness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
CopperMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,205 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Custom Material")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Transparency")
tooltip: qsTr("Specifies if the material has transparency.")
}
SecondColumnLayout {
CheckBox {
text: backendValues.hasTransparency.valueToString
backendValue: backendValues.hasTransparency
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Refraction")
tooltip: qsTr("Specifies if the material has refraction.")
}
SecondColumnLayout {
CheckBox {
text: backendValues.hasRefraction.valueToString
backendValue: backendValues.hasRefraction
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Always Dirty")
tooltip: qsTr("Specifies if the material needs to be refreshed every time it is used.")
}
SecondColumnLayout {
CheckBox {
text: backendValues.alwaysDirty.valueToString
backendValue: backendValues.alwaysDirty
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Shader Info")
tooltip: qsTr("Shader info for the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.ShaderInfo"
backendValue: backendValues.shaderInfo
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Passes")
tooltip: qsTr("Render passes of the material.")
Layout.alignment: Qt.AlignTop
Layout.topMargin: 5
}
SecondColumnLayout {
EditableListView {
backendValue: backendValues.passes
model: backendValues.passes.expressionAsList
Layout.fillWidth: true
typeFilter: "QtQuick3D.Pass"
onAdd: function(value) { backendValues.passes.idListAdd(value) }
onRemove: function(idx) { backendValues.passes.idListRemove(idx) }
onReplace: function (idx, value) { backendValues.passes.idListReplace(idx, value) }
}
ExpandingSpacer {}
}
}
}
Section {
// Copied from quick3d's MaterialSection.qml
caption: qsTr("Material")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Light Probe")
tooltip: qsTr("Defines a texture for overriding or setting an image based lighting texture for use with this material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.lightProbe
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Displacement Map")
tooltip: qsTr("Defines a grayscale image used to offset the vertices of geometry across the surface of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.displacementMap
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Displacement Amount")
tooltip: qsTr("Controls the offset amount for the displacement map.")
}
SecondColumnLayout {
SpinBox {
minimumValue: -9999999
maximumValue: 9999999
decimals: 0
backendValue: backendValues.displacementAmount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Culling Mode")
tooltip: qsTr("Defines whether culling is enabled and which mode is actually enabled.")
}
SecondColumnLayout {
ComboBox {
scope: "Material"
model: ["BackFaceCulling", "FrontFaceCulling", "NoCulling"]
backendValue: backendValues.cullMode
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
CustomMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,73 @@
/****************************************************************************
**
** Copyright (C) 2021 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Section {
caption: qsTr("Environment Map")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Enabled")
tooltip: qsTr("Specifies if the environment map is enabled.")
}
SecondColumnLayout {
CheckBox {
text: backendValues.uEnvironmentMappingEnabled.valueToString
backendValue: backendValues.uEnvironmentMappingEnabled
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for environment map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.uEnvironmentTexture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}

View File

@@ -0,0 +1,512 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Bump")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Scale")
tooltip: qsTr("Set the scale of the bump bands.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 5
decimals: 2
stepSize: 0.1
backendValue: backendValues.bumpScale
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Bands")
tooltip: qsTr("Set the number of the bump bands.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10
decimals: 0
backendValue: backendValues.bumpBands
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Strength")
tooltip: qsTr("Set the glass bump map strength.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.glass_bfactor
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Internal")
tooltip: qsTr("Specifies if the bump map be used only for the internal lighting.")
}
SecondColumnLayout {
CheckBox {
text: backendValues.glass_binside.valueToString
backendValue: backendValues.glass_binside
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for bump map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.glass_bump_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Coordinates")
tooltip: qsTr("Sets the bump coordinates of the refraction.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.bumpCoords_x
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "X"
color: StudioTheme.Values.theme3DAxisXColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.bumpCoords_y
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Y"
color: StudioTheme.Values.theme3DAxisYColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.bumpCoords_z
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Z"
color: StudioTheme.Values.theme3DAxisZColor
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Glass Color") }
ColorEditor {
backendValue: backendValues.glass_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Roughness")
tooltip: qsTr("Set the material roughness.")
}
SecondColumnLayout {
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Blur Size")
tooltip: qsTr("Set the amount of blurring behind the glass.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 50
decimals: 2
backendValue: backendValues.blur_size
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Refract Depth")
tooltip: qsTr("Set the refract depth of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 5
decimals: 2
stepSize: 0.1
backendValue: backendValues.refract_depth
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Fresnel Power")
tooltip: qsTr("Set the fresnel power of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 100
decimals: 2
backendValue: backendValues.uFresnelPower
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Reflectivity")
tooltip: qsTr("Set the reflectivity of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflectivity_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Index of Refraction")
tooltip: qsTr("Set the index of refraction for the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1.4
maximumValue: 2.1
decimals: 2
stepSize: 0.1
backendValue: backendValues.glass_ior
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Band Light")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Band Light Color") }
ColorEditor {
backendValue: backendValues.intLightCol
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Falloff")
tooltip: qsTr("Set the light intensity falloff rate.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10
decimals: 2
backendValue: backendValues.intLightFall
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Angle")
tooltip: qsTr("Set the angle of lightsource. Band is perpendicular to this.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 360
decimals: 2
backendValue: backendValues.intLightRot
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Brightness")
tooltip: qsTr("Set the brightness of the band light.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.intLightBrt
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Position")
tooltip: qsTr("Sets the Position of the band light in the UV space.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.intLightPos_x
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel { text: "X" }
Spacer { implicitWidth: StudioTheme.Values.controlGap }
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.intLightPos_y
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel { text: "Y" }
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Random Gradient Maps")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("1D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient1D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("2D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient2D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("3D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient3D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("4D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient4D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
FrostedGlassMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,430 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Bump")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Scale")
tooltip: qsTr("Set the scale of the bump bands.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 5
decimals: 2
stepSize: 0.1
backendValue: backendValues.bumpScale
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Bands")
tooltip: qsTr("Set the number of the bump bands.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10
decimals: 0
backendValue: backendValues.bumpBands
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Coordinates")
tooltip: qsTr("Sets the bump coordinates of the refraction.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.bumpCoords_x
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "X"
color: StudioTheme.Values.theme3DAxisXColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.bumpCoords_y
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Y"
color: StudioTheme.Values.theme3DAxisYColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.bumpCoords_z
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Z"
color: StudioTheme.Values.theme3DAxisZColor
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Glass Color") }
ColorEditor {
backendValue: backendValues.glass_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Roughness")
tooltip: qsTr("Set the material roughness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Blur Size")
tooltip: qsTr("Set the amount of blurring behind the glass.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 50
decimals: 2
backendValue: backendValues.blur_size
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Fresnel Power")
tooltip: qsTr("Set the fresnel power of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 100
decimals: 2
backendValue: backendValues.uFresnelPower
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Reflectivity")
tooltip: qsTr("Set the reflectivity of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflectivity_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Index of Refraction")
tooltip: qsTr("Set the index of refraction for the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1.4
maximumValue: 2.1
decimals: 2
stepSize: 0.1
backendValue: backendValues.glass_ior
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Noise")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Scale")
tooltip: qsTr("Set the noise scale.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 40
decimals: 2
backendValue: backendValues.noiseScale
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Coordinates")
tooltip: qsTr("Sets the noise coordinates.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.noiseCoords_x
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "X"
color: StudioTheme.Values.theme3DAxisXColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.noiseCoords_y
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Y"
color: StudioTheme.Values.theme3DAxisYColor
}
ExpandingSpacer {}
}
PropertyLabel {}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 10000
decimals: 2
backendValue: backendValues.noiseCoords_z
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel {
text: "Z"
color: StudioTheme.Values.theme3DAxisZColor
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Random Gradient Maps")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("1D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient1D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("2D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient2D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("3D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient3D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("4D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient4D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
FrostedGlassSinglePassMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,127 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Glass Color") }
ColorEditor {
backendValue: backendValues.glass_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Fresnel Power")
tooltip: qsTr("Set the fresnel power of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 100
decimals: 2
backendValue: backendValues.uFresnelPower
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Minimum Opacity")
tooltip: qsTr("Set the minimum opacity of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.uMinOpacity
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Reflectivity")
tooltip: qsTr("Set the reflectivity of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflectivity_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Index of Refraction")
tooltip: qsTr("Set the index of refraction for the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1.4
maximumValue: 2.1
decimals: 2
stepSize: 0.1
backendValue: backendValues.glass_ior
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
GlassMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,127 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Glass Color") }
ColorEditor {
backendValue: backendValues.glass_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Fresnel Power")
tooltip: qsTr("Set the fresnel power of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 100
decimals: 2
backendValue: backendValues.uFresnelPower
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Roughness")
tooltip: qsTr("Set the roughness of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Reflectivity")
tooltip: qsTr("Set the reflectivity of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflectivity_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Index of Refraction")
tooltip: qsTr("Set the index of refraction for the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1.4
maximumValue: 2.1
decimals: 2
stepSize: 0.1
backendValue: backendValues.glass_ior
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
GlassRefractiveMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,123 @@
/****************************************************************************
**
** 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
ComboBox {
id: comboBox
property alias typeFilter: itemFilterModel.typeFilter
manualMapping: true
editable: true
model: comboBox.addDefaultItem(itemFilterModel.itemModel)
textInput.validator: RegExpValidator { regExp: /(^$|^[a-z_]\w*)/ }
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*/
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
|| comboBox.editText === parenthesize(defaultItem))
}
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 = parenthesize(comboBox.defaultItem)
} else {
if (comboBox.currentIndex === -1)
comboBox.editText = text
else if (comboBox.currentIndex === 0)
comboBox.editText = parenthesize(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(parenthesize(comboBox.defaultItem))
return copy
}
function parenthesize(value)
{
return "[" + value + "]"
}
}

View File

@@ -0,0 +1,269 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Transmission")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Transmission Weight")
tooltip: qsTr("Set the material transmission weight.")
}
SecondColumnLayout {
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.transmission_weight
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Reflection Weight")
tooltip: qsTr("Set the material reflection weight.")
}
SecondColumnLayout {
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflection_weight
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for transmission map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.transmission_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Translucency Falloff")
tooltip: qsTr("Set the falloff of the translucency of the material.")
}
SecondColumnLayout {
SpinBox {
maximumValue: 100
minimumValue: 0
decimals: 2
backendValue: backendValues.uTranslucentFalloff
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Opacity")
tooltip: qsTr("Set the opacity of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 100
decimals: 2
backendValue: backendValues.uOpacity
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture Tiling")
tooltip: qsTr("Sets the tiling repeat of the reflection map.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.texture_tiling_x
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel { text: "X" }
Spacer { implicitWidth: StudioTheme.Values.controlGap }
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.texture_tiling_y
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel { text: "Y" }
Spacer { implicitWidth: StudioTheme.Values.controlGap }
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Diffuse Map")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Light Wrap")
tooltip: qsTr("Set the diffuse light bend of the material.")
}
SecondColumnLayout {
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.uDiffuseLightWrap
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for diffuse map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.diffuse_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Bump")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Amount")
tooltip: qsTr("Set the bump map bumpiness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 2
decimals: 2
stepSize: 0.1
backendValue: backendValues.bump_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for bump map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.bump_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
PaperArtisticMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,277 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Transmission")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Transmission Weight")
tooltip: qsTr("Set the material transmission weight.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.transmission_weight
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Reflection Weight")
tooltip: qsTr("Set the material reflection weight.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.reflection_weight
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for transmission map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.transmission_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Translucency Falloff")
tooltip: qsTr("Set the falloff of the translucency of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 100
decimals: 2
backendValue: backendValues.uTranslucentFalloff
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Opacity")
tooltip: qsTr("Set the opacity of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 100
decimals: 2
backendValue: backendValues.uOpacity
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture Tiling")
tooltip: qsTr("Sets the tiling repeat of the reflection map.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.texture_tiling_x
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel { text: "X" }
Spacer { implicitWidth: StudioTheme.Values.controlGap }
SpinBox {
maximumValue: 1
minimumValue: 0
decimals: 2
stepSize: 0.1
backendValue: backendValues.texture_tiling_y
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel { text: "Y" }
Spacer { implicitWidth: StudioTheme.Values.controlGap }
ExpandingSpacer {}
}
PropertyLabel { text: qsTr("Paper Color") }
ColorEditor {
backendValue: backendValues.paper_color
supportGradient: false
isVector3D: true
}
}
}
Section {
caption: qsTr("Diffuse Map")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Light Wrap")
tooltip: qsTr("Set the diffuse light bend of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.uDiffuseLightWrap
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for diffuse map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.diffuse_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Bump")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Amount")
tooltip: qsTr("Set the bump map bumpiness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 2
decimals: 2
stepSize: 0.1
backendValue: backendValues.bump_amount
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for bump map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.bump_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,44 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
ShadowMapSection {
width: parent.width
}
PaperOfficeMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,271 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("Emission")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Intensity")
tooltip: qsTr("Set the emission intensity.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.intensity
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Map Texture")
tooltip: qsTr("Defines a texture for emissive map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.emissive_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("MaskTexture")
tooltip: qsTr("Defines a texture for emissive mask.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.emissive_mask_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel { text: qsTr("Emission Color") }
ColorEditor {
backendValue: backendValues.emission_color
supportGradient: false
isVector3D: true
}
}
}
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Diffuse Color") }
ColorEditor {
backendValue: backendValues.diffuse_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Roughness")
tooltip: qsTr("Set the material roughness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Index of Refraction")
tooltip: qsTr("Set the index of refraction for the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1.4
maximumValue: 1.6
decimals: 3
stepSize: 0.01
backendValue: backendValues.material_ior
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture Scaling")
tooltip: qsTr("Set the texture scaling of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.texture_scaling
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Bump Factor")
tooltip: qsTr("Set the strength of the bumpiness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.bump_factor
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Random Gradient Maps")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("1D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient1D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("2D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient2D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("3D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient3D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("4D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient4D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
PlasticStructuredRedEmissiveMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,203 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel { text: qsTr("Diffuse Color") }
ColorEditor {
backendValue: backendValues.diffuse_color
supportGradient: false
isVector3D: true
}
PropertyLabel {
text: qsTr("Roughness")
tooltip: qsTr("Set the material roughness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.roughness
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Index of Refraction")
tooltip: qsTr("Set the index of refraction for the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1.4
maximumValue: 1.6
decimals: 3
stepSize: 0.01
backendValue: backendValues.material_ior
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture Scaling")
tooltip: qsTr("Set the texture scaling of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.texture_scaling
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Bump Factor")
tooltip: qsTr("Set the strength of the bumpiness.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.bump_factor
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Random Gradient Maps")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("1D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient1D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("2D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient2D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("3D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient3D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("4D")
tooltip: qsTr("Defines a texture map used to create the random bumpiness of the material.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.randomGradient4D_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
PlasticStructuredRedMaterialSection {
width: parent.width
}
}

View File

@@ -0,0 +1,73 @@
/****************************************************************************
**
** Copyright (C) 2021 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Section {
caption: qsTr("Shadow Map")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Enabled")
tooltip: qsTr("Specifies if the shadow map is enabled.")
}
SecondColumnLayout {
CheckBox {
text: backendValues.uShadowMappingEnabled.valueToString
backendValue: backendValues.uShadowMappingEnabled
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Texture")
tooltip: qsTr("Defines a texture for shadow map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.uBakedShadowTexture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}

View File

@@ -0,0 +1,163 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
import StudioTheme 1.0 as StudioTheme
Column {
width: parent.width
Section {
caption: qsTr("General")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Index of Refraction")
tooltip: qsTr("Set the index of refraction for the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0.47
maximumValue: 2.97
decimals: 2
stepSize: 0.1
backendValue: backendValues.material_ior
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Anisotropy")
tooltip: qsTr("Set the anisotropy of the material.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 0.01
maximumValue: 1
decimals: 2
stepSize: 0.1
backendValue: backendValues.anisotropy
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
Section {
caption: qsTr("Textures")
width: parent.width
SectionLayout {
PropertyLabel {
text: qsTr("Tiling")
tooltip: qsTr("Sets the tiling repeat of the texture maps.")
}
SecondColumnLayout {
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.texture_tiling_x
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel { text: "X" }
Spacer { implicitWidth: StudioTheme.Values.controlGap }
SpinBox {
minimumValue: 1
maximumValue: 100
decimals: 0
backendValue: backendValues.texture_tiling_y
implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
ControlLabel { text: "Y" }
Spacer { implicitWidth: StudioTheme.Values.controlGap }
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Diffuse")
tooltip: qsTr("Defines a texture for diffuse map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.diffuse_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
PropertyLabel {
text: qsTr("Anisotropy")
tooltip: qsTr("Defines a texture for anisotropy map.")
}
SecondColumnLayout {
IdComboBox {
typeFilter: "QtQuick3D.Texture"
backendValue: backendValues.anisotropy_rot_texture_texture
defaultItem: qsTr("Default")
implicitWidth: StudioTheme.Values.singleControlColumnWidth
+ StudioTheme.Values.actionIndicatorWidth
}
ExpandingSpacer {}
}
}
}
}

View File

@@ -0,0 +1,48 @@
/****************************************************************************
**
** 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 QtQuick.Layouts 1.15
import HelperWidgets 2.0
Column {
width: parent.width
EnvironmentMapSection {
width: parent.width
}
ShadowMapSection {
width: parent.width
}
SteelMilledConcentricMaterialSection {
width: parent.width
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 563 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 347 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

@@ -0,0 +1,308 @@
MetaInfo {
Type {
name: "QtQuick3D.Materials.AluminumAnodizedEmissiveMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Aluminum Anod Emis"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.AluminumAnodizedMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Aluminum Anodized"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.AluminumBrushedMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Aluminum Brushed"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.AluminumEmissiveMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Aluminum Emissive"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.AluminumMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Aluminum"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.CopperMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Copper"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.FrostedGlassMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Frosted Glass"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.FrostedGlassSinglePassMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Frosted Glass Single Pass"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.GlassMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Glass"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.GlassRefractiveMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Glass Refractive"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.PaperArtisticMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Paper Artistic"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.PaperOfficeMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Paper Office"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.PlasticStructuredRedEmissiveMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Plastic Struct Emissive"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.PlasticStructuredRedMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Plastic Structured"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.SteelMilledConcentricMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
canBeDroppedInView3D: false
}
ItemLibraryEntry {
name: "Steel Milled Concentric"
category: "Qt Quick 3D Materials"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
}
}
Type {
name: "QtQuick3D.Materials.CustomMaterial"
icon: "images/custommaterial16.png"
Hints {
visibleInNavigator: true
canBeDroppedInNavigator: true
canBeDroppedInFormEditor: false
}
ItemLibraryEntry {
name: "Custom Material"
category: "Qt Quick 3D Custom Shader Utils"
libraryIcon: "images/custommaterial.png"
version: "1.14"
requiredImport: "QtQuick3D.Materials"
QmlSource { source: "./source/custommaterial_template.qml" }
ExtraFile { source: "./source/custom_material_default_shader.vert" }
ExtraFile { source: "./source/custom_material_default_shader.frag" }
}
}
}

View File

@@ -0,0 +1,5 @@
out vec4 fragColor;
void main() {
fragColor = vec4(1.0, 0.0, 0.0, 1.0);
}

View File

@@ -0,0 +1,6 @@
in vec3 attr_pos;
uniform mat4 modelViewProjection;
void main() {
gl_Position = modelViewProjection * vec4(attr_pos, 1.0);
}

View File

@@ -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 QtQuick3D 1.15
import QtQuick3D.Materials 1.15
CustomMaterial {
shaderInfo: shaderInformation
passes: renderPass
ShaderInfo {
id: shaderInformation
type: "GLSL"
version: "330"
}
Pass {
id: renderPass
shaders: [vertShader, fragShader]
}
Shader {
id: vertShader
stage: Shader.Vertex
shader: "custom_material_default_shader.vert"
}
Shader {
id: fragShader
stage: Shader.Fragment
shader: "custom_material_default_shader.frag"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 505 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 418 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 90 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 334 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 334 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 393 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 148 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 331 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 315 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 618 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 738 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 748 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 535 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 334 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

@@ -0,0 +1,56 @@
import QtQuick.tooling 1.2
// This file describes the plugin-supplied types contained in the library.
// It is used for QML tooling purposes only.
//
// This file was auto-generated by:
// 'qmlplugindump -nonrelocatable QtQuick3D.Materials 1.15'
Module {
dependencies: [
"QtQuick 2.15",
"QtQuick.Window 2.1",
"QtQuick3D 1.15",
"QtQuick3D.Effects 1.15"
]
Component {
name: "QQuick3DCustomMaterial"
defaultProperty: "data"
prototype: "QQuick3DMaterial"
exports: ["QtQuick3D.Materials/CustomMaterial 1.14"]
exportMetaObjectRevisions: [0]
Property { name: "hasTransparency"; type: "bool" }
Property { name: "hasRefraction"; type: "bool" }
Property { name: "alwaysDirty"; type: "bool" }
Property { name: "shaderInfo"; type: "QQuick3DShaderUtilsShaderInfo"; isPointer: true }
Property { name: "passes"; type: "QQuick3DShaderUtilsRenderPass"; isList: true; isReadonly: true }
Signal {
name: "hasTransparencyChanged"
Parameter { name: "hasTransparency"; type: "bool" }
}
Signal {
name: "hasRefractionChanged"
Parameter { name: "hasRefraction"; type: "bool" }
}
Signal {
name: "alwaysDirtyChanged"
Parameter { name: "alwaysDirty"; type: "bool" }
}
Method {
name: "setHasTransparency"
Parameter { name: "hasTransparency"; type: "bool" }
}
Method {
name: "setHasRefraction"
Parameter { name: "hasRefraction"; type: "bool" }
}
Method {
name: "setShaderInfo"
Parameter { name: "shaderInfo"; type: "QQuick3DShaderUtilsShaderInfo"; isPointer: true }
}
Method {
name: "setAlwaysDirty"
Parameter { name: "alwaysDirty"; type: "bool" }
}
}
}

View File

@@ -0,0 +1,22 @@
module QtQuick3D.Materials
plugin qtquick3dmaterialplugin
classname QtQuick3DMaterialPlugin
AluminumAnisotropicMaterial 1.0 AluminumAnisotropicMaterial.qml
AluminumBrushedMaterial 1.0 AluminumBrushedMaterial.qml
AluminumEmissiveMaterial 1.0 AluminumEmissiveMaterial.qml
AluminumMaterial 1.0 AluminumMaterial.qml
AluminumAnodizedEmissiveMaterial 1.0 AluminumAnodizedEmissiveMaterial.qml
AluminumAnodizedMaterial 1.0 AluminumAnodizedMaterial.qml
CopperMaterial 1.0 CopperMaterial.qml
GlassMaterial 1.0 GlassMaterial.qml
GlassRefractiveMaterial 1.0 GlassRefractiveMaterial.qml
FrostedGlassMaterial 1.0 FrostedGlassMaterial.qml
FrostedGlassSinglePassMaterial 1.0 FrostedGlassSinglePassMaterial.qml
PaperArtisticMaterial 1.0 PaperArtisticMaterial.qml
PaperOfficeMaterial 1.0 PaperOfficeMaterial.qml
PlasticStructuredRedMaterial 1.0 PlasticStructuredRedMaterial.qml
PlasticStructuredRedEmissiveMaterial 1.0 PlasticStructuredRedEmissiveMaterial.qml
SteelMilledConcentricMaterial 1.0 SteelMilledConcentricMaterial.qml
designersupported
depends QtQuick3D 1.0
depends QtQuick.Window 2.1