mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#5914 Import faults : Avoid computation of faults if turned off in preferences
This commit is contained in:
parent
2bc9cb37c0
commit
0c32538e01
@ -609,11 +609,15 @@ void RimEclipseCase::computeCachedData()
|
||||
{
|
||||
auto task = pInf.task( "Calculating faults", 17 );
|
||||
|
||||
bool computeNncs = RiaApplication::instance()->preferences()->readerSettings()->importNNCs();
|
||||
bool computeFaults = RiaApplication::instance()->preferences()->readerSettings()->importFaults();
|
||||
if ( computeFaults )
|
||||
{
|
||||
bool computeNncs = RiaApplication::instance()->preferences()->readerSettings()->importNNCs();
|
||||
|
||||
rigEclipseCase->mainGrid()->calculateFaults( rigEclipseCase->activeCellInfo(
|
||||
RiaDefines::PorosityModelType::MATRIX_MODEL ),
|
||||
computeNncs );
|
||||
rigEclipseCase->mainGrid()->calculateFaults( rigEclipseCase->activeCellInfo(
|
||||
RiaDefines::PorosityModelType::MATRIX_MODEL ),
|
||||
computeNncs );
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
|
@ -132,11 +132,14 @@ RigMainGrid* RimEclipseCaseCollection::registerCaseInGridCollection( RigEclipseC
|
||||
// This is the first insertion of this grid, compute cached data
|
||||
rigEclipseCase->mainGrid()->computeCachedData();
|
||||
|
||||
bool computeNncs = RiaApplication::instance()->preferences()->readerSettings()->importNNCs();
|
||||
|
||||
rigEclipseCase->mainGrid()->calculateFaults( rigEclipseCase->activeCellInfo(
|
||||
RiaDefines::PorosityModelType::MATRIX_MODEL ),
|
||||
computeNncs );
|
||||
bool computeFaults = RiaApplication::instance()->preferences()->readerSettings()->importFaults();
|
||||
if ( computeFaults )
|
||||
{
|
||||
bool computeNncs = RiaApplication::instance()->preferences()->readerSettings()->importNNCs();
|
||||
rigEclipseCase->mainGrid()->calculateFaults( rigEclipseCase->activeCellInfo(
|
||||
RiaDefines::PorosityModelType::MATRIX_MODEL ),
|
||||
computeNncs );
|
||||
}
|
||||
|
||||
equalGrid = rigEclipseCase->mainGrid();
|
||||
}
|
||||
|
@ -569,6 +569,8 @@ void RigMainGrid::calculateFaults( const RigActiveCellInfo* activeCellInfo, bool
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RigMainGrid::distributeNNCsToFaults()
|
||||
{
|
||||
if ( m_faultsPrCellAcc.isNull() ) return;
|
||||
|
||||
const RigConnectionContainer& nncs = this->nncData()->connections();
|
||||
for ( size_t nncIdx = 0; nncIdx < nncs.size(); ++nncIdx )
|
||||
{
|
||||
@ -655,7 +657,7 @@ bool RigMainGrid::isFaceNormalsOutwards() const
|
||||
const RigFault* RigMainGrid::findFaultFromCellIndexAndCellFace( size_t reservoirCellIndex,
|
||||
cvf::StructGridInterface::FaceType face ) const
|
||||
{
|
||||
CVF_TIGHT_ASSERT( m_faultsPrCellAcc.notNull() );
|
||||
if ( m_faultsPrCellAcc.isNull() ) return nullptr;
|
||||
|
||||
if ( face == cvf::StructGridInterface::NO_FACE ) return nullptr;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user