#5925 Simplify computation of fault data

This commit is contained in:
Magne Sjaastad
2020-05-13 17:57:21 +02:00
parent 928acfdf9b
commit 73ac3e5db1
4 changed files with 33 additions and 30 deletions

View File

@@ -609,18 +609,7 @@ void RimEclipseCase::computeCachedData()
{
auto task = pInf.task( "Calculating faults", 17 );
bool computeFaults = RiaApplication::instance()->preferences()->readerSettings()->importFaults();
if ( computeFaults )
{
bool computeNncs = RiaApplication::instance()->preferences()->readerSettings()->importNNCs();
bool includeInactiveCells =
RiaApplication::instance()->preferences()->readerSettings()->includeInactiveCellsInFaultGeometry();
rigEclipseCase->mainGrid()->calculateFaults( rigEclipseCase->activeCellInfo(
RiaDefines::PorosityModelType::MATRIX_MODEL ),
computeNncs,
includeInactiveCells );
}
ensureFaultDataIsComputed();
}
{
@@ -701,6 +690,29 @@ void RimEclipseCase::loadAndSyncronizeInputProperties( bool includeGridFileName
RifEclipseInputPropertyLoader::loadAndSyncronizeInputProperties( inputPropertyCollection(), eclipseCaseData(), filenames );
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RimEclipseCase::ensureFaultDataIsComputed()
{
RigEclipseCaseData* rigEclipseCase = eclipseCaseData();
if ( rigEclipseCase )
{
bool computeFaults = RiaApplication::instance()->preferences()->readerSettings()->importFaults();
if ( computeFaults )
{
bool computeNncs = RiaApplication::instance()->preferences()->readerSettings()->importNNCs();
bool includeInactiveCells =
RiaApplication::instance()->preferences()->readerSettings()->includeInactiveCellsInFaultGeometry();
rigEclipseCase->mainGrid()->calculateFaults( rigEclipseCase->activeCellInfo(
RiaDefines::PorosityModelType::MATRIX_MODEL ),
computeNncs,
includeInactiveCells );
}
}
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------