Skip to content

Commit

Permalink
Cache geometries before rendering (curved geometries are going to be …
Browse files Browse the repository at this point in the history
…segmentized)
  • Loading branch information
mhugent committed Jul 13, 2015
1 parent 2dac139 commit 9f8aa84
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/core/qgsvectorlayerrenderer.cpp
Expand Up @@ -276,15 +276,15 @@ void QgsVectorLayerRenderer::drawRendererV2( QgsFeatureIterator& fit )
bool sel = mContext.showSelection() && mSelectedFeatureIds.contains( fet.id() );
bool drawMarker = ( mDrawVertexMarkers && mContext.drawEditingInformation() && ( !mVertexMarkerOnlyForSelection || sel ) );

// render feature
bool rendered = mRendererV2->renderFeature( fet, mContext, -1, sel, drawMarker );

if ( mCache )
{
// Cache this for the use of (e.g.) modifying the feature's uncommitted geometry.
mCache->cacheGeometry( fet.id(), *fet.constGeometry() );
}

// render feature
bool rendered = mRendererV2->renderFeature( fet, mContext, -1, sel, drawMarker );

// labeling - register feature
Q_UNUSED( rendered );
if ( rendered && mContext.labelingEngine() )
Expand Down

0 comments on commit 9f8aa84

Please sign in to comment.