mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Additional refactoring for POR-Bar result handling
* Always use element-nodal for POR calculations * Add RigFemAddressDefines Add special handling for "POR-Bar" result, always use element_nodal * 9362 Show unit text "sg" when normalized by hydrostatic pressure
This commit is contained in:
@@ -20,6 +20,7 @@
|
||||
#include "RivFemElmVisibilityCalculator.h"
|
||||
|
||||
#include "RigCaseToCaseCellMapper.h"
|
||||
#include "RigFemAddressDefines.h"
|
||||
#include "RigFemPart.h"
|
||||
#include "RigFemPartGrid.h"
|
||||
#include "RigFemPartResultsCollection.h"
|
||||
@@ -118,11 +119,7 @@ void RivFemElmVisibilityCalculator::computePropertyVisibility( cvf::UByteArray*
|
||||
|
||||
RigGeoMechCaseData* caseData = propFilterColl->reservoirView()->geoMechCase()->geoMechData();
|
||||
|
||||
RigFemResultAddress resVarAddress = propertyFilter->resultDefinition->resultAddress();
|
||||
|
||||
// Do a "Hack" to use elm nodal and not nodal POR results
|
||||
if ( resVarAddress.resultPosType == RIG_NODAL && resVarAddress.fieldName == "POR-Bar" )
|
||||
resVarAddress.resultPosType = RIG_ELEMENT_NODAL;
|
||||
RigFemResultAddress resVarAddress = RigFemAddressDefines::getResultLookupAddress( propertyFilter->resultDefinition->resultAddress() );
|
||||
|
||||
const std::vector<float>& resVals =
|
||||
caseData->femPartResults()->resultValues( resVarAddress, part->elementPartId(), timeStepIndex, frameIndex );
|
||||
|
||||
@@ -17,16 +17,13 @@
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <cstdlib>
|
||||
|
||||
#include "RivFemPartPartMgr.h"
|
||||
|
||||
#include "RivGeoMechPartMgr.h"
|
||||
|
||||
#include "RiaPreferences.h"
|
||||
|
||||
#include "RifGeoMechReaderInterface.h"
|
||||
|
||||
#include "RigFemAddressDefines.h"
|
||||
#include "RigFemPart.h"
|
||||
#include "RigFemPartResultsCollection.h"
|
||||
#include "RigFemScalarResultFrames.h"
|
||||
@@ -38,6 +35,7 @@
|
||||
#include "RimRegularLegendConfig.h"
|
||||
|
||||
#include "RivFemPickSourceInfo.h"
|
||||
#include "RivGeoMechPartMgr.h"
|
||||
#include "RivMeshLinesSourceInfo.h"
|
||||
#include "RivPartPriority.h"
|
||||
#include "RivResultToTextureMapper.h"
|
||||
@@ -61,6 +59,8 @@
|
||||
#include "cvfTransform.h"
|
||||
#include "cvfUniform.h"
|
||||
|
||||
#include <cstdlib>
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -286,13 +286,7 @@ void RivFemPartPartMgr::updateCellResultColor( int timeStepIndex, int frameIndex
|
||||
|
||||
if ( !caseData ) return;
|
||||
|
||||
RigFemResultAddress resVarAddress = cellResultColors->resultAddress();
|
||||
|
||||
// Do a "Hack" to show elm nodal and not nodal POR results
|
||||
if ( resVarAddress.resultPosType == RIG_NODAL && resVarAddress.fieldName == "POR-Bar" )
|
||||
{
|
||||
resVarAddress.resultPosType = RIG_ELEMENT_NODAL;
|
||||
}
|
||||
RigFemResultAddress resVarAddress = RigFemAddressDefines::getResultLookupAddress( cellResultColors->resultAddress() );
|
||||
|
||||
const std::vector<float>& resultValues =
|
||||
caseData->femPartResults()->resultValues( resVarAddress, m_partIdx, timeStepIndex, frameIndex );
|
||||
|
||||
Reference in New Issue
Block a user