Skip to content

Commit

Permalink
Revert geometry/rubberband item's buffer parameter change
Browse files Browse the repository at this point in the history
  • Loading branch information
nirvn committed Nov 2, 2023
1 parent f9a9dc4 commit 0362648
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/core/qgssggeometry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ QSGGeometry *QgsSGGeometry::qgsPolygonToQSGGeometry( const QgsPolygon *polygon,
Q_ASSERT( polygon );

QgsGeometry geom( polygon->clone() );
geom = geom.buffer( 0.0000001, 1, Qgis::EndCapStyle::Flat, Qgis::JoinStyle::Miter, 5 );
geom = geom.buffer( 0.0000001, 5 );
QgsPolygon *bufferedPolygon = qgsgeometry_cast<QgsPolygon *>( geom.constGet() );
QgsTessellator t( visibleExtent.xMinimum(), visibleExtent.yMaximum(), false, false, false, true );
if ( bufferedPolygon )
Expand Down
2 changes: 1 addition & 1 deletion src/core/sgrubberband.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ QSGGeometryNode *SGRubberband::createLineGeometry( const QVector<QgsPoint> &poin
QSGGeometryNode *SGRubberband::createPolygonGeometry( const QVector<QgsPoint> &points )
{
QgsGeometry geom( new QgsPolygon( new QgsLineString( points ) ) );
geom = geom.buffer( 0.0000001, 1, Qgis::EndCapStyle::Flat, Qgis::JoinStyle::Miter, 5 );
geom = geom.buffer( 0.0000001, 5 );
// QgsTesselator doesn't allow for coordinates distance smaller than 0.001
geom.removeDuplicateNodes( 0.001 );
QgsPolygon *polygon = qgsgeometry_cast<QgsPolygon *>( geom.constGet() );
Expand Down

1 comment on commit 0362648

@qfield-fairy
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.