mirror of
https://github.com/OPM/ResInsight.git
synced 2026-11-10 16:25:30 -06:00
Refactor: Change RigGridBase::cellCornerVertices to return std::array
Refactored RigGridBase::cellCornerVertices to return std::array<cvf::Vec3d, 8> by value instead of taking a reference to std::array as an output parameter. This change improves code readability and leverages modern C++ return value optimizations. Updated all call sites across the codebase to reflect the new function signature.
This commit is contained in:
1 parent
da69eef72b
commit
10182e99a7
41 files changed
+148
-214
No files matched your search
@@ -87,8 +87,7 @@ void RimFractureContainmentTools::appendNeighborCellForFace( const std::set<size
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
double computeAverageZForTwoDeepestZ( const RigMainGrid* mainGrid, size_t globalReservoirCellIndex, cvf::StructGridInterface::FaceType face )
|
||||
{
|
||||
std::array<cvf::Vec3d, 8> hexCorners;
|
||||
mainGrid->cellCornerVertices( globalReservoirCellIndex, hexCorners );
|
||||
std::array<cvf::Vec3d, 8> hexCorners = mainGrid->cellCornerVertices( globalReservoirCellIndex );
|
||||
|
||||
double avgZ = 0.0;
|
||||
|
||||
@@ -250,8 +249,7 @@ std::set<size_t> RimFractureContainmentTools::getCellsIntersectingFracturePlane(
|
||||
|
||||
for ( const auto& globalCellIndex : indicesToPotentiallyFracturedCells )
|
||||
{
|
||||
std::array<cvf::Vec3d, 8> hexCorners;
|
||||
mainGrid->cellCornerVertices( globalCellIndex, hexCorners );
|
||||
std::array<cvf::Vec3d, 8> hexCorners = mainGrid->cellCornerVertices( globalCellIndex );
|
||||
std::vector<std::vector<cvf::Vec3d>> planeCellPolygons;
|
||||
|
||||
bool isPlanIntersected =
|
||||
|
||||
Reference in new issue
Block a user