Skip to content
Permalink
Browse files

Fixes variables' names

  • Loading branch information
pblottiere committed Feb 16, 2018
1 parent d2ed783 commit 47ba3a026edac8f2b60ea07a9513dbc753c3f4f9
Showing with 8 additions and 9 deletions.
  1. +4 −4 src/app/qgsmaptoolcircle2tangentspoint.cpp
  2. +4 −5 src/core/geometry/qgsgeometryutils.cpp
@@ -175,16 +175,16 @@ void QgsMapToolCircle2TangentsPoint::getPossibleCenter( )
QgsPoint inter;
QgsGeometryUtils::segmentIntersection( QgsPoint( line1m.asPolyline().at( 0 ) ), QgsPoint( line1m.asPolyline().at( 1 ) ),
QgsPoint( line2m.asPolyline().at( 0 ) ), QgsPoint( line2m.asPolyline().at( 1 ) ), inter, isIntersect );
mCenters.append( QgsPointXY( inter ) );
mCenters.append( QgsPoint( inter ) );
QgsGeometryUtils::segmentIntersection( QgsPoint( line1m.asPolyline().at( 0 ) ), QgsPoint( line1m.asPolyline().at( 1 ) ),
QgsPoint( line2p.asPolyline().at( 0 ) ), QgsPoint( line2p.asPolyline().at( 1 ) ), inter, isIntersect );
mCenters.append( QgsPointXY( inter ) );
mCenters.append( QgsPoint( inter ) );
QgsGeometryUtils::segmentIntersection( QgsPoint( line1p.asPolyline().at( 0 ) ), QgsPoint( line1p.asPolyline().at( 1 ) ),
QgsPoint( line2m.asPolyline().at( 0 ) ), QgsPoint( line2m.asPolyline().at( 1 ) ), inter, isIntersect );
mCenters.append( QgsPointXY( inter ) );
mCenters.append( QgsPoint( inter ) );
QgsGeometryUtils::segmentIntersection( QgsPoint( line1p.asPolyline().at( 0 ) ), QgsPoint( line1p.asPolyline().at( 1 ) ),
QgsPoint( line2p.asPolyline().at( 0 ) ), QgsPoint( line2p.asPolyline().at( 1 ) ), inter, isIntersect );
mCenters.append( QgsPointXY( inter ) );
mCenters.append( QgsPoint( inter ) );
}
}

@@ -254,18 +254,17 @@ bool QgsGeometryUtils::lineIntersection( const QgsPoint &p1, QgsVector v1, const
{
z = p1.z();
}
else if ( q1.is3D() )
else if ( p2.is3D() )
{
z = q1.z();
z = p2.z();
}

if ( ! std::isnan( z ) )
{
inter.convertTo( QgsWkbTypes::addZ( inter.wkbType() ) );
inter.setZ( z );
intersection.convertTo( QgsWkbTypes::addZ( intersection.wkbType() ) );
intersection.setZ( z );
}


return true;
}

0 comments on commit 47ba3a0

Please sign in to comment.
You can’t perform that action at this time.