Skip to content

Commit

Permalink
Add goupSize explanation
Browse files Browse the repository at this point in the history
  • Loading branch information
NEDJIMAbelgacem authored and wonder-sk committed Apr 8, 2021
1 parent a297d84 commit 93804a0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/core/pointcloud/qgspointcloudlayerrenderer.cpp
Expand Up @@ -239,6 +239,10 @@ int QgsPointCloudLayerRenderer::renderNodesAsync( const QVector<IndexedPointClou
QElapsedTimer downloadTimer;
downloadTimer.start();

// Instead of loading all point blocks in parallel and then rendering the one by one,
// we split the processing into groups of size groupSize where we load the blocks of the group
// in parallel and then render the group's blocks sequentially.
// This way helps QGIS stay responsive if the nodes vector size is big
const int groupSize = 4;
for ( int groupIndex = 0; groupIndex < nodes.size(); groupIndex += groupSize )
{
Expand Down

0 comments on commit 93804a0

Please sign in to comment.