Skip to content

Commit

Permalink
Build fix
Browse files Browse the repository at this point in the history
  • Loading branch information
magnesj committed Jan 24, 2025
1 parent 4679471 commit 100be24
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions ApplicationLibCode/UserInterface/RiuCellSelectionTool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -170,8 +170,6 @@ RiuEclipseSelectionItem* RiuCellSelectionTool::createSelectionItemFromInput()
return nullptr;
}

cvf::Vec3d targetPoint = cvf::Vec3d( coords[0], coords[1], -coords[2] );

// Use the main grid to find the cell index. Look at close points 0.5 in length along all main axis if the target point is not in a
// cell
auto findCandidateCell = [&]( const cvf::Vec3d& source, double distance ) -> size_t
Expand All @@ -187,13 +185,11 @@ RiuEclipseSelectionItem* RiuCellSelectionTool::createSelectionItemFromInput()
// Check if the point is inside a cell
for ( const auto& p : points )
{
auto candidate = mainGrid->findReservoirCellIndexFromPoint( source );
auto candidate = mainGrid->findReservoirCellIndexFromPoint( p );
if ( candidate != cvf::UNDEFINED_SIZE_T ) return candidate;
}

// If the point is not inside a cell, check if it is close to a cell
size_t cellContainingPoint = cvf::UNDEFINED_SIZE_T;

cvf::BoundingBox pointBBox;
pointBBox.add( source );

Expand All @@ -206,6 +202,8 @@ RiuEclipseSelectionItem* RiuCellSelectionTool::createSelectionItemFromInput()
return cvf::UNDEFINED_SIZE_T;
};

m_cellEdit->clear();

double iSize, jSize, kSize;
mainGrid->characteristicCellSizes( &iSize, &jSize, &kSize );

Expand Down

0 comments on commit 100be24

Please sign in to comment.