Kuesa::Qt3D::GLTF2MaterialProperties
Module: Kuesa Qt 3D API
GLTF2MaterialProperties is a base class holding properties common to all glTF2 Materials. More...
#include <Kuesa/Qt3D/api/materials/gltf2materialproperties.h>
Inherits from Qt3DCore::QNode
Inherited by Kuesa::Qt3D::Iro2AlphaEquiRectProperties, Kuesa::Qt3D::Iro2AlphaSemProperties, Kuesa::Qt3D::Iro2DiffuseEquiRectProperties, Kuesa::Qt3D::Iro2DiffuseSemProperties, Kuesa::Qt3D::Iro2GlassEquiRectProperties, Kuesa::Qt3D::Iro2GlassSemProperties, Kuesa::Qt3D::Iro2MatteAlphaProperties, Kuesa::Qt3D::Iro2PlanarReflectionEquiRectProperties, Kuesa::Qt3D::Iro2PlanarReflectionSemProperties, Kuesa::Qt3D::IroDiffuseAlphaProperties, Kuesa::Qt3D::IroDiffuseHemiProperties, Kuesa::Qt3D::IroDiffuseProperties, Kuesa::Qt3D::IroGlassAddProperties, Kuesa::Qt3D::IroMatteAddProperties, Kuesa::Qt3D::IroMatteAlphaProperties, Kuesa::Qt3D::IroMatteBackgroundProperties, Kuesa::Qt3D::IroMatteMultProperties, Kuesa::Qt3D::IroMatteOpaqueProperties, Kuesa::Qt3D::IroMatteSkyboxProperties, Kuesa::Qt3D::MetallicRoughnessProperties, Kuesa::Qt3D::UnlitProperties
Public Types
Public Slots
Public Signals
Public Functions
Public Properties
Detailed Description
| class Kuesa::Qt3D::GLTF2MaterialProperties;
|
GLTF2MaterialProperties is a base class holding properties common to all glTF2 Materials.
Since: Kuesa 2.0
A GLTF2MaterialProperties consists of the following base properties:
- alphaCutOff: The alpha cut off threshold
- baseColorUsesTexCoord1: Whether we use the first or second set of texture coordinates
- baseColorFactor: Base color of the material
- baseColorMap: A texture specifying the base color of the material
- textureTransform: Allows to transform (scale, translate, rotate) a texture.
Public Types Documentation
enum ColorSpace
Enumerator |
Value |
Description |
Linear |
|
|
sRGB |
|
|
Public Slots Documentation
slot setBaseColorUsesTexCoord1
| void setBaseColorUsesTexCoord1(
bool baseColorUsesTexCoord1
)
|
slot setBaseColorFactor
| void setBaseColorFactor(
const QColor & baseColorFactor
)
|
slot setBaseColorMap
| void setBaseColorMap(
Qt3DRender::QAbstractTexture * baseColorMap
)
|
slot setAlphaCutoff
| void setAlphaCutoff(
float alphaCutoff
)
|
slot setOutputColorSpace
| void setOutputColorSpace(
ColorSpace colorSpace
)
|
slot setReceivesShadows
| void setReceivesShadows(
bool receivesShadows
)
|
slot setShadowMapDepthTexture
| void setShadowMapDepthTexture(
Qt3DRender::QAbstractTexture * depthTexture
)
|
slot setShadowMapCubeDepthTexture
| void setShadowMapCubeDepthTexture(
Qt3DRender::QAbstractTexture * cubeMapDepthTexture
)
|
Public Signals Documentation
signal baseColorUsesTexCoord1Changed
| void baseColorUsesTexCoord1Changed(
bool
)
|
signal baseColorFactorChanged
| void baseColorFactorChanged(
const QColor & baseColorFactor
)
|
signal baseColorMapChanged
| void baseColorMapChanged(
Qt3DRender::QAbstractTexture * baseColorMap
)
|
signal alphaCutoffChanged
| void alphaCutoffChanged(
float alphaCutoff
)
|
signal receivesShadowsChanged
| void receivesShadowsChanged(
bool receivesShadows
)
|
signal shadowMapDepthTextureChanged
| void shadowMapDepthTextureChanged(
Qt3DRender::QAbstractTexture * depthTexture
)
|
signal shadowMapCubeDepthTextureChanged
| void shadowMapCubeDepthTextureChanged(
Qt3DRender::QAbstractTexture * cubeMapDepthTexture
)
|
signal outputColorSpaceChanged
| void outputColorSpaceChanged(
ColorSpace colorSpace
)
|
Public Functions Documentation
function GLTF2MaterialProperties
| explicit GLTF2MaterialProperties(
Qt3DCore::QNode * parent =nullptr
)
|
function ~GLTF2MaterialProperties
| ~GLTF2MaterialProperties()
|
function isBaseColorUsingTexCoord1
| bool isBaseColorUsingTexCoord1() const
|
function baseColorFactor
| QColor baseColorFactor() const
|
function baseColorMap
| Qt3DRender::QAbstractTexture * baseColorMap() const
|
function alphaCutoff
| float alphaCutoff() const
|
function outputColorSpace
| ColorSpace outputColorSpace() const
|
function addClientMaterial
| void addClientMaterial(
Qt3DRender::QMaterial * material
)
|
function clientMaterials
| QVector< Qt3DRender::QMaterial * > clientMaterials() const
|
function shaderData
| virtual Qt3DRender::QShaderData * shaderData() const =0
|
Reimplemented by: Kuesa::Qt3D::IroDiffuseProperties::shaderData, Kuesa::Qt3D::IroDiffuseAlphaProperties::shaderData, Kuesa::Qt3D::IroDiffuseHemiProperties::shaderData, Kuesa::Qt3D::IroGlassAddProperties::shaderData, Kuesa::Qt3D::IroMatteAddProperties::shaderData, Kuesa::Qt3D::IroMatteAlphaProperties::shaderData, Kuesa::Qt3D::IroMatteBackgroundProperties::shaderData, Kuesa::Qt3D::IroMatteMultProperties::shaderData, Kuesa::Qt3D::IroMatteOpaqueProperties::shaderData, Kuesa::Qt3D::IroMatteSkyboxProperties::shaderData, Kuesa::Qt3D::Iro2AlphaEquiRectProperties::shaderData, Kuesa::Qt3D::Iro2AlphaSemProperties::shaderData, Kuesa::Qt3D::Iro2DiffuseEquiRectProperties::shaderData, Kuesa::Qt3D::Iro2DiffuseSemProperties::shaderData, Kuesa::Qt3D::Iro2GlassEquiRectProperties::shaderData, Kuesa::Qt3D::Iro2GlassSemProperties::shaderData, Kuesa::Qt3D::Iro2MatteAlphaProperties::shaderData, Kuesa::Qt3D::Iro2PlanarReflectionEquiRectProperties::shaderData, Kuesa::Qt3D::Iro2PlanarReflectionSemProperties::shaderData, Kuesa::Qt3D::MetallicRoughnessProperties::shaderData, Kuesa::Qt3D::UnlitProperties::shaderData
function receivesShadows
| bool receivesShadows() const
|
function shadowMapDepthTexture
| Qt3DRender::QAbstractTexture * shadowMapDepthTexture() const
|
function shadowMapCubeDepthTexture
| Qt3DRender::QAbstractTexture * shadowMapCubeDepthTexture() const
|
Public Property Documentation
property baseColorUsesTexCoord1
| bool baseColorUsesTexCoord1;
|
property baseColorFactor
Specifies the baseColorFactor of the material
property baseColorMap
| Qt3DRender::QAbstractTexture * baseColorMap;
|
Note: If this property is nullptr and was set to a non nullptr value, this will trigger a recompilation of the shader. If it was a non nullptr value and is set to nullptr, it will also trigger a recompilation of the shader.
Specifies a texture to be used as baseColorFactor. The content of the texture is expected to be in sRGB color space.
property alphaCutoff
Alpha cutoff threshold. Any fragment with an alpha value higher than this property will be considered opaque. Any fragment with an alpha value lower than this property will be discarded and wont have any effect on the final result. For alphaCutoff to have any effect, it must be activated.
property receivesShadows
Specifies whether a surface should show any shadows that are cast on it. This Default is true
property outputColorSpace
| ColorSpace outputColorSpace;
|
Updated on 2023-07-03 at 11:02:09 +0000