DebugSettings QML Type

Used to configure debug settings. More...

Import Statement: import QtQuick3D
Inherits:

QtObject

Properties

Detailed Description

The renderer can be configured to output many different views to facilitate debugging. This component is used to configure these debug views.

In addition to programatic control, properties such as materialOverride and wireframeEnabled can also be controlled interactively via the DebugView item if an instance of that is added to the Qt Quick scene by the application.

Property Documentation

disableShadowCameraUpdate : bool [since 6.8]

When this property is enabled the camera update is disabled for the shadowmap. This means that the view frustum will be locked in space just for the shadowmap calculations. This is just a debug tool to be able to view the camera frustum and shadow map from different angles.

The default value is false.

This property was introduced in Qt 6.8.


drawCascades : bool [since 6.8]

When this property is enabled a frustum is drawn with splits indicating where the shadowmap cascades begin and end.

The default value is false.

This property was introduced in Qt 6.8.


drawDirectionalLightShadowBoxes : bool [since 6.8]

When this property is enabled a bounding box is drawn for every directional light's shadowmap.

The default value is false.

This property was introduced in Qt 6.8.


drawSceneCascadeIntersection : bool [since 6.8]

When this property is enabled the intersection of the shadowmap cascades and the casting and receiving objects of the scene is drawn.

The default value is false.

This property was introduced in Qt 6.8.


drawShadowCastingBounds : bool [since 6.8]

When this property is enabled a bounding box is drawn for the shadow casting objects.

The default value is false.

This property was introduced in Qt 6.8.


drawShadowReceivingBounds : bool [since 6.8]

When this property is enabled a bounding box is drawn for the shadow receiving objects.

The default value is false.

This property was introduced in Qt 6.8.


materialOverride : enumeration [since 6.5]

This property changes how all materials are rendered to only reflect a particular aspect of the overall rendering process. This can be used as a debugging tool to get a better understanding of why a material looks the way it does.

The default value is DebugSettings.None

ConstantDescription
DebugSettings.NoneMaterial overriding is bypassed, rendering occurs as normal.
DebugSettings.BaseColorThe BaseColor or Diffuse color of a material is passed through without any lighting.
DebugSettings.RoughnessThe Roughness of a material is passed through as an unlit greyscale value.
DebugSettings.MetalnessThe Metalness of a material is passed through as an unlit greyscale value.
DebugSettings.DiffuseOnly the diffuse contribution of the material after all lighting.
DebugSettings.SpecularOnly the specular contribution of the material after all lighting.
DebugSettings.ShadowOcclusionThe Occlusion caused by shadows as a greyscale value.
DebugSettings.EmissionOnly the emissive contribution of the material
DebugSettings.AmbientOcclusionOnly the Ambient Occlusion of the material
DebugSettings.NormalsThe interpolated world space Normal value of the material mapped to an RGB color.
DebugSettings.TangentsThe interpolated world space Tangent value of the material mapped to an RGB color. This will only be visible if the Tangent value is used.
DebugSettings.BinormalsThe interpolated world space Binormal value of the material mapped to an RGB color. This will only be visible if the Binormal value is used.
DebugSettings.F0This represents the Fresnel Reflectance at 0 Degrees. This will only be visible for materials that calculate an F0 value.

As an example, take the following scene with the Sponza model. The scene uses image-based lighting via SceneEnvironment::lightProbe and also has a directional light.

Setting DebugSettings.BaseColor:

Setting DebugSettings.Roughness:

Setting DebugSettings.Metalness:

Setting DebugSettings.Diffuse:

Setting DebugSettings.Specular:

Setting DebugSettings.Normals:

This property was introduced in Qt 6.5.


wireframeEnabled : bool [since 6.5]

This property changes how all materials are rendered by changing the polygon fill mode to be lines instead of filled. This appears as a wireframe, but the shaded color will still reflect the respective materials of the meshes.

The default value is false.

This property was introduced in Qt 6.5.