Skip to content

Commit

Permalink
qgsframegraph: Give names to rubberband objects
Browse files Browse the repository at this point in the history
This makes it easier to debug the framegraph with the debug overlay.
  • Loading branch information
ptitjano authored and lbartoletti committed Jun 24, 2024
1 parent 17bd597 commit b362ee6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/3d/qgsframegraph.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -630,6 +630,8 @@ QgsFrameGraph::QgsFrameGraph( QSurface *surface, QSize s, Qt3DRender::QCamera *m
mTransparentObjectsPassLayer = new Qt3DRender::QLayer;
mRubberBandsLayer = new Qt3DRender::QLayer;

mRubberBandsLayer->setObjectName( "mRubberBandsLayer" );

mPreviewLayer->setRecursive( true );
mCastShadowsLayer->setRecursive( true );
mForwardRenderLayer->setRecursive( true );
Expand All @@ -654,6 +656,7 @@ QgsFrameGraph::QgsFrameGraph( QSurface *surface, QSize s, Qt3DRender::QCamera *m

// rubber bands (they should be always on top)
Qt3DRender::QFrameGraphNode *rubberBandsPass = constructRubberBandsPass();
rubberBandsPass->setObjectName( "rubberBandsPass" );
rubberBandsPass->setParent( mMainViewPort );

// shadow rendering pass
Expand All @@ -677,6 +680,7 @@ QgsFrameGraph::QgsFrameGraph( QSurface *surface, QSize s, Qt3DRender::QCamera *m
postprocessingPass->setObjectName( "PostProcessingPass" );

mRubberBandsRootEntity = new Qt3DCore::QEntity( mRootEntity );
mRubberBandsRootEntity->setObjectName( "mRubberBandsRootEntity" );
mRubberBandsRootEntity->addComponent( mRubberBandsLayer );

// textures preview pass
Expand Down

0 comments on commit b362ee6

Please sign in to comment.