#1513 Fishbones : Add 'Fly to Object' for fishbones and perforations

This commit is contained in:
Magne Sjaastad
2017-05-21 09:15:54 +02:00
parent 4c19123b2d
commit 29bf25c56b
9 changed files with 242 additions and 3 deletions

View File

@@ -26,6 +26,7 @@
#include "cafPdmUiListEditor.h"
#include "cvfAssert.h"
#include "cvfBoundingBox.h"
#include <cstdlib>
@@ -51,7 +52,6 @@ namespace caf {
}
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
@@ -446,6 +446,29 @@ void RimFishbonesMultipleSubs::defineUiTreeOrdering(caf::PdmUiTreeOrdering& uiTr
m_name = QString("Fishbone %1").arg(index);
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
cvf::BoundingBox RimFishbonesMultipleSubs::boundingBoxInDomainCoords()
{
cvf::BoundingBox bb;
for (size_t i = 0; i < m_locationOfSubs().size(); i++)
{
for (size_t lateralIndex = 0; lateralIndex < m_lateralCountPerSub; lateralIndex++)
{
std::vector<cvf::Vec3d> coords = coordsForLateral(i, lateralIndex);
for (auto c : coords)
{
bb.add(c);
}
}
}
return bb;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------