#1618 Showing well path direction in read only field. Also updating azimuth angle of wellpath / simwell to avoid negative angles and instead have angles 0-360deg.

This commit is contained in:
astridkbjorke 2017-06-26 15:09:33 +02:00
parent 2ed872e8fc
commit 2501264013
4 changed files with 16 additions and 0 deletions

View File

@ -100,6 +100,9 @@ RimFracture::RimFracture(void)
CAF_PDM_InitField(&stimPlanTimeIndexToPlot, "timeIndexToPlot", 0, "StimPlan Time Step", "", "", "");
//TODO:
CAF_PDM_InitField(&m_wellPathAzimuth, "WellPathAzimuth", 0.0, "Well Path Azimuth", "", "", "");
m_fracturePartMgr = new RivWellFracturePartMgr(this);
}
@ -348,6 +351,8 @@ QList<caf::PdmOptionItemInfo> RimFracture::calculateValueOptions(const caf::PdmF
//--------------------------------------------------------------------------------------------------
void RimFracture::defineUiOrdering(QString uiConfigName, caf::PdmUiOrdering& uiOrdering)
{
m_wellPathAzimuth.uiCapability()->setUiReadOnly(true);
if (m_fractureUnit() == RiaEclipseUnitTools::UNITS_METRIC)
{
wellDiameter.uiCapability()->setUiName("Well Diameter [m]");

View File

@ -111,6 +111,7 @@ protected:
caf::PdmPtrField<RimFractureTemplate*> m_fractureTemplate;
caf::PdmProxyValueField<cvf::Vec3d> m_uiAnchorPosition;
caf::PdmField< RiaEclipseUnitTools::UnitSystemType > m_fractureUnit;
caf::PdmField<double> m_wellPathAzimuth;
private:
caf::PdmField<cvf::Vec3d> m_anchorPosition;

View File

@ -111,6 +111,8 @@ double RimSimWellFracture::wellAzimuthAtFracturePosition()
{
updateBranchGeometry();
double simWellAzimuth = m_branchCenterLines[m_branchIndex].simWellAzimuthAngle(fracturePosition());
if (simWellAzimuth < 0) simWellAzimuth += 360;
return simWellAzimuth;
}
@ -178,6 +180,7 @@ void RimSimWellFracture::updateFracturePositionFromLocation()
this->firstAncestorOrThisOfType(proj);
if (proj) proj->createDisplayModelAndRedrawAllViews();
}
m_wellPathAzimuth = wellAzimuthAtFracturePosition();
}
//--------------------------------------------------------------------------------------------------
@ -194,6 +197,7 @@ void RimSimWellFracture::defineUiOrdering(QString uiConfigName, caf::PdmUiOrderi
locationGroup->add(&m_location);
locationGroup->add(&m_branchIndex);
locationGroup->add(&azimuth);
locationGroup->add(&m_wellPathAzimuth);
locationGroup->add(&dip);
locationGroup->add(&tilt);

View File

@ -129,6 +129,9 @@ double RimWellPathFracture::wellAzimuthAtFracturePosition()
RigWellPath* wellPathGeometry = wellPath->wellPathGeometry();
double wellPathAzimuth = wellPathGeometry->wellPathAzimuthAngle(fracturePosition());
if (wellPathAzimuth < 0) wellPathAzimuth += 360;
return wellPathAzimuth;
}
@ -150,6 +153,8 @@ void RimWellPathFracture::updatePositionFromMeasuredDepth()
positionAlongWellpath = wellPathGeometry->interpolatedPointAlongWellPath(m_measuredDepth());
this->setAnchorPosition(positionAlongWellpath);
m_wellPathAzimuth = wellAzimuthAtFracturePosition();
}
//--------------------------------------------------------------------------------------------------
@ -165,6 +170,7 @@ void RimWellPathFracture::defineUiOrdering(QString uiConfigName, caf::PdmUiOrder
caf::PdmUiGroup* locationGroup = uiOrdering.addNewGroup("Location / Orientation");
locationGroup->add(&m_measuredDepth);
locationGroup->add(&azimuth);
locationGroup->add(&m_wellPathAzimuth);
locationGroup->add(&dip);
locationGroup->add(&tilt);