QMetalRoughMaterial Class

(Qt3DExtras::QMetalRoughMaterial)

The QMetalRoughMaterial provides a default implementation of PBR lighting. More...

Header: #include <QMetalRoughMaterial>
qmake: QT += 3dextras
Since: Qt 5.9
Inherits: Qt3DRender::QMaterial

Properties

Public Functions

QMetalRoughMaterial(Qt3DCore::QNode *parent = nullptr)
~QMetalRoughMaterial()
QColor baseColor() const
float metalness() const
float roughness() const

Public Slots

void setBaseColor(const QColor &baseColor)
void setMetalness(float metalness)
void setRoughness(float roughness)

Signals

void baseColorChanged(const QColor &baseColor)
void metalnessChanged(float metalness)
void roughnessChanged(float roughness)

Protected Functions

QMetalRoughMaterial(QMetalRoughMaterialPrivate &dd, Qt3DCore::QNode *parent = nullptr)

Additional Inherited Members

  • 11 static public members inherited from QObject

Detailed Description

The QMetalRoughMaterial provides a default implementation of PBR lighting.

This material uses an effect with a single render pass approach and performs per fragment lighting. Techniques are provided for OpenGL 3 only.

Property Documentation

baseColor : QColor

Holds the current base color of the material.

Access functions:

QColor baseColor() const
void setBaseColor(const QColor &baseColor)

Notifier signal:

void baseColorChanged(const QColor &baseColor)

metalness : float

Holds the current metalness level of the material, since is a value between 0 (purely dielectric, the default) and 1 (purely metallic).

Access functions:

float metalness() const
void setMetalness(float metalness)

Notifier signal:

void metalnessChanged(float metalness)

roughness : float

Holds the current roughness level of the material.

Access functions:

float roughness() const
void setRoughness(float roughness)

Notifier signal:

void roughnessChanged(float roughness)

Member Function Documentation

QMetalRoughMaterial::QMetalRoughMaterial(Qt3DCore::QNode *parent = nullptr)

Default constructs an instance of QMetalRoughMaterial.

[protected] QMetalRoughMaterial::QMetalRoughMaterial(QMetalRoughMaterialPrivate &dd, Qt3DCore::QNode *parent = nullptr)

Copy constructor.

QMetalRoughMaterial::~QMetalRoughMaterial()

Destroys the QMetalRoughMaterial instance.

© 2019 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.