#1544 Fracture : Add function used to compute perforation length coords

This commit is contained in:
Magne Sjaastad
2018-01-19 14:05:57 +01:00
parent c7d61ed7f4
commit 53418179ba
5 changed files with 51 additions and 0 deletions

View File

@@ -30,6 +30,7 @@
#include "RimSimWellInView.h"
#include "cafPdmUiDoubleSliderEditor.h"
#include "RigWellPath.h"
@@ -131,6 +132,29 @@ void RimSimWellFracture::loadDataAndUpdate()
updateAzimuthBasedOnWellAzimuthAngle();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::vector<cvf::Vec3d> RimSimWellFracture::perforationLengthCenterLineCoords() const
{
std::vector<cvf::Vec3d> coords;
if (!m_branchCenterLines.empty() && m_branchIndex < m_branchCenterLines.size())
{
RigWellPath wellPathGeometry;
wellPathGeometry.m_wellPathPoints = m_branchCenterLines[m_branchIndex].wellPathPoints();
wellPathGeometry.m_measuredDepths = m_branchCenterLines[m_branchIndex].measuredDepths();
double startMd = m_location - perforationLength() / 2.0;
double endMd = m_location + perforationLength() / 2.0;
coords = wellPathGeometry.clippedPointSubset(startMd, endMd).first;
}
return coords;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------