QGIS API Documentation 3.40.0-Bratislava (b56115d8743)
Loading...
Searching...
No Matches
Public Member Functions | List of all members
QgsFrameGraph Class Reference

3 More...

#include <qgsframegraph.h>

Inheritance diagram for QgsFrameGraph:
Inheritance graph
[legend]

Public Member Functions

 QgsFrameGraph (QSurface *surface, QSize s, Qt3DRender::QCamera *mainCamera, Qt3DCore::QEntity *root)
 Constructor.
 
void addClipPlanes (int nrClipPlanes)
 Setups nrClipPlanes clip planes in the forward pass to enable OpenGL clipping.
 
QgsPreviewQuadaddTexturePreviewOverlay (Qt3DRender::QTexture2D *texture, const QPointF &centerNDC, const QSizeF &size, QVector< Qt3DRender::QParameter * > additionalShaderParameters=QVector< Qt3DRender::QParameter * >())
 Adds an preview entity that shows a texture in real time for debugging purposes.
 
bool ambientOcclusionEnabled () const
 Returns whether Screen Space Ambient Occlusion is enabled.
 
float ambientOcclusionIntensity () const
 Returns the ambient occlusion intensity.
 
float ambientOcclusionRadius () const
 Returns the ambient occlusion radius.
 
float ambientOcclusionThreshold () const
 Returns the ambient occlusion threshold.
 
Qt3DRender::QTexture2D * blurredAmbientOcclusionFactorMap ()
 Returns blurred ambient occlusion factor values texture.
 
Qt3DRender::QLayer * castShadowsLayer ()
 Returns a layer object used to indicate that an entity will cast shadows.
 
Qt3DRender::QRenderCapture * depthRenderCapture ()
 Returns the render capture object used to take an image of the depth buffer of the scene.
 
QString dumpFrameGraph () const
 Dumps frame graph as string.
 
QString dumpSceneGraph () const
 Dumps scene graph as string.
 
Qt3DRender::QTexture2D * forwardRenderColorTexture ()
 Returns the color texture of the forward rendering pass.
 
Qt3DRender::QTexture2D * forwardRenderDepthTexture ()
 Returns the depth texture of the forward rendering pass.
 
Qt3DRender::QLayer * forwardRenderLayer ()
 Returns a layer object used to indicate that an entity will be rendered during the forward rendering pass.
 
Qt3DRender::QFrameGraphNode * frameGraphRoot ()
 Returns the root of the frame graph object.
 
bool frustumCullingEnabled () const
 Returns whether frustum culling is enabled.
 
Qt3DRender::QCamera * lightCamera ()
 Returns the light camera.
 
Qt3DRender::QCamera * mainCamera ()
 Returns the main camera.
 
QgsPostprocessingEntitypostprocessingEntity ()
 Returns the postprocessing entity.
 
Qt3DRender::QLayer * previewLayer ()
 Returns a layer object used to indicate that an entity is to be rendered during the preview textures rendering pass.
 
void removeClipPlanes ()
 Disables OpenGL clipping.
 
Qt3DRender::QRenderCapture * renderCapture ()
 Returns the render capture object used to take an image of the scene.
 
bool renderCaptureEnabled () const
 Returns whether it will be possible to render to an image.
 
Qt3DCore::QEntity * rootEntity ()
 Returns the root entity of the entities related to the frame graph (like the post processing entity and preview entity)
 
Qt3DCore::QEntity * rubberBandsRootEntity ()
 Returns entity for all rubber bands (to show them always on top)
 
void setAmbientOcclusionEnabled (bool enabled)
 Sets whether Screen Space Ambient Occlusion will be enabled.
 
void setAmbientOcclusionIntensity (float intensity)
 Sets the ambient occlusion intensity.
 
void setAmbientOcclusionRadius (float radius)
 Sets the ambient occlusion radius.
 
void setAmbientOcclusionThreshold (float threshold)
 Sets the ambient occlusion threshold.
 
void setClearColor (const QColor &clearColor)
 Sets the clear color of the scene (background color)
 
void setDebugOverlayEnabled (bool enabled)
 Sets whether debug overlay is enabled.
 
void setFrustumCullingEnabled (bool enabled)
 Sets whether frustum culling is enabled.
 
void setRenderCaptureEnabled (bool enabled)
 Sets whether it will be possible to render to an image.
 
void setShadowBias (float shadowBias)
 Sets the shadow bias value.
 
void setShadowMapResolution (int resolution)
 Sets the resolution of the shadow map.
 
void setShadowRenderingEnabled (bool enabled)
 Sets whether the shadow rendering is enabled.
 
void setSize (QSize s)
 Sets the size of the buffers used for rendering.
 
void setupDepthMapDebugging (bool enabled, Qt::Corner corner, double size)
 Sets the depth map debugging view port.
 
void setupDirectionalLight (const QgsDirectionalLightSettings &light, float maximumShadowRenderingDistance)
 Sets shadow rendering to use a directional light.
 
void setupEyeDomeLighting (bool enabled, double strength, int distance)
 Sets eye dome lighting shading related settings.
 
void setupShadowMapDebugging (bool enabled, Qt::Corner corner, double size)
 Sets the shadow map debugging view port.
 
float shadowBias () const
 Returns the shadow bias value.
 
int shadowMapResolution () const
 Returns the shadow map resolution.
 
Qt3DRender::QTexture2D * shadowMapTexture ()
 Returns the shadow map (a depth texture for the shadow rendering pass)
 
bool shadowRenderingEnabled () const
 Returns whether shadow rendering is enabled.
 
Qt3DRender::QLayer * transparentObjectLayer ()
 Returns a layer object used to indicate that the object is transparent.
 

Detailed Description

3

Container class that holds different objects related to frame graph of 3D scenes

A frame graph captures configuration of rendering passes when 3D scene gets rendered.

Note
Not available in Python bindings
Since
QGIS 3.16

Definition at line 61 of file qgsframegraph.h.

Constructor & Destructor Documentation

◆ QgsFrameGraph()

QgsFrameGraph::QgsFrameGraph ( QSurface *  surface,
QSize  s,
Qt3DRender::QCamera *  mainCamera,
Qt3DCore::QEntity *  root 
)

Constructor.

Definition at line 627 of file qgsframegraph.cpp.

Member Function Documentation

◆ addClipPlanes()

void QgsFrameGraph::addClipPlanes ( int  nrClipPlanes)

Setups nrClipPlanes clip planes in the forward pass to enable OpenGL clipping.

If nrClipPlanes is equal to 0, the clipping is disabled.

See also
removeClipPlanes()
Since
QGIS 3.40

Definition at line 1012 of file qgsframegraph.cpp.

◆ addTexturePreviewOverlay()

QgsPreviewQuad * QgsFrameGraph::addTexturePreviewOverlay ( Qt3DRender::QTexture2D *  texture,
const QPointF &  centerNDC,
const QSizeF &  size,
QVector< Qt3DRender::QParameter * >  additionalShaderParameters = QVector<Qt3DRender::QParameter *>() 
)

Adds an preview entity that shows a texture in real time for debugging purposes.

Definition at line 737 of file qgsframegraph.cpp.

◆ ambientOcclusionEnabled()

bool QgsFrameGraph::ambientOcclusionEnabled ( ) const
inline

Returns whether Screen Space Ambient Occlusion is enabled.

Since
QGIS 3.28

Definition at line 148 of file qgsframegraph.h.

◆ ambientOcclusionIntensity()

float QgsFrameGraph::ambientOcclusionIntensity ( ) const
inline

Returns the ambient occlusion intensity.

Since
QGIS 3.28

Definition at line 160 of file qgsframegraph.h.

◆ ambientOcclusionRadius()

float QgsFrameGraph::ambientOcclusionRadius ( ) const
inline

Returns the ambient occlusion radius.

Since
QGIS 3.28

Definition at line 172 of file qgsframegraph.h.

◆ ambientOcclusionThreshold()

float QgsFrameGraph::ambientOcclusionThreshold ( ) const
inline

Returns the ambient occlusion threshold.

Since
QGIS 3.28

Definition at line 184 of file qgsframegraph.h.

◆ blurredAmbientOcclusionFactorMap()

Qt3DRender::QTexture2D * QgsFrameGraph::blurredAmbientOcclusionFactorMap ( )
inline

Returns blurred ambient occlusion factor values texture.

Since
QGIS 3.28

Definition at line 83 of file qgsframegraph.h.

◆ castShadowsLayer()

Qt3DRender::QLayer * QgsFrameGraph::castShadowsLayer ( )
inline

Returns a layer object used to indicate that an entity will cast shadows.

Definition at line 88 of file qgsframegraph.h.

◆ depthRenderCapture()

Qt3DRender::QRenderCapture * QgsFrameGraph::depthRenderCapture ( )
inline

Returns the render capture object used to take an image of the depth buffer of the scene.

Definition at line 114 of file qgsframegraph.h.

◆ dumpFrameGraph()

QString QgsFrameGraph::dumpFrameGraph ( ) const

Dumps frame graph as string.

Definition at line 833 of file qgsframegraph.cpp.

◆ dumpSceneGraph()

QString QgsFrameGraph::dumpSceneGraph ( ) const

Dumps scene graph as string.

Definition at line 846 of file qgsframegraph.cpp.

◆ forwardRenderColorTexture()

Qt3DRender::QTexture2D * QgsFrameGraph::forwardRenderColorTexture ( )
inline

Returns the color texture of the forward rendering pass.

Definition at line 73 of file qgsframegraph.h.

◆ forwardRenderDepthTexture()

Qt3DRender::QTexture2D * QgsFrameGraph::forwardRenderDepthTexture ( )
inline

Returns the depth texture of the forward rendering pass.

Definition at line 75 of file qgsframegraph.h.

◆ forwardRenderLayer()

Qt3DRender::QLayer * QgsFrameGraph::forwardRenderLayer ( )
inline

Returns a layer object used to indicate that an entity will be rendered during the forward rendering pass.

Definition at line 90 of file qgsframegraph.h.

◆ frameGraphRoot()

Qt3DRender::QFrameGraphNode * QgsFrameGraph::frameGraphRoot ( )
inline

Returns the root of the frame graph object.

Definition at line 70 of file qgsframegraph.h.

◆ frustumCullingEnabled()

bool QgsFrameGraph::frustumCullingEnabled ( ) const
inline

Returns whether frustum culling is enabled.

Definition at line 118 of file qgsframegraph.h.

◆ lightCamera()

Qt3DRender::QCamera * QgsFrameGraph::lightCamera ( )
inline

Returns the light camera.

Definition at line 101 of file qgsframegraph.h.

◆ mainCamera()

Qt3DRender::QCamera * QgsFrameGraph::mainCamera ( )
inline

Returns the main camera.

Definition at line 99 of file qgsframegraph.h.

◆ postprocessingEntity()

QgsPostprocessingEntity * QgsFrameGraph::postprocessingEntity ( )
inline

Returns the postprocessing entity.

Definition at line 103 of file qgsframegraph.h.

◆ previewLayer()

Qt3DRender::QLayer * QgsFrameGraph::previewLayer ( )
inline

Returns a layer object used to indicate that an entity is to be rendered during the preview textures rendering pass.

Definition at line 86 of file qgsframegraph.h.

◆ removeClipPlanes()

void QgsFrameGraph::removeClipPlanes ( )

Disables OpenGL clipping.

See also
addClipPlanes()
Since
QGIS 3.40

Definition at line 1001 of file qgsframegraph.cpp.

◆ renderCapture()

Qt3DRender::QRenderCapture * QgsFrameGraph::renderCapture ( )
inline

Returns the render capture object used to take an image of the scene.

Definition at line 111 of file qgsframegraph.h.

◆ renderCaptureEnabled()

bool QgsFrameGraph::renderCaptureEnabled ( ) const
inline

Returns whether it will be possible to render to an image.

Since
QGIS 3.18

Definition at line 211 of file qgsframegraph.h.

◆ rootEntity()

Qt3DCore::QEntity * QgsFrameGraph::rootEntity ( )
inline

Returns the root entity of the entities related to the frame graph (like the post processing entity and preview entity)

Definition at line 105 of file qgsframegraph.h.

◆ rubberBandsRootEntity()

Qt3DCore::QEntity * QgsFrameGraph::rubberBandsRootEntity ( )
inline

Returns entity for all rubber bands (to show them always on top)

Definition at line 108 of file qgsframegraph.h.

◆ setAmbientOcclusionEnabled()

void QgsFrameGraph::setAmbientOcclusionEnabled ( bool  enabled)

Sets whether Screen Space Ambient Occlusion will be enabled.

Since
QGIS 3.28

Definition at line 880 of file qgsframegraph.cpp.

◆ setAmbientOcclusionIntensity()

void QgsFrameGraph::setAmbientOcclusionIntensity ( float  intensity)

Sets the ambient occlusion intensity.

Since
QGIS 3.28

Definition at line 887 of file qgsframegraph.cpp.

◆ setAmbientOcclusionRadius()

void QgsFrameGraph::setAmbientOcclusionRadius ( float  radius)

Sets the ambient occlusion radius.

Since
QGIS 3.28

Definition at line 893 of file qgsframegraph.cpp.

◆ setAmbientOcclusionThreshold()

void QgsFrameGraph::setAmbientOcclusionThreshold ( float  threshold)

Sets the ambient occlusion threshold.

Since
QGIS 3.28

Definition at line 899 of file qgsframegraph.cpp.

◆ setClearColor()

void QgsFrameGraph::setClearColor ( const QColor &  clearColor)

Sets the clear color of the scene (background color)

Definition at line 852 of file qgsframegraph.cpp.

◆ setDebugOverlayEnabled()

void QgsFrameGraph::setDebugOverlayEnabled ( bool  enabled)

Sets whether debug overlay is enabled.

Since
QGIS 3.26

Definition at line 996 of file qgsframegraph.cpp.

◆ setFrustumCullingEnabled()

void QgsFrameGraph::setFrustumCullingEnabled ( bool  enabled)

Sets whether frustum culling is enabled.

Definition at line 905 of file qgsframegraph.cpp.

◆ setRenderCaptureEnabled()

void QgsFrameGraph::setRenderCaptureEnabled ( bool  enabled)

Sets whether it will be possible to render to an image.

Since
QGIS 3.18

Definition at line 988 of file qgsframegraph.cpp.

◆ setShadowBias()

void QgsFrameGraph::setShadowBias ( float  shadowBias)

Sets the shadow bias value.

Definition at line 867 of file qgsframegraph.cpp.

◆ setShadowMapResolution()

void QgsFrameGraph::setShadowMapResolution ( int  resolution)

Sets the resolution of the shadow map.

Definition at line 873 of file qgsframegraph.cpp.

◆ setShadowRenderingEnabled()

void QgsFrameGraph::setShadowRenderingEnabled ( bool  enabled)

Sets whether the shadow rendering is enabled.

Definition at line 857 of file qgsframegraph.cpp.

◆ setSize()

void QgsFrameGraph::setSize ( QSize  s)

Sets the size of the buffers used for rendering.

Definition at line 973 of file qgsframegraph.cpp.

◆ setupDepthMapDebugging()

void QgsFrameGraph::setupDepthMapDebugging ( bool  enabled,
Qt::Corner  corner,
double  size 
)

Sets the depth map debugging view port.

Definition at line 949 of file qgsframegraph.cpp.

◆ setupDirectionalLight()

void QgsFrameGraph::setupDirectionalLight ( const QgsDirectionalLightSettings light,
float  maximumShadowRenderingDistance 
)

Sets shadow rendering to use a directional light.

Definition at line 806 of file qgsframegraph.cpp.

◆ setupEyeDomeLighting()

void QgsFrameGraph::setupEyeDomeLighting ( bool  enabled,
double  strength,
int  distance 
)

Sets eye dome lighting shading related settings.

Definition at line 916 of file qgsframegraph.cpp.

◆ setupShadowMapDebugging()

void QgsFrameGraph::setupShadowMapDebugging ( bool  enabled,
Qt::Corner  corner,
double  size 
)

Sets the shadow map debugging view port.

Definition at line 926 of file qgsframegraph.cpp.

◆ shadowBias()

float QgsFrameGraph::shadowBias ( ) const
inline

Returns the shadow bias value.

Definition at line 128 of file qgsframegraph.h.

◆ shadowMapResolution()

int QgsFrameGraph::shadowMapResolution ( ) const
inline

Returns the shadow map resolution.

Definition at line 133 of file qgsframegraph.h.

◆ shadowMapTexture()

Qt3DRender::QTexture2D * QgsFrameGraph::shadowMapTexture ( )
inline

Returns the shadow map (a depth texture for the shadow rendering pass)

Definition at line 77 of file qgsframegraph.h.

◆ shadowRenderingEnabled()

bool QgsFrameGraph::shadowRenderingEnabled ( ) const
inline

Returns whether shadow rendering is enabled.

Definition at line 123 of file qgsframegraph.h.

◆ transparentObjectLayer()

Qt3DRender::QLayer * QgsFrameGraph::transparentObjectLayer ( )
inline

Returns a layer object used to indicate that the object is transparent.

Since
QGIS 3.26

Definition at line 96 of file qgsframegraph.h.


The documentation for this class was generated from the following files: