#1025 Added check for valid input for visibleCellsIntersetcsWell-function.

This commit is contained in:
astridkbjorke 2016-12-12 11:35:44 +01:00
parent 8e81c53520
commit 277cdf79b6

View File

@ -190,7 +190,6 @@ bool RimEclipseWell::calculateWellPipeVisibility(size_t frameIndex)
if (m_reservoirView->wellCollection()->wellPipeVisibility() == RimEclipseWellCollection::PIPES_OPEN_IN_VISIBLE_CELLS)
{
return visibleCellsInstersectsWell(frameIndex);
}
@ -204,7 +203,10 @@ bool RimEclipseWell::calculateWellPipeVisibility(size_t frameIndex)
//--------------------------------------------------------------------------------------------------
bool RimEclipseWell::visibleCellsInstersectsWell(size_t frameIndex)
{
//TODO: lag egen funksjon her:
if (this->wellResults() == nullptr) return false;
if (!wellResults()->hasWellResult(frameIndex)) return false;
const std::vector<RivCellSetEnum>& visGridParts = m_reservoirView->visibleGridParts();
cvf::cref<RivReservoirViewPartMgr> rvMan = m_reservoirView->reservoirGridPartManager();