QGIS API Documentation 3.41.0-Master (af5edcb665c)
Loading...
Searching...
No Matches
Signals | Public Member Functions | List of all members
Qgs3DMapSettings Class Reference

3 More...

#include <qgs3dmapsettings.h>

Inheritance diagram for Qgs3DMapSettings:
Inheritance graph
[legend]

Signals

void ambientOcclusionSettingsChanged ()
 Emitted when ambient occlusion rendering settings are changed.
 
void axisSettingsChanged ()
 Emitted when 3d axis rendering settings are changed.
 
void backgroundColorChanged ()
 Emitted when the background color has changed.
 
void cameraMovementSpeedChanged ()
 Emitted when the camera movement speed was changed.
 
void cameraNavigationModeChanged ()
 Emitted when the camera navigation mode was changed.
 
void debugDepthMapSettingsChanged ()
 Emitted when depth map debugging has changed.
 
void debugOverlayEnabledChanged (bool debugOverlayEnabled)
 Emitted when the debug overaly is enabled or disabled.
 
void debugShadowMapSettingsChanged ()
 Emitted when shadow map debugging has changed.
 
void directionalLightsChanged ()
 Emitted when the list of directional lights changes.
 
void extentChanged ()
 Emitted when the 3d view's 2d extent has changed.
 
void eyeDomeLightingDistanceChanged ()
 Emitted when the eye dome lighting distance has changed.
 
void eyeDomeLightingEnabledChanged ()
 Emitted when the flag whether eye dome lighting is used has changed.
 
void eyeDomeLightingStrengthChanged ()
 Emitted when the eye dome lighting strength has changed.
 
void fieldOfViewChanged ()
 Emitted when the camera lens field of view changes.
 
void fpsCounterEnabledChanged (bool fpsCounterEnabled)
 Emitted when the FPS counter is enabled or disabled.
 
void layersChanged ()
 Emitted when the list of map layers for 3d rendering has changed.
 
void lightSourcesChanged ()
 Emitted when any of the light source settings in the map changes.
 
Q_DECL_DEPRECATED void mapTileResolutionChanged ()
 Emitted when the map tile resoulution has changed.
 
Q_DECL_DEPRECATED void maxTerrainGroundErrorChanged ()
 Emitted when the maximum terrain ground error has changed.
 
Q_DECL_DEPRECATED void maxTerrainScreenErrorChanged ()
 Emitted when the maximum terrain screen error has changed.
 
void originChanged ()
 Emitted when the world's origin point has been shifted.
 
void pointLightsChanged ()
 Emitted when the list of point lights changes.
 
void projectionTypeChanged ()
 Emitted when the camera lens projection type changes.
 
void renderersChanged ()
 Emitted when the list of map's extra renderers have been modified.
 
void selectionColorChanged ()
 Emitted when the selection color has changed.
 
void settingsChanged ()
 Emitted when one of the configuration settings has changed.
 
void shadowSettingsChanged ()
 Emitted when shadow rendering settings are changed.
 
void showCameraRotationCenterChanged ()
 Emitted when the flag whether camera's rotation center is shown has changed.
 
void showCameraViewCenterChanged ()
 Emitted when the flag whether camera's view center is shown has changed.
 
void showDebugPanelChanged (bool shown)
 Emitted when the Show debug panel checkbox changes value.
 
void showExtentIn2DViewChanged ()
 Emitted when the parameter to display 3d view's extent in the 2D canvas has changed.
 
void showLabelsChanged ()
 Emitted when the flag whether labels are displayed on terrain tiles has changed.
 
void showLightSourceOriginsChanged ()
 Emitted when the flag whether light source origins are shown has changed.
 
void showTerrainBoundingBoxesChanged ()
 Emitted when the flag whether terrain's bounding boxes are shown has changed.
 
void showTerrainTilesInfoChanged ()
 Emitted when the flag whether terrain's tile info is shown has changed.
 
void skyboxSettingsChanged ()
 Emitted when skybox settings are changed.
 
void stopUpdatesChanged ()
 Emitted when the flag whether to keep updating scene has changed.
 
Q_DECL_DEPRECATED void terrainElevationOffsetChanged (double newElevation)
 Emitted when the terrain elevation offset is changed.
 
void terrainGeneratorChanged ()
 Emitted when the terrain generator has changed.
 
void terrainMapThemeChanged ()
 Emitted when terrain's map theme has changed.
 
void terrainSettingsChanged ()
 Emitted when the terrain settings are changed.
 
void terrainShadingChanged ()
 Emitted when terrain shading enabled flag or terrain shading material has changed.
 
Q_DECL_DEPRECATED void terrainVerticalScaleChanged ()
 Emitted when the vertical scale of the terrain has changed.
 
void viewFrustumVisualizationEnabledChanged ()
 Emitted when the camera's view frustum visualization on the main 2D map canvas is enabled or disabled.
 

Public Member Functions

 Qgs3DMapSettings ()
 
 Qgs3DMapSettings (const Qgs3DMapSettings &other)
 
 ~Qgs3DMapSettings () override
 
QgsAmbientOcclusionSettings ambientOcclusionSettings () const
 Returns the current configuration of screen space ambient occlusion.
 
QColor backgroundColor () const
 Returns background color of the 3D map view.
 
double cameraMovementSpeed () const
 Returns the camera movement speed.
 
Qgis::NavigationMode cameraNavigationMode () const
 Returns the navigation mode used by the camera.
 
void configureTerrainFromProject (QgsProjectElevationProperties *properties, const QgsRectangle &fullExtent)
 Configures the map's terrain settings directly from a project's elevation properties.
 
QgsCoordinateReferenceSystem crs () const
 Returns coordinate reference system used in the 3D scene.
 
Qt::Corner debugDepthMapCorner () const
 Returns the corner where the shadow map preview is displayed.
 
bool debugDepthMapEnabled () const
 Returns whether the shadow map debugging is enabled.
 
double debugDepthMapSize () const
 Returns the size of the shadow map preview.
 
Qt::Corner debugShadowMapCorner () const
 Returns the corner where the shadow map preview is displayed.
 
bool debugShadowMapEnabled () const
 Returns whether the shadow map debugging is enabled.
 
double debugShadowMapSize () const
 Returns the size of the shadow map preview.
 
QgsRectangle extent () const
 Returns the 3D scene's 2D extent in the 3D scene's CRS.
 
int eyeDomeLightingDistance () const
 Returns the eye dome lighting distance value (contributes to the contrast of the image)
 
bool eyeDomeLightingEnabled () const
 Returns whether eye dome lighting is used.
 
double eyeDomeLightingStrength () const
 Returns the eye dome lighting strength value.
 
float fieldOfView () const
 Returns the camera lens' field of view.
 
Qgs3DAxisSettings get3DAxisSettings () const
 Returns the current configuration of 3d axis.
 
bool isDebugOverlayEnabled () const
 Returns whether debug overlay is enabled.
 
bool isFpsCounterEnabled () const
 Returns whether FPS counter label is enabled.
 
bool isSkyboxEnabled () const
 Returns whether the skybox is enabled.
 
bool isTerrainShadingEnabled () const
 Returns whether terrain shading is enabled.
 
QList< QgsMapLayer * > layers () const
 Returns the list of 3D map layers to be rendered in the scene.
 
QList< QgsLightSource * > lightSources () const
 Returns list of directional light sources defined in the scene.
 
QgsMapThemeCollectionmapThemeCollection () const
 Returns pointer to the collection of map themes.
 
Q_DECL_DEPRECATED int mapTileResolution () const
 Returns resolution (in pixels) of the texture of a terrain tile.
 
QgsVector3D mapToWorldCoordinates (const QgsVector3D &mapCoords) const
 Converts map coordinates to 3D world coordinates (applies offset and turns (x,y,z) into (x,-z,y))
 
Q_DECL_DEPRECATED double maxTerrainGroundError () const
 Returns maximum ground error of terrain tiles in world units.
 
Q_DECL_DEPRECATED double maxTerrainScreenError () const
 Returns maximum allowed screen error of terrain tiles in pixels.
 
Qgs3DMapSettingsoperator= (Qgs3DMapSettings const &)=delete
 
QgsVector3D origin () const
 Returns coordinates in map CRS at which 3D scene has origin (0,0,0).
 
double outputDpi () const
 Returns DPI used for conversion between real world units (e.g.
 
const QgsPathResolverpathResolver () const
 Returns the path resolver for conversion between relative and absolute paths during rendering operations, e.g.
 
Qt3DRender::QCameraLens::ProjectionType projectionType () const
 Returns the camera lens' projection type.
 
void readXml (const QDomElement &elem, const QgsReadWriteContext &context)
 Reads configuration from a DOM element previously written by writeXml()
 
Qgis::RendererUsage rendererUsage () const
 Returns the renderer usage.
 
void resolveReferences (const QgsProject &project)
 Resolves references to other objects (map layers) after the call to readXml()
 
QColor selectionColor () const
 Returns color used for selected features.
 
void set3DAxisSettings (const Qgs3DAxisSettings &axisSettings, bool force=false)
 Sets the current configuration of 3d axis.
 
void setAmbientOcclusionSettings (const QgsAmbientOcclusionSettings &ambientOcclusionSettings)
 Sets the current configuration of screen space ambient occlusion.
 
void setBackgroundColor (const QColor &color)
 Sets background color of the 3D map view.
 
void setCameraMovementSpeed (double movementSpeed)
 Sets the camera movement speed.
 
void setCameraNavigationMode (Qgis::NavigationMode navigationMode)
 Sets the navigation mode for the camera.
 
void setCrs (const QgsCoordinateReferenceSystem &crs)
 Sets coordinate reference system used in the 3D scene.
 
void setDebugDepthMapSettings (bool enabled, Qt::Corner corner, double size)
 Sets the debugging settings of the depth map.
 
void setDebugShadowMapSettings (bool enabled, Qt::Corner corner, double size)
 Sets the debugging settings of the shadow map.
 
void setExtent (const QgsRectangle &extent)
 Sets the 3D scene's 2D extent in the 3D scene's CRS, while also setting the scene's origin to the extent's center This needs to be called during initialization, as terrain will only be generated within this extent and layer 3D data will only be loaded within this extent too.
 
void setEyeDomeLightingDistance (int distance)
 Sets the eye dome lighting distance value (contributes to the contrast of the image.
 
void setEyeDomeLightingEnabled (bool enabled)
 Sets whether eye dome lighting will be used.
 
void setEyeDomeLightingStrength (double strength)
 Sets the eye dome lighting strength value.
 
void setFieldOfView (const float fieldOfView)
 Sets the camera lens' field of view.
 
void setIsDebugOverlayEnabled (bool debugOverlayEnabled)
 Sets whether debug overlay is enabled The debug overlay displays some debugging and profiling information.
 
void setIsFpsCounterEnabled (bool fpsCounterEnabled)
 Sets whether FPS counter label is enabled.
 
void setIsSkyboxEnabled (bool enabled)
 Sets whether the skybox is enabled.
 
void setLayers (const QList< QgsMapLayer * > &layers)
 Sets the list of 3D map layers to be rendered in the scene.
 
void setLightSources (const QList< QgsLightSource * > &lights)
 Sets the list of light sources defined in the scene.
 
void setMapThemeCollection (QgsMapThemeCollection *mapThemes)
 Sets pointer to the collection of map themes.
 
Q_DECL_DEPRECATED void setMapTileResolution (int res)
 Sets resolution (in pixels) of the texture of a terrain tile.
 
Q_DECL_DEPRECATED void setMaxTerrainGroundError (double error)
 Sets the maximum ground error of terrain tiles in world units.
 
Q_DECL_DEPRECATED void setMaxTerrainScreenError (double error)
 Sets maximum allowed screen error of terrain tiles in pixels.
 
void setOrigin (const QgsVector3D &origin)
 Sets coordinates in map CRS at which our 3D world has origin (0,0,0)
 
void setOutputDpi (const double dpi)
 Sets DPI used for conversion between real world units (e.g.
 
void setPathResolver (const QgsPathResolver &resolver)
 Sets the path resolver for conversion between relative and absolute paths during rendering operations, e.g.
 
void setProjectionType (const Qt3DRender::QCameraLens::ProjectionType projectionType)
 Sets the camera lens' projection type.
 
void setRendererUsage (Qgis::RendererUsage rendererUsage)
 Sets the renderer usage.
 
void setSelectionColor (const QColor &color)
 Sets color used for selected features.
 
void setShadowSettings (const QgsShadowSettings &shadowSettings)
 Sets the current configuration of shadow rendering.
 
void setShowCameraRotationCenter (bool enabled)
 Sets whether to show camera's rotation center as a sphere (for debugging)
 
void setShowCameraViewCenter (bool enabled)
 Sets whether to show camera's view center as a sphere (for debugging)
 
void setShowDebugPanel (bool enabled)
 Sets whether the debug side panel is shown.
 
void setShowExtentIn2DView (bool show)
 Sets whether the extent is displayed on the main 2D map canvas.
 
void setShowLabels (bool enabled)
 Sets whether to display labels on terrain tiles.
 
void setShowLightSourceOrigins (bool enabled)
 Sets whether to show light source origins as a sphere (for debugging)
 
void setShowTerrainBoundingBoxes (bool enabled)
 Sets whether to display bounding boxes of terrain tiles (for debugging)
 
void setShowTerrainTilesInfo (bool enabled)
 Sets whether to display extra tile info on top of terrain tiles (for debugging)
 
void setSkyboxSettings (const QgsSkyboxSettings &skyboxSettings)
 Sets the current configuration of the skybox.
 
void setStopUpdates (bool enabled)
 Sets whether scene updates on camera movement should be enabled.
 
Q_DECL_DEPRECATED void setTerrainElevationOffset (double offset)
 Sets the terrain elevation offset (used to move the terrain up or down)
 
void setTerrainGenerator (QgsTerrainGenerator *gen)
 Sets terrain generator and sets extent() as the generator's extent.
 
void setTerrainMapTheme (const QString &theme)
 Sets name of the map theme.
 
void setTerrainRenderingEnabled (bool terrainRenderingEnabled)
 Sets whether the 2D terrain surface will be rendered in.
 
void setTerrainSettings (QgsAbstractTerrainSettings *settings)
 Sets the terrain settings.
 
void setTerrainShadingEnabled (bool enabled)
 Sets whether terrain shading is enabled.
 
void setTerrainShadingMaterial (const QgsPhongMaterialSettings &material)
 Sets terrain shading material.
 
Q_DECL_DEPRECATED void setTerrainVerticalScale (double zScale)
 Sets vertical scale (exaggeration) of terrain (1 = true scale, > 1 = hills get more pronounced)
 
void setTransformContext (const QgsCoordinateTransformContext &context)
 Sets the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system.
 
void setViewFrustumVisualizationEnabled (bool enabled)
 Sets whether the camera's view frustum is visualized on the 2D map canvas.
 
void setViewSyncMode (Qgis::ViewSyncModeFlags mode)
 Sets the view sync mode (used to synchronize the 2D main map canvas and the 3D camera navigation)
 
QgsShadowSettings shadowSettings () const
 Returns the current configuration of shadows.
 
bool showCameraRotationCenter () const
 Returns whether to show camera's rotation center as a sphere (for debugging)
 
bool showCameraViewCenter () const
 Returns whether to show camera's view center as a sphere (for debugging)
 
bool showDebugPanel () const
 Returns whether the debug side panel is shown.
 
bool showExtentIn2DView () const
 Returns whether the extent is displayed on the main 2D map canvas.
 
bool showLabels () const
 Returns whether to display labels on terrain tiles.
 
bool showLightSourceOrigins () const
 Returns whether to show light source origins as a sphere (for debugging)
 
bool showTerrainBoundingBoxes () const
 Returns whether to display bounding boxes of terrain tiles (for debugging)
 
bool showTerrainTilesInfo () const
 Returns whether to display extra tile info on top of terrain tiles (for debugging)
 
QgsSkyboxSettings skyboxSettings () const
 Returns the current configuration of the skybox.
 
bool stopUpdates () const
 Returns whether the scene updates on camera movement.
 
Q_DECL_DEPRECATED double terrainElevationOffset () const
 Returns the elevation offset of the terrain (used to move the terrain up or down)
 
QgsTerrainGeneratorterrainGenerator () const
 Returns the terrain generator.
 
QString terrainMapTheme () const
 Returns name of the map theme (from the active project) that will be used for terrain's texture.
 
bool terrainRenderingEnabled () const
 Returns whether the 2D terrain surface will be rendered.
 
const QgsAbstractTerrainSettingsterrainSettings () const
 Returns the terrain settings.
 
QgsPhongMaterialSettings terrainShadingMaterial () const
 Returns terrain shading material.
 
Q_DECL_DEPRECATED double terrainVerticalScale () const
 Returns vertical scale (exaggeration) of terrain.
 
QgsCoordinateTransformContext transformContext () const
 Returns the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system.
 
bool viewFrustumVisualizationEnabled () const
 Returns whether the camera's view frustum is visualized on the 2D map canvas.
 
Qgis::ViewSyncModeFlags viewSyncMode () const
 Returns the view sync mode (used to synchronize the 2D main map canvas and the 3D camera navigation)
 
QgsVector3D worldToMapCoordinates (const QgsVector3D &worldCoords) const
 Converts 3D world coordinates to map coordinates (applies offset and turns (x,y,z) into (x,-z,y))
 
QDomElement writeXml (QDomDocument &doc, const QgsReadWriteContext &context) const
 Writes configuration to a DOM element, to be used later with readXml()
 
- Public Member Functions inherited from QgsTemporalRangeObject
 QgsTemporalRangeObject (bool enabled=false)
 Constructor QgsTemporalRangeObject.
 
virtual ~QgsTemporalRangeObject ()=default
 
bool isTemporal () const
 Returns true if the object's temporal range is enabled, and the object will be filtered when rendering maps with a specific time range set.
 
void setIsTemporal (bool enabled)
 Sets whether the temporal range is enabled (i.e.
 
void setTemporalRange (const QgsDateTimeRange &range)
 Sets the temporal range for the object.
 
const QgsDateTimeRangetemporalRange () const
 Returns the datetime range for the object.
 

Detailed Description

3

Definition of the world.

Warning
Qgs3DMapSettings are a QObject subclass, and accordingly are not safe for access across different threads. See Qgs3DRenderContext instead for a safe snapshot of settings from Qgs3DMapSettings.

Definition at line 55 of file qgs3dmapsettings.h.

Constructor & Destructor Documentation

◆ Qgs3DMapSettings() [1/2]

Qgs3DMapSettings::Qgs3DMapSettings ( )

Definition at line 40 of file qgs3dmapsettings.cpp.

◆ Qgs3DMapSettings() [2/2]

Qgs3DMapSettings::Qgs3DMapSettings ( const Qgs3DMapSettings other)

Definition at line 50 of file qgs3dmapsettings.cpp.

◆ ~Qgs3DMapSettings()

Qgs3DMapSettings::~Qgs3DMapSettings ( )
override

Definition at line 114 of file qgs3dmapsettings.cpp.

Member Function Documentation

◆ ambientOcclusionSettings()

QgsAmbientOcclusionSettings Qgs3DMapSettings::ambientOcclusionSettings ( ) const

Returns the current configuration of screen space ambient occlusion.

Since
QGIS 3.28

Definition at line 1200 of file qgs3dmapsettings.cpp.

◆ ambientOcclusionSettingsChanged

void Qgs3DMapSettings::ambientOcclusionSettingsChanged ( )
signal

Emitted when ambient occlusion rendering settings are changed.

Since
QGIS 3.28

◆ axisSettingsChanged

void Qgs3DMapSettings::axisSettingsChanged ( )
signal

Emitted when 3d axis rendering settings are changed.

Since
QGIS 3.26

◆ backgroundColor()

QColor Qgs3DMapSettings::backgroundColor ( ) const

Returns background color of the 3D map view.

Definition at line 578 of file qgs3dmapsettings.cpp.

◆ backgroundColorChanged

void Qgs3DMapSettings::backgroundColorChanged ( )
signal

Emitted when the background color has changed.

◆ cameraMovementSpeed()

double Qgs3DMapSettings::cameraMovementSpeed ( ) const

Returns the camera movement speed.

Since
QGIS 3.18

Definition at line 1154 of file qgs3dmapsettings.cpp.

◆ cameraMovementSpeedChanged

void Qgs3DMapSettings::cameraMovementSpeedChanged ( )
signal

Emitted when the camera movement speed was changed.

Since
QGIS 3.18

◆ cameraNavigationMode()

Qgis::NavigationMode Qgs3DMapSettings::cameraNavigationMode ( ) const

Returns the navigation mode used by the camera.

Since
QGIS 3.18

Definition at line 1136 of file qgs3dmapsettings.cpp.

◆ cameraNavigationModeChanged

void Qgs3DMapSettings::cameraNavigationModeChanged ( )
signal

Emitted when the camera navigation mode was changed.

Since
QGIS 3.18

◆ configureTerrainFromProject()

void Qgs3DMapSettings::configureTerrainFromProject ( QgsProjectElevationProperties properties,
const QgsRectangle fullExtent 
)

Configures the map's terrain settings directly from a project's elevation properties.

Since
QGIS 3.26

Definition at line 651 of file qgs3dmapsettings.cpp.

◆ crs()

QgsCoordinateReferenceSystem Qgs3DMapSettings::crs ( ) const

Returns coordinate reference system used in the 3D scene.

See also
setCrs()

Definition at line 518 of file qgs3dmapsettings.cpp.

◆ debugDepthMapCorner()

Qt::Corner Qgs3DMapSettings::debugDepthMapCorner ( ) const

Returns the corner where the shadow map preview is displayed.

Definition at line 1318 of file qgs3dmapsettings.cpp.

◆ debugDepthMapEnabled()

bool Qgs3DMapSettings::debugDepthMapEnabled ( ) const

Returns whether the shadow map debugging is enabled.

Definition at line 1311 of file qgs3dmapsettings.cpp.

◆ debugDepthMapSettingsChanged

void Qgs3DMapSettings::debugDepthMapSettingsChanged ( )
signal

Emitted when depth map debugging has changed.

Since
QGIS 3.18

◆ debugDepthMapSize()

double Qgs3DMapSettings::debugDepthMapSize ( ) const

Returns the size of the shadow map preview.

Definition at line 1325 of file qgs3dmapsettings.cpp.

◆ debugOverlayEnabledChanged

void Qgs3DMapSettings::debugOverlayEnabledChanged ( bool  debugOverlayEnabled)
signal

Emitted when the debug overaly is enabled or disabled.

Since
QGIS 3.26

◆ debugShadowMapCorner()

Qt::Corner Qgs3DMapSettings::debugShadowMapCorner ( ) const

Returns the corner where the shadow map preview is displayed.

Definition at line 1287 of file qgs3dmapsettings.cpp.

◆ debugShadowMapEnabled()

bool Qgs3DMapSettings::debugShadowMapEnabled ( ) const

Returns whether the shadow map debugging is enabled.

Definition at line 1280 of file qgs3dmapsettings.cpp.

◆ debugShadowMapSettingsChanged

void Qgs3DMapSettings::debugShadowMapSettingsChanged ( )
signal

Emitted when shadow map debugging has changed.

Since
QGIS 3.18

◆ debugShadowMapSize()

double Qgs3DMapSettings::debugShadowMapSize ( ) const

Returns the size of the shadow map preview.

Definition at line 1294 of file qgs3dmapsettings.cpp.

◆ directionalLightsChanged

void Qgs3DMapSettings::directionalLightsChanged ( )
signal

Emitted when the list of directional lights changes.

Since
QGIS 3.16

◆ extent()

QgsRectangle Qgs3DMapSettings::extent ( ) const

Returns the 3D scene's 2D extent in the 3D scene's CRS.

See also
crs()
Since
QGIS 3.30

Definition at line 454 of file qgs3dmapsettings.cpp.

◆ extentChanged

void Qgs3DMapSettings::extentChanged ( )
signal

Emitted when the 3d view's 2d extent has changed.

See also
setExtent()
Since
QGIS 3.30

◆ eyeDomeLightingDistance()

int Qgs3DMapSettings::eyeDomeLightingDistance ( ) const

Returns the eye dome lighting distance value (contributes to the contrast of the image)

Definition at line 1044 of file qgs3dmapsettings.cpp.

◆ eyeDomeLightingDistanceChanged

void Qgs3DMapSettings::eyeDomeLightingDistanceChanged ( )
signal

Emitted when the eye dome lighting distance has changed.

Since
QGIS 3.18

◆ eyeDomeLightingEnabled()

bool Qgs3DMapSettings::eyeDomeLightingEnabled ( ) const

Returns whether eye dome lighting is used.

Definition at line 1010 of file qgs3dmapsettings.cpp.

◆ eyeDomeLightingEnabledChanged

void Qgs3DMapSettings::eyeDomeLightingEnabledChanged ( )
signal

Emitted when the flag whether eye dome lighting is used has changed.

Since
QGIS 3.18

◆ eyeDomeLightingStrength()

double Qgs3DMapSettings::eyeDomeLightingStrength ( ) const

Returns the eye dome lighting strength value.

Definition at line 1027 of file qgs3dmapsettings.cpp.

◆ eyeDomeLightingStrengthChanged

void Qgs3DMapSettings::eyeDomeLightingStrengthChanged ( )
signal

Emitted when the eye dome lighting strength has changed.

Since
QGIS 3.18

◆ fieldOfView()

float Qgs3DMapSettings::fieldOfView ( ) const

Returns the camera lens' field of view.

Since
QGIS 3.8

Definition at line 1100 of file qgs3dmapsettings.cpp.

◆ fieldOfViewChanged

void Qgs3DMapSettings::fieldOfViewChanged ( )
signal

Emitted when the camera lens field of view changes.

Since
QGIS 3.8

◆ fpsCounterEnabledChanged

void Qgs3DMapSettings::fpsCounterEnabledChanged ( bool  fpsCounterEnabled)
signal

Emitted when the FPS counter is enabled or disabled.

Since
QGIS 3.18

◆ get3DAxisSettings()

Qgs3DAxisSettings Qgs3DMapSettings::get3DAxisSettings ( ) const

Returns the current configuration of 3d axis.

Returns
QGIS 3.26

Definition at line 1405 of file qgs3dmapsettings.cpp.

◆ isDebugOverlayEnabled()

bool Qgs3DMapSettings::isDebugOverlayEnabled ( ) const

Returns whether debug overlay is enabled.

See also
setIsDebugOverlayEnabled()
Since
QGIS 3.26

Definition at line 1489 of file qgs3dmapsettings.cpp.

◆ isFpsCounterEnabled()

bool Qgs3DMapSettings::isFpsCounterEnabled ( ) const

Returns whether FPS counter label is enabled.

See also
setIsFpsCounterEnabled()
Since
QGIS 3.18

Definition at line 1245 of file qgs3dmapsettings.cpp.

◆ isSkyboxEnabled()

bool Qgs3DMapSettings::isSkyboxEnabled ( ) const

Returns whether the skybox is enabled.

See also
setIsSkyboxEnabled()
Since
QGIS 3.16

Definition at line 1231 of file qgs3dmapsettings.cpp.

◆ isTerrainShadingEnabled()

bool Qgs3DMapSettings::isTerrainShadingEnabled ( ) const

Returns whether terrain shading is enabled.

When enabled, in addition to the terrain texture generated from the map, the terrain rendering will take into account position of the lights, terrain normals and terrain shading material (ambient and specular colors, shininess).

Since
QGIS 3.6

Definition at line 830 of file qgs3dmapsettings.cpp.

◆ layers()

QList< QgsMapLayer * > Qgs3DMapSettings::layers ( ) const

Returns the list of 3D map layers to be rendered in the scene.

This setting dictates which layers are to be rendered using their 3D rendering configuration, if available.

See also
setLayers()
layersChanged()

Definition at line 637 of file qgs3dmapsettings.cpp.

◆ layersChanged

void Qgs3DMapSettings::layersChanged ( )
signal

Emitted when the list of map layers for 3d rendering has changed.

See also
setLayers()
layers()

◆ lightSources()

QList< QgsLightSource * > Qgs3DMapSettings::lightSources ( ) const

Returns list of directional light sources defined in the scene.

See also
setLightSources()
Since
QGIS 3.26

Definition at line 1051 of file qgs3dmapsettings.cpp.

◆ lightSourcesChanged

void Qgs3DMapSettings::lightSourcesChanged ( )
signal

Emitted when any of the light source settings in the map changes.

Since
QGIS 3.26

◆ mapThemeCollection()

QgsMapThemeCollection * Qgs3DMapSettings::mapThemeCollection ( ) const

Returns pointer to the collection of map themes.

Normally this would be QgsProject::mapThemeCollection() of the currently used project. Without a valid map theme collection object it is not possible to resolve map themes from their names.

Since
QGIS 3.6

Definition at line 553 of file qgs3dmapsettings.cpp.

◆ mapTileResolution()

int Qgs3DMapSettings::mapTileResolution ( ) const

Returns resolution (in pixels) of the texture of a terrain tile.

This parameter influences how many zoom levels for terrain tiles there will be (together with maxTerrainGroundError())

Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 722 of file qgs3dmapsettings.cpp.

◆ mapTileResolutionChanged

Q_DECL_DEPRECATED void Qgs3DMapSettings::mapTileResolutionChanged ( )
signal

Emitted when the map tile resoulution has changed.

Deprecated:
QGIS 3.42. Use terrainSettingsChanged() instead.

◆ mapToWorldCoordinates()

QgsVector3D Qgs3DMapSettings::mapToWorldCoordinates ( const QgsVector3D mapCoords) const

Converts map coordinates to 3D world coordinates (applies offset and turns (x,y,z) into (x,-z,y))

Definition at line 497 of file qgs3dmapsettings.cpp.

◆ maxTerrainGroundError()

double Qgs3DMapSettings::maxTerrainGroundError ( ) const

Returns maximum ground error of terrain tiles in world units.

This parameter influences how many zoom levels there will be (together with mapTileResolution()). This value tells that when the given ground error is reached (e.g. 10 meters), it makes no sense to further split terrain tiles into finer ones because they will not add extra details anymore.

Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 785 of file qgs3dmapsettings.cpp.

◆ maxTerrainGroundErrorChanged

Q_DECL_DEPRECATED void Qgs3DMapSettings::maxTerrainGroundErrorChanged ( )
signal

Emitted when the maximum terrain ground error has changed.

Deprecated:
QGIS 3.42. Use terrainSettingsChanged() instead.

◆ maxTerrainScreenError()

double Qgs3DMapSettings::maxTerrainScreenError ( ) const

Returns maximum allowed screen error of terrain tiles in pixels.

This parameter decides how aggressively less detailed terrain tiles are swapped to more detailed ones as camera gets closer. Each tile has its error defined in world units - this error gets projected to screen pixels according to camera view and if the tile's error is greater than the allowed error, it will be swapped by more detailed tiles with lower error.

Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 743 of file qgs3dmapsettings.cpp.

◆ maxTerrainScreenErrorChanged

Q_DECL_DEPRECATED void Qgs3DMapSettings::maxTerrainScreenErrorChanged ( )
signal

Emitted when the maximum terrain screen error has changed.

Deprecated:
QGIS 3.42. Use terrainSettingsChanged() instead.

◆ operator=()

Qgs3DMapSettings & Qgs3DMapSettings::operator= ( Qgs3DMapSettings const &  )
delete

◆ origin()

QgsVector3D Qgs3DMapSettings::origin ( ) const

Returns coordinates in map CRS at which 3D scene has origin (0,0,0).

See also
setOrigin()

Definition at line 490 of file qgs3dmapsettings.cpp.

◆ originChanged

void Qgs3DMapSettings::originChanged ( )
signal

Emitted when the world's origin point has been shifted.

See also
setOrigin()
Since
QGIS 3.42

◆ outputDpi()

double Qgs3DMapSettings::outputDpi ( ) const

Returns DPI used for conversion between real world units (e.g.

mm) and pixels Default value is 96

Since
QGIS 3.10

Definition at line 1179 of file qgs3dmapsettings.cpp.

◆ pathResolver()

const QgsPathResolver & Qgs3DMapSettings::pathResolver ( ) const

Returns the path resolver for conversion between relative and absolute paths during rendering operations, e.g.

for resolving relative symbol paths.

See also
setPathResolver()

Definition at line 539 of file qgs3dmapsettings.cpp.

◆ pointLightsChanged

void Qgs3DMapSettings::pointLightsChanged ( )
signal

Emitted when the list of point lights changes.

Since
QGIS 3.6

◆ projectionType()

Qt3DRender::QCameraLens::ProjectionType Qgs3DMapSettings::projectionType ( ) const

Returns the camera lens' projection type.

Since
QGIS 3.18

Definition at line 1118 of file qgs3dmapsettings.cpp.

◆ projectionTypeChanged

void Qgs3DMapSettings::projectionTypeChanged ( )
signal

Emitted when the camera lens projection type changes.

Since
QGIS 3.18

◆ readXml()

void Qgs3DMapSettings::readXml ( const QDomElement &  elem,
const QgsReadWriteContext context 
)

Reads configuration from a DOM element previously written by writeXml()

Definition at line 119 of file qgs3dmapsettings.cpp.

◆ renderersChanged

void Qgs3DMapSettings::renderersChanged ( )
signal

Emitted when the list of map's extra renderers have been modified.

Since
QGIS 3.10

◆ rendererUsage()

Qgis::RendererUsage Qgs3DMapSettings::rendererUsage ( ) const

Returns the renderer usage.

See also
rendererUsage()
Since
QGIS 3.24

Definition at line 1359 of file qgs3dmapsettings.cpp.

◆ resolveReferences()

void Qgs3DMapSettings::resolveReferences ( const QgsProject project)

Resolves references to other objects (map layers) after the call to readXml()

Definition at line 431 of file qgs3dmapsettings.cpp.

◆ selectionColor()

QColor Qgs3DMapSettings::selectionColor ( ) const

Returns color used for selected features.

Definition at line 596 of file qgs3dmapsettings.cpp.

◆ selectionColorChanged

void Qgs3DMapSettings::selectionColorChanged ( )
signal

Emitted when the selection color has changed.

◆ set3DAxisSettings()

void Qgs3DMapSettings::set3DAxisSettings ( const Qgs3DAxisSettings axisSettings,
bool  force = false 
)

Sets the current configuration of 3d axis.

Since
QGIS 3.26

Definition at line 1468 of file qgs3dmapsettings.cpp.

◆ setAmbientOcclusionSettings()

void Qgs3DMapSettings::setAmbientOcclusionSettings ( const QgsAmbientOcclusionSettings ambientOcclusionSettings)

Sets the current configuration of screen space ambient occlusion.

Since
QGIS 3.28

Definition at line 1223 of file qgs3dmapsettings.cpp.

◆ setBackgroundColor()

void Qgs3DMapSettings::setBackgroundColor ( const QColor &  color)

Sets background color of the 3D map view.

Definition at line 567 of file qgs3dmapsettings.cpp.

◆ setCameraMovementSpeed()

void Qgs3DMapSettings::setCameraMovementSpeed ( double  movementSpeed)

Sets the camera movement speed.

Since
QGIS 3.18

Definition at line 1161 of file qgs3dmapsettings.cpp.

◆ setCameraNavigationMode()

void Qgs3DMapSettings::setCameraNavigationMode ( Qgis::NavigationMode  navigationMode)

Sets the navigation mode for the camera.

Since
QGIS 3.18

Definition at line 1143 of file qgs3dmapsettings.cpp.

◆ setCrs()

void Qgs3DMapSettings::setCrs ( const QgsCoordinateReferenceSystem crs)

Sets coordinate reference system used in the 3D scene.

See also
crs()

Definition at line 511 of file qgs3dmapsettings.cpp.

◆ setDebugDepthMapSettings()

void Qgs3DMapSettings::setDebugDepthMapSettings ( bool  enabled,
Qt::Corner  corner,
double  size 
)

Sets the debugging settings of the depth map.

See also
debugDepthMapEnabled()
debugDepthMapCorner()
debugDepthMapSize()
Since
QGIS 3.18

Definition at line 1301 of file qgs3dmapsettings.cpp.

◆ setDebugShadowMapSettings()

void Qgs3DMapSettings::setDebugShadowMapSettings ( bool  enabled,
Qt::Corner  corner,
double  size 
)

Sets the debugging settings of the shadow map.

See also
debugShadowMapEnabled()
debugShadowMapCorner()
debugShadowMapSize()
Since
QGIS 3.18

Definition at line 1270 of file qgs3dmapsettings.cpp.

◆ setExtent()

void Qgs3DMapSettings::setExtent ( const QgsRectangle extent)

Sets the 3D scene's 2D extent in the 3D scene's CRS, while also setting the scene's origin to the extent's center This needs to be called during initialization, as terrain will only be generated within this extent and layer 3D data will only be loaded within this extent too.

See also
setOrigin()
setCrs()
Since
QGIS 3.30

Definition at line 461 of file qgs3dmapsettings.cpp.

◆ setEyeDomeLightingDistance()

void Qgs3DMapSettings::setEyeDomeLightingDistance ( int  distance)

Sets the eye dome lighting distance value (contributes to the contrast of the image.

See also
eyeDomeLightingDistance()
Since
QGIS 3.18

Definition at line 1034 of file qgs3dmapsettings.cpp.

◆ setEyeDomeLightingEnabled()

void Qgs3DMapSettings::setEyeDomeLightingEnabled ( bool  enabled)

Sets whether eye dome lighting will be used.

See also
eyeDomeLightingEnabled()
Since
QGIS 3.18

Definition at line 1000 of file qgs3dmapsettings.cpp.

◆ setEyeDomeLightingStrength()

void Qgs3DMapSettings::setEyeDomeLightingStrength ( double  strength)

Sets the eye dome lighting strength value.

See also
eyeDomeLightingStrength()
Since
QGIS 3.18

Definition at line 1017 of file qgs3dmapsettings.cpp.

◆ setFieldOfView()

void Qgs3DMapSettings::setFieldOfView ( const float  fieldOfView)

Sets the camera lens' field of view.

Since
QGIS 3.8

Definition at line 1107 of file qgs3dmapsettings.cpp.

◆ setIsDebugOverlayEnabled()

void Qgs3DMapSettings::setIsDebugOverlayEnabled ( bool  debugOverlayEnabled)

Sets whether debug overlay is enabled The debug overlay displays some debugging and profiling information.

It has been introduced in Qt version 5.15. This parameter is transient. It is not saved in the project parameters.

See also
isDebugOverlayEnabled()
Since
QGIS 3.26

Definition at line 1412 of file qgs3dmapsettings.cpp.

◆ setIsFpsCounterEnabled()

void Qgs3DMapSettings::setIsFpsCounterEnabled ( bool  fpsCounterEnabled)

Sets whether FPS counter label is enabled.

See also
isFpsCounterEnabled()
Since
QGIS 3.18

Definition at line 1332 of file qgs3dmapsettings.cpp.

◆ setIsSkyboxEnabled()

void Qgs3DMapSettings::setIsSkyboxEnabled ( bool  enabled)

Sets whether the skybox is enabled.

See also
isSkyboxEnabled()
Since
QGIS 3.16

Definition at line 1238 of file qgs3dmapsettings.cpp.

◆ setLayers()

void Qgs3DMapSettings::setLayers ( const QList< QgsMapLayer * > &  layers)

Sets the list of 3D map layers to be rendered in the scene.

This setting dictates which layers are to be rendered using their 3D rendering configuration, if available.

See also
layers()
layersChanged()

Definition at line 624 of file qgs3dmapsettings.cpp.

◆ setLightSources()

void Qgs3DMapSettings::setLightSources ( const QList< QgsLightSource * > &  lights)

Sets the list of light sources defined in the scene.

Ownership of the lights is transferred to the settings.

See also
lightSources()
Since
QGIS 3.26

Definition at line 1058 of file qgs3dmapsettings.cpp.

◆ setMapThemeCollection()

void Qgs3DMapSettings::setMapThemeCollection ( QgsMapThemeCollection mapThemes)

Sets pointer to the collection of map themes.

See also
mapThemeCollection()
Since
QGIS 3.6

Definition at line 560 of file qgs3dmapsettings.cpp.

◆ setMapTileResolution()

void Qgs3DMapSettings::setMapTileResolution ( int  res)

Sets resolution (in pixels) of the texture of a terrain tile.

See also
mapTileResolution()
Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 708 of file qgs3dmapsettings.cpp.

◆ setMaxTerrainGroundError()

void Qgs3DMapSettings::setMaxTerrainGroundError ( double  error)

Sets the maximum ground error of terrain tiles in world units.

See also
maxTerrainGroundError()
Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 750 of file qgs3dmapsettings.cpp.

◆ setMaxTerrainScreenError()

void Qgs3DMapSettings::setMaxTerrainScreenError ( double  error)

Sets maximum allowed screen error of terrain tiles in pixels.

See also
maxTerrainScreenError()
Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 729 of file qgs3dmapsettings.cpp.

◆ setOrigin()

void Qgs3DMapSettings::setOrigin ( const QgsVector3D origin)

Sets coordinates in map CRS at which our 3D world has origin (0,0,0)

We move the 3D world origin to the center of the extent of our terrain: this is done to minimize the impact of numerical errors when operating with 32-bit floats. Unfortunately this is not enough when working with a large area (still results in jitter with scenes spanning hundreds of kilometers and zooming in a lot).

Need to look into more advanced techniques like "relative to center" or "relative to eye" to improve the precision.

See also
origin()

Definition at line 479 of file qgs3dmapsettings.cpp.

◆ setOutputDpi()

void Qgs3DMapSettings::setOutputDpi ( const double  dpi)

Sets DPI used for conversion between real world units (e.g.

mm) and pixels

Parameters
dpithe number of dot per inch
Since
QGIS 3.10

Definition at line 1172 of file qgs3dmapsettings.cpp.

◆ setPathResolver()

void Qgs3DMapSettings::setPathResolver ( const QgsPathResolver resolver)

Sets the path resolver for conversion between relative and absolute paths during rendering operations, e.g.

for resolving relative symbol paths.

See also
pathResolver()

Definition at line 546 of file qgs3dmapsettings.cpp.

◆ setProjectionType()

void Qgs3DMapSettings::setProjectionType ( const Qt3DRender::QCameraLens::ProjectionType  projectionType)

Sets the camera lens' projection type.

Since
QGIS 3.18

Definition at line 1125 of file qgs3dmapsettings.cpp.

◆ setRendererUsage()

void Qgs3DMapSettings::setRendererUsage ( Qgis::RendererUsage  rendererUsage)

Sets the renderer usage.

See also
rendererUsage()
Since
QGIS 3.24

Definition at line 1366 of file qgs3dmapsettings.cpp.

◆ setSelectionColor()

void Qgs3DMapSettings::setSelectionColor ( const QColor &  color)

Sets color used for selected features.

Definition at line 585 of file qgs3dmapsettings.cpp.

◆ setShadowSettings()

void Qgs3DMapSettings::setShadowSettings ( const QgsShadowSettings shadowSettings)

Sets the current configuration of shadow rendering.

Since
QGIS 3.16

Definition at line 1215 of file qgs3dmapsettings.cpp.

◆ setShowCameraRotationCenter()

void Qgs3DMapSettings::setShowCameraRotationCenter ( bool  enabled)

Sets whether to show camera's rotation center as a sphere (for debugging)

Since
QGIS 3.24

Definition at line 928 of file qgs3dmapsettings.cpp.

◆ setShowCameraViewCenter()

void Qgs3DMapSettings::setShowCameraViewCenter ( bool  enabled)

Sets whether to show camera's view center as a sphere (for debugging)

Since
QGIS 3.4

Definition at line 910 of file qgs3dmapsettings.cpp.

◆ setShowDebugPanel()

void Qgs3DMapSettings::setShowDebugPanel ( bool  enabled)

Sets whether the debug side panel is shown.

Since
QGIS 3.42

Definition at line 1252 of file qgs3dmapsettings.cpp.

◆ setShowExtentIn2DView()

void Qgs3DMapSettings::setShowExtentIn2DView ( bool  show)

Sets whether the extent is displayed on the main 2D map canvas.

Since
QGIS 3.32

Definition at line 1496 of file qgs3dmapsettings.cpp.

◆ setShowLabels()

void Qgs3DMapSettings::setShowLabels ( bool  enabled)

Sets whether to display labels on terrain tiles.

Definition at line 964 of file qgs3dmapsettings.cpp.

◆ setShowLightSourceOrigins()

void Qgs3DMapSettings::setShowLightSourceOrigins ( bool  enabled)

Sets whether to show light source origins as a sphere (for debugging)

Since
QGIS 3.16

Definition at line 946 of file qgs3dmapsettings.cpp.

◆ setShowTerrainBoundingBoxes()

void Qgs3DMapSettings::setShowTerrainBoundingBoxes ( bool  enabled)

Sets whether to display bounding boxes of terrain tiles (for debugging)

Definition at line 873 of file qgs3dmapsettings.cpp.

◆ setShowTerrainTilesInfo()

void Qgs3DMapSettings::setShowTerrainTilesInfo ( bool  enabled)

Sets whether to display extra tile info on top of terrain tiles (for debugging)

Definition at line 892 of file qgs3dmapsettings.cpp.

◆ setSkyboxSettings()

void Qgs3DMapSettings::setSkyboxSettings ( const QgsSkyboxSettings skyboxSettings)

Sets the current configuration of the skybox.

Since
QGIS 3.16

Definition at line 1207 of file qgs3dmapsettings.cpp.

◆ setStopUpdates()

void Qgs3DMapSettings::setStopUpdates ( bool  enabled)

Sets whether scene updates on camera movement should be enabled.

Note
By default, scene is updating on camera movement. Useful for debugging purposes.
Since
QGIS 3.42

Definition at line 982 of file qgs3dmapsettings.cpp.

◆ setTerrainElevationOffset()

void Qgs3DMapSettings::setTerrainElevationOffset ( double  offset)

Sets the terrain elevation offset (used to move the terrain up or down)

See also
terrainElevationOffset()
Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 765 of file qgs3dmapsettings.cpp.

◆ setTerrainGenerator()

void Qgs3DMapSettings::setTerrainGenerator ( QgsTerrainGenerator gen)

Sets terrain generator and sets extent() as the generator's extent.

It takes care of producing terrain tiles from the input data. Takes ownership of the generator.

Note
Terrain generation will only occur if terrainRenderingEnabled() is true.
See also
terrainGenerator()
setTerrainRenderingEnabled()
setExtent()

Definition at line 792 of file qgs3dmapsettings.cpp.

◆ setTerrainMapTheme()

void Qgs3DMapSettings::setTerrainMapTheme ( const QString &  theme)

Sets name of the map theme.

See also
terrainMapTheme()
Since
QGIS 3.6

Definition at line 855 of file qgs3dmapsettings.cpp.

◆ setTerrainRenderingEnabled()

void Qgs3DMapSettings::setTerrainRenderingEnabled ( bool  terrainRenderingEnabled)

Sets whether the 2D terrain surface will be rendered in.

See also
terrainRenderingEnabled()
Since
QGIS 3.22

Definition at line 1349 of file qgs3dmapsettings.cpp.

◆ setTerrainSettings()

void Qgs3DMapSettings::setTerrainSettings ( QgsAbstractTerrainSettings settings)

Sets the terrain settings.

See also
terrainSettings()
Since
QGIS 3.42

Definition at line 671 of file qgs3dmapsettings.cpp.

◆ setTerrainShadingEnabled()

void Qgs3DMapSettings::setTerrainShadingEnabled ( bool  enabled)

Sets whether terrain shading is enabled.

See also
isTerrainShadingEnabled()
Since
QGIS 3.6

Definition at line 819 of file qgs3dmapsettings.cpp.

◆ setTerrainShadingMaterial()

void Qgs3DMapSettings::setTerrainShadingMaterial ( const QgsPhongMaterialSettings material)

Sets terrain shading material.

See also
terrainShadingMaterial()
Since
QGIS 3.6

Definition at line 837 of file qgs3dmapsettings.cpp.

◆ setTerrainVerticalScale()

void Qgs3DMapSettings::setTerrainVerticalScale ( double  zScale)

Sets vertical scale (exaggeration) of terrain (1 = true scale, > 1 = hills get more pronounced)

Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 603 of file qgs3dmapsettings.cpp.

◆ settingsChanged

void Qgs3DMapSettings::settingsChanged ( )
signal

Emitted when one of the configuration settings has changed.

Since
QGIS 3.24

◆ setTransformContext()

void Qgs3DMapSettings::setTransformContext ( const QgsCoordinateTransformContext context)

Sets the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system.

See also
transformContext()

Definition at line 532 of file qgs3dmapsettings.cpp.

◆ setViewFrustumVisualizationEnabled()

void Qgs3DMapSettings::setViewFrustumVisualizationEnabled ( bool  enabled)

Sets whether the camera's view frustum is visualized on the 2D map canvas.

Since
QGIS 3.26

Definition at line 1394 of file qgs3dmapsettings.cpp.

◆ setViewSyncMode()

void Qgs3DMapSettings::setViewSyncMode ( Qgis::ViewSyncModeFlags  mode)

Sets the view sync mode (used to synchronize the 2D main map canvas and the 3D camera navigation)

Since
QGIS 3.26

Definition at line 1380 of file qgs3dmapsettings.cpp.

◆ shadowSettings()

QgsShadowSettings Qgs3DMapSettings::shadowSettings ( ) const

Returns the current configuration of shadows.

Returns
QGIS 3.16

Definition at line 1193 of file qgs3dmapsettings.cpp.

◆ shadowSettingsChanged

void Qgs3DMapSettings::shadowSettingsChanged ( )
signal

Emitted when shadow rendering settings are changed.

Since
QGIS 3.16

◆ showCameraRotationCenter()

bool Qgs3DMapSettings::showCameraRotationCenter ( ) const

Returns whether to show camera's rotation center as a sphere (for debugging)

Since
QGIS 3.24

Definition at line 939 of file qgs3dmapsettings.cpp.

◆ showCameraRotationCenterChanged

void Qgs3DMapSettings::showCameraRotationCenterChanged ( )
signal

Emitted when the flag whether camera's rotation center is shown has changed.

Since
QGIS 3.24

◆ showCameraViewCenter()

bool Qgs3DMapSettings::showCameraViewCenter ( ) const

Returns whether to show camera's view center as a sphere (for debugging)

Since
QGIS 3.4

Definition at line 921 of file qgs3dmapsettings.cpp.

◆ showCameraViewCenterChanged

void Qgs3DMapSettings::showCameraViewCenterChanged ( )
signal

Emitted when the flag whether camera's view center is shown has changed.

Since
QGIS 3.4

◆ showDebugPanel()

bool Qgs3DMapSettings::showDebugPanel ( ) const

Returns whether the debug side panel is shown.

Since
QGIS 3.42

Definition at line 1263 of file qgs3dmapsettings.cpp.

◆ showDebugPanelChanged

void Qgs3DMapSettings::showDebugPanelChanged ( bool  shown)
signal

Emitted when the Show debug panel checkbox changes value.

See also
setShowDebugPanel()
Since
QGIS 3.42

◆ showExtentIn2DView()

bool Qgs3DMapSettings::showExtentIn2DView ( ) const

Returns whether the extent is displayed on the main 2D map canvas.

See also
setShowExtentIn2DView()
Since
QGIS 3.32

Definition at line 1423 of file qgs3dmapsettings.cpp.

◆ showExtentIn2DViewChanged

void Qgs3DMapSettings::showExtentIn2DViewChanged ( )
signal

Emitted when the parameter to display 3d view's extent in the 2D canvas has changed.

See also
setShowExtentIn2DView()
Since
QGIS 3.32

◆ showLabels()

bool Qgs3DMapSettings::showLabels ( ) const

Returns whether to display labels on terrain tiles.

Definition at line 975 of file qgs3dmapsettings.cpp.

◆ showLabelsChanged

void Qgs3DMapSettings::showLabelsChanged ( )
signal

Emitted when the flag whether labels are displayed on terrain tiles has changed.

◆ showLightSourceOrigins()

bool Qgs3DMapSettings::showLightSourceOrigins ( ) const

Returns whether to show light source origins as a sphere (for debugging)

Since
QGIS 3.16

Definition at line 957 of file qgs3dmapsettings.cpp.

◆ showLightSourceOriginsChanged

void Qgs3DMapSettings::showLightSourceOriginsChanged ( )
signal

Emitted when the flag whether light source origins are shown has changed.

Since
QGIS 3.15

◆ showTerrainBoundingBoxes()

bool Qgs3DMapSettings::showTerrainBoundingBoxes ( ) const

Returns whether to display bounding boxes of terrain tiles (for debugging)

Definition at line 884 of file qgs3dmapsettings.cpp.

◆ showTerrainBoundingBoxesChanged

void Qgs3DMapSettings::showTerrainBoundingBoxesChanged ( )
signal

Emitted when the flag whether terrain's bounding boxes are shown has changed.

◆ showTerrainTilesInfo()

bool Qgs3DMapSettings::showTerrainTilesInfo ( ) const

Returns whether to display extra tile info on top of terrain tiles (for debugging)

Definition at line 903 of file qgs3dmapsettings.cpp.

◆ showTerrainTilesInfoChanged

void Qgs3DMapSettings::showTerrainTilesInfoChanged ( )
signal

Emitted when the flag whether terrain's tile info is shown has changed.

◆ skyboxSettings()

QgsSkyboxSettings Qgs3DMapSettings::skyboxSettings ( ) const

Returns the current configuration of the skybox.

Since
QGIS 3.16

Definition at line 1186 of file qgs3dmapsettings.cpp.

◆ skyboxSettingsChanged

void Qgs3DMapSettings::skyboxSettingsChanged ( )
signal

Emitted when skybox settings are changed.

Since
QGIS 3.16

◆ stopUpdates()

bool Qgs3DMapSettings::stopUpdates ( ) const

Returns whether the scene updates on camera movement.

Since
QGIS 3.42

Definition at line 993 of file qgs3dmapsettings.cpp.

◆ stopUpdatesChanged

void Qgs3DMapSettings::stopUpdatesChanged ( )
signal

Emitted when the flag whether to keep updating scene has changed.

Since
QGIS 3.42

◆ terrainElevationOffset()

double Qgs3DMapSettings::terrainElevationOffset ( ) const

Returns the elevation offset of the terrain (used to move the terrain up or down)

Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 778 of file qgs3dmapsettings.cpp.

◆ terrainElevationOffsetChanged

Q_DECL_DEPRECATED void Qgs3DMapSettings::terrainElevationOffsetChanged ( double  newElevation)
signal

Emitted when the terrain elevation offset is changed.

Deprecated:
QGIS 3.42. Use terrainSettingsChanged() instead.

◆ terrainGenerator()

QgsTerrainGenerator * Qgs3DMapSettings::terrainGenerator ( ) const

Returns the terrain generator.

It takes care of producing terrain tiles from the input data.

Note
Terrain generation will only occur if terrainRenderingEnabled() is true.
See also
setTerrainGenerator()
terrainRenderingEnabled()

Definition at line 812 of file qgs3dmapsettings.cpp.

◆ terrainGeneratorChanged

void Qgs3DMapSettings::terrainGeneratorChanged ( )
signal

Emitted when the terrain generator has changed.

◆ terrainMapTheme()

QString Qgs3DMapSettings::terrainMapTheme ( ) const

Returns name of the map theme (from the active project) that will be used for terrain's texture.

Empty map theme name means that the map theme is not overridden and the current map theme will be used.

Note
Support for map themes only works if mapThemeCollection() is a valid object (otherwise it is not possible to resolve map themes from names)
Since
QGIS 3.6

Definition at line 866 of file qgs3dmapsettings.cpp.

◆ terrainMapThemeChanged

void Qgs3DMapSettings::terrainMapThemeChanged ( )
signal

Emitted when terrain's map theme has changed.

Since
QGIS 3.6

◆ terrainRenderingEnabled()

bool Qgs3DMapSettings::terrainRenderingEnabled ( ) const

Returns whether the 2D terrain surface will be rendered.

See also
setTerrainRenderingEnabled()
Since
QGIS 3.22

Definition at line 1342 of file qgs3dmapsettings.cpp.

◆ terrainSettings()

const QgsAbstractTerrainSettings * Qgs3DMapSettings::terrainSettings ( ) const

Returns the terrain settings.

Warning
Modifications should never be made to the returned object. Instead use setTerrainSettings(), so that the corresponding changed signals are correctly emitted.
See also
setTerrainSettings()
Since
QGIS 3.42

Definition at line 664 of file qgs3dmapsettings.cpp.

◆ terrainSettingsChanged

void Qgs3DMapSettings::terrainSettingsChanged ( )
signal

Emitted when the terrain settings are changed.

Since
QGIS 3.42

◆ terrainShadingChanged

void Qgs3DMapSettings::terrainShadingChanged ( )
signal

Emitted when terrain shading enabled flag or terrain shading material has changed.

Since
QGIS 3.6

◆ terrainShadingMaterial()

QgsPhongMaterialSettings Qgs3DMapSettings::terrainShadingMaterial ( ) const

Returns terrain shading material.

Diffuse color component is ignored since the diffuse component is provided by 2D rendered map texture. Only used when isTerrainShadingEnabled() is true.

Since
QGIS 3.6

Definition at line 848 of file qgs3dmapsettings.cpp.

◆ terrainVerticalScale()

double Qgs3DMapSettings::terrainVerticalScale ( ) const

Returns vertical scale (exaggeration) of terrain.

Deprecated:
QGIS 3.42. Use terrainSettings() instead.

Definition at line 617 of file qgs3dmapsettings.cpp.

◆ terrainVerticalScaleChanged

Q_DECL_DEPRECATED void Qgs3DMapSettings::terrainVerticalScaleChanged ( )
signal

Emitted when the vertical scale of the terrain has changed.

Deprecated:
QGIS 3.42. Use terrainSettingsChanged() instead.

◆ transformContext()

QgsCoordinateTransformContext Qgs3DMapSettings::transformContext ( ) const

Returns the coordinate transform context, which stores various information regarding which datum transforms should be used when transforming points from a source to destination coordinate reference system.

See also
setTransformContext()

Definition at line 525 of file qgs3dmapsettings.cpp.

◆ viewFrustumVisualizationEnabled()

bool Qgs3DMapSettings::viewFrustumVisualizationEnabled ( ) const

Returns whether the camera's view frustum is visualized on the 2D map canvas.

Since
QGIS 3.26

Definition at line 1387 of file qgs3dmapsettings.cpp.

◆ viewFrustumVisualizationEnabledChanged

void Qgs3DMapSettings::viewFrustumVisualizationEnabledChanged ( )
signal

Emitted when the camera's view frustum visualization on the main 2D map canvas is enabled or disabled.

Since
QGIS 3.26

◆ viewSyncMode()

Qgis::ViewSyncModeFlags Qgs3DMapSettings::viewSyncMode ( ) const

Returns the view sync mode (used to synchronize the 2D main map canvas and the 3D camera navigation)

Since
QGIS 3.26

Definition at line 1373 of file qgs3dmapsettings.cpp.

◆ worldToMapCoordinates()

QgsVector3D Qgs3DMapSettings::worldToMapCoordinates ( const QgsVector3D worldCoords) const

Converts 3D world coordinates to map coordinates (applies offset and turns (x,y,z) into (x,-z,y))

Definition at line 504 of file qgs3dmapsettings.cpp.

◆ writeXml()

QDomElement Qgs3DMapSettings::writeXml ( QDomDocument &  doc,
const QgsReadWriteContext context 
) const

Writes configuration to a DOM element, to be used later with readXml()

Definition at line 297 of file qgs3dmapsettings.cpp.


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