Improve well path modeling

* Improve handling of MD at first target
* When sea level well target is disabled, update MD of first target
* Show well target spheres by default, allow toggling of spheres
* Activate well target modifiers when clicking on well targets
* Remove selection update causing an unstable 3D view
* Improve display and handling of multiple locations
* Add special 3D target for tie in well target
* Add slider to tie in MD input field
* Show MD in well path target table
* Delete all well path laterals when deleting a well path

* Python : Add lateral to parent well
* Python : Add perforation interval
This commit is contained in:
Magne Sjaastad
2021-08-13 16:48:33 +02:00
committed by GitHub
parent 40bd4c285a
commit 8dbb1d5ccd
50 changed files with 1377 additions and 310 deletions

View File

@@ -43,7 +43,7 @@ void caf::AppEnum<RimWellPathTarget::TargetTypeEnum>::setUp()
{
addItem( RimWellPathTarget::TargetTypeEnum::POINT_AND_TANGENT, "POINT_AND_TANGENT", "Point and Tangent" );
addItem( RimWellPathTarget::TargetTypeEnum::POINT, "POINT", "Point" );
setDefault( RimWellPathTarget::TargetTypeEnum::POINT_AND_TANGENT );
setDefault( RimWellPathTarget::TargetTypeEnum::POINT );
}
} // namespace caf
//--------------------------------------------------------------------------------------------------
@@ -51,7 +51,7 @@ void caf::AppEnum<RimWellPathTarget::TargetTypeEnum>::setUp()
//--------------------------------------------------------------------------------------------------
RimWellPathTarget::RimWellPathTarget()
: moved( this )
, m_targetType( TargetTypeEnum::POINT_AND_TANGENT )
, m_targetType( TargetTypeEnum::POINT )
, m_targetPointXYD( cvf::Vec3d::ZERO )
, m_azimuth( 0.0 )
, m_inclination( 0.0 )
@@ -69,10 +69,13 @@ RimWellPathTarget::RimWellPathTarget()
m_isLocked.uiCapability()->setUiHidden( true );
CAF_PDM_InitScriptableFieldNoDefault( &m_targetPointXYD, "TargetPoint", "Relative Coord", "", "", "" );
CAF_PDM_InitScriptableFieldNoDefault( &m_targetPointForDisplay, "TargetPointForDisplay", "UTM Coord", "", "", "" );
CAF_PDM_InitFieldNoDefault( &m_targetPointForDisplay, "TargetPointForDisplay", "UTM Coord", "", "", "" );
m_targetPointForDisplay.registerGetMethod( this, &RimWellPathTarget::targetPointForDisplayXYD );
m_targetPointForDisplay.registerSetMethod( this, &RimWellPathTarget::setTargetPointFromDisplayCoord );
CAF_PDM_InitScriptableFieldNoDefault( &m_targetMeasuredDepth, "TargetMeasuredDepth", "MD", "", "", "" );
m_targetMeasuredDepth.registerGetMethod( this, &RimWellPathTarget::measuredDepth );
CAF_PDM_InitScriptableField( &m_dogleg1, "Dogleg1", 3.0, "DL in", "", "[deg/30m]", "" );
CAF_PDM_InitScriptableField( &m_dogleg2, "Dogleg2", 3.0, "DL out", "", "[deg/30m]", "" );
@@ -224,10 +227,8 @@ double RimWellPathTarget::azimuth() const
{
return cvf::Math::toRadians( m_azimuth );
}
else
{
return std::numeric_limits<double>::infinity();
}
return std::numeric_limits<double>::infinity();
}
//--------------------------------------------------------------------------------------------------
@@ -239,10 +240,8 @@ double RimWellPathTarget::inclination() const
{
return cvf::Math::toRadians( m_inclination );
}
else
{
return std::numeric_limits<double>::infinity();
}
return std::numeric_limits<double>::infinity();
}
//--------------------------------------------------------------------------------------------------
@@ -441,6 +440,28 @@ void RimWellPathTarget::setTargetPointFromDisplayCoord( const cvf::Vec3d& coordI
m_targetPointXYD = newCoordInXYD;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
double RimWellPathTarget::measuredDepth() const
{
RimWellPath* wellPath = nullptr;
this->firstAncestorOfType( wellPath );
auto geoDef = geometryDefinition();
if ( geoDef && wellPath && wellPath->wellPathGeometry() )
{
auto offsetXYZ = geoDef->anchorPointXyz();
auto coordXYZ = targetPointXYZ() + offsetXYZ;
auto wellPathGeo = wellPath->wellPathGeometry();
return wellPathGeo->closestMeasuredDepth( coordXYZ );
}
return 0.0;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------