#5458 New well path targets copy air gap from existing well path when picking

* If we're picking a point on an existing well path, copy the air gap.
This commit is contained in:
Gaute Lindkvist committed 2020-02-07 08:36:37 +01:00
1 parent 610a315e14
commit 33a319d504
1 file changed
+5 -1
@@ -106,13 +106,17 @@ bool RicCreateWellTargetsPickEventHandler::handle3dPickEvent( const Ric3dPickEve
{
targetPointInDomain = wellPathSourceInfo->closestPointOnCenterLine( firstPickItem.faceIdx(),
intersectionPointInDomain );
double md = wellPathSourceInfo->measuredDepth( firstPickItem.faceIdx(), intersectionPointInDomain );
doSetAzimuthAndInclination =
calculateAzimuthAndInclinationAtMd( md,
wellPathSourceInfo->wellPath()->wellPathGeometry(),
&azimuth,
&inclination );
double rkbDiff = wellPathSourceInfo->wellPath()->wellPathGeometry()->rkbDiff();
if ( m_geometryToAddTargetsTo->airGap() == 0.0 && rkbDiff != std::numeric_limits<double>::infinity() )
{
m_geometryToAddTargetsTo->setAirGap( rkbDiff );
}
}
else if ( isGridSourceObject( firstPickItem.sourceInfo() ) )
{