mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Renamed variables according to newly renamed class names
"Result slot" -> "Result colors"
This commit is contained in:
parent
fa75a46ecb
commit
7315dd5318
@ -214,11 +214,11 @@ void RivFemPartPartMgr::updateCellColor(cvf::Color4f color)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivFemPartPartMgr::updateCellResultColor(size_t timeStepIndex, RimGeoMechCellColors* cellResultSlot)
|
||||
void RivFemPartPartMgr::updateCellResultColor(size_t timeStepIndex, RimGeoMechCellColors* cellResultColors)
|
||||
{
|
||||
CVF_ASSERT(cellResultSlot);
|
||||
CVF_ASSERT(cellResultColors);
|
||||
|
||||
// RigCaseData* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData();
|
||||
// RigCaseData* eclipseCase = cellResultColors->reservoirView()->eclipseCase()->reservoirData();
|
||||
|
||||
cvf::ref<cvf::Color3ubArray> surfaceFacesColorArray;
|
||||
|
||||
@ -226,24 +226,24 @@ void RivFemPartPartMgr::updateCellResultColor(size_t timeStepIndex, RimGeoMechCe
|
||||
if (m_surfaceFaces.notNull())
|
||||
{
|
||||
|
||||
const cvf::ScalarMapper* mapper = cellResultSlot->legendConfig()->scalarMapper();
|
||||
const cvf::ScalarMapper* mapper = cellResultColors->legendConfig()->scalarMapper();
|
||||
|
||||
RigGeoMechCaseData* caseData = cellResultSlot->ownerCaseData();
|
||||
RigGeoMechCaseData* caseData = cellResultColors->ownerCaseData();
|
||||
|
||||
if (!caseData) return;
|
||||
|
||||
RigFemResultAddress resVarAddress = cellResultSlot->resultAddress();
|
||||
RigFemResultAddress resVarAddress = cellResultColors->resultAddress();
|
||||
|
||||
const std::vector<float>& resultValues = caseData->femPartResults()->resultValues(resVarAddress, m_gridIdx, (int)timeStepIndex);
|
||||
|
||||
const std::vector<size_t>* vxToResultMapping = NULL;
|
||||
|
||||
if (cellResultSlot->resultPositionType() == RIG_NODAL)
|
||||
if (cellResultColors->resultPositionType() == RIG_NODAL)
|
||||
{
|
||||
vxToResultMapping = &(m_surfaceGenerator.quadVerticesToNodeIdxMapping());
|
||||
}
|
||||
else if ( cellResultSlot->resultPositionType() == RIG_ELEMENT_NODAL
|
||||
|| cellResultSlot->resultPositionType() == RIG_INTEGRATION_POINT)
|
||||
else if ( cellResultColors->resultPositionType() == RIG_ELEMENT_NODAL
|
||||
|| cellResultColors->resultPositionType() == RIG_INTEGRATION_POINT)
|
||||
{
|
||||
vxToResultMapping = &(m_surfaceGenerator.quadVerticesToGlobalElmNodeIdx());
|
||||
}
|
||||
@ -276,7 +276,7 @@ void RivFemPartPartMgr::updateCellResultColor(size_t timeStepIndex, RimGeoMechCe
|
||||
}
|
||||
}
|
||||
|
||||
RivScalarMapperUtils::applyTextureResultsToPart(m_surfaceFaces.p(), m_surfaceFacesTextureCoords.p(), mapper, m_opacityLevel, caf::FC_NONE, cellResultSlot->reservoirView()->isLightingDisabled());
|
||||
RivScalarMapperUtils::applyTextureResultsToPart(m_surfaceFaces.p(), m_surfaceFacesTextureCoords.p(), mapper, m_opacityLevel, caf::FC_NONE, cellResultColors->reservoirView()->isLightingDisabled());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -54,7 +54,7 @@ public:
|
||||
cvf::ref<cvf::UByteArray> cellVisibility() { return m_cellVisibility;}
|
||||
|
||||
void updateCellColor(cvf::Color4f color);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimGeoMechCellColors* cellResultSlot);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimGeoMechCellColors* cellResultColors);
|
||||
|
||||
void appendPartsToModel(cvf::ModelBasicList* model);
|
||||
|
||||
|
@ -106,11 +106,11 @@ void RivGeoMechPartMgr::updateCellColor(cvf::Color4f color)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivGeoMechPartMgr::updateCellResultColor(size_t timeStepIndex, RimGeoMechCellColors* cellResultSlot)
|
||||
void RivGeoMechPartMgr::updateCellResultColor(size_t timeStepIndex, RimGeoMechCellColors* cellResultColors)
|
||||
{
|
||||
for (size_t i = 0; i < m_femPartPartMgrs.size() ; ++i)
|
||||
{
|
||||
m_femPartPartMgrs[i]->updateCellResultColor(timeStepIndex, cellResultSlot);
|
||||
m_femPartPartMgrs[i]->updateCellResultColor(timeStepIndex, cellResultColors);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -56,7 +56,7 @@ public:
|
||||
cellVisibility(size_t partIndex);
|
||||
|
||||
void updateCellColor(cvf::Color4f color);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimGeoMechCellColors* cellResultSlot);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimGeoMechCellColors* cellResultColors);
|
||||
|
||||
void appendGridPartsToModel(cvf::ModelBasicList* model, const std::vector<size_t>& partIndices);
|
||||
void appendGridPartsToModel(cvf::ModelBasicList* model);
|
||||
|
@ -80,13 +80,13 @@ void RivGeoMechVizLogic::appendPartsToModel(int timeStepIndex, cvf::ModelBasicLi
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivGeoMechVizLogic::updateCellResultColor(int timeStepIndex, RimGeoMechCellColors* cellResultSlot)
|
||||
void RivGeoMechVizLogic::updateCellResultColor(int timeStepIndex, RimGeoMechCellColors* cellResultColors)
|
||||
{
|
||||
std::vector<RivGeoMechPartMgrCache::Key> visiblePartMgrs = keysToVisiblePartMgrs(timeStepIndex);
|
||||
for (size_t pmIdx = 0; pmIdx < visiblePartMgrs.size(); ++pmIdx)
|
||||
{
|
||||
RivGeoMechPartMgr* partMgr = m_partMgrCache->partMgr(visiblePartMgrs[pmIdx]);
|
||||
partMgr->updateCellResultColor(timeStepIndex, cellResultSlot);
|
||||
partMgr->updateCellResultColor(timeStepIndex, cellResultColors);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -44,7 +44,7 @@ public:
|
||||
|
||||
void appendNoAnimPartsToModel(cvf::ModelBasicList* model);
|
||||
void appendPartsToModel(int timeStepIndex, cvf::ModelBasicList* model);
|
||||
void updateCellResultColor(int timeStepIndex, RimGeoMechCellColors* cellResultSlot);
|
||||
void updateCellResultColor(int timeStepIndex, RimGeoMechCellColors* cellResultColors);
|
||||
void updateStaticCellColors(int timeStepIndex);
|
||||
void scheduleGeometryRegen(RivCellSetEnum geometryType);
|
||||
private:
|
||||
|
@ -43,20 +43,20 @@
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivCellEdgeGeometryUtils::addCellEdgeResultsToDrawableGeo(
|
||||
size_t timeStepIndex,
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors,
|
||||
const cvf::StructGridQuadToCellFaceMapper* quadToCellFaceMapper,
|
||||
cvf::DrawableGeo* geo,
|
||||
size_t gridIndex,
|
||||
float opacityLevel)
|
||||
{
|
||||
RigCaseData* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData();
|
||||
RigCaseData* eclipseCase = cellResultColors->reservoirView()->eclipseCase()->reservoirData();
|
||||
CVF_ASSERT(eclipseCase != NULL);
|
||||
|
||||
// Create result access objects
|
||||
|
||||
cvf::ref<RigResultAccessor> cellCenterDataAccessObject = createCellCenterResultAccessor(cellResultSlot, timeStepIndex, eclipseCase, eclipseCase->grid(gridIndex));
|
||||
cvf::ref<RigResultAccessor> cellEdgeResultAccessor = createCellEdgeCenterResultAccessor(cellResultSlot, cellEdgeResultSlot, timeStepIndex, eclipseCase, eclipseCase->grid(gridIndex));
|
||||
cvf::ref<RigResultAccessor> cellCenterDataAccessObject = createCellCenterResultAccessor(cellResultColors, timeStepIndex, eclipseCase, eclipseCase->grid(gridIndex));
|
||||
cvf::ref<RigResultAccessor> cellEdgeResultAccessor = createCellEdgeCenterResultAccessor(cellResultColors, cellEdgeResultColors, timeStepIndex, eclipseCase, eclipseCase->grid(gridIndex));
|
||||
|
||||
size_t vertexCount = geo->vertexArray()->size();
|
||||
size_t quadCount = vertexCount / 4;
|
||||
@ -80,17 +80,17 @@ void RivCellEdgeGeometryUtils::addCellEdgeResultsToDrawableGeo(
|
||||
cellEdgeColorTextureCoordsArrays.push_back(colorArray.p());
|
||||
}
|
||||
|
||||
cvf::ScalarMapper* cellResultScalarMapper = cellResultSlot->legendConfig()->scalarMapper();
|
||||
cvf::ScalarMapper* edgeResultScalarMapper = cellEdgeResultSlot->legendConfig()->scalarMapper();
|
||||
cvf::ScalarMapper* cellResultScalarMapper = cellResultColors->legendConfig()->scalarMapper();
|
||||
cvf::ScalarMapper* edgeResultScalarMapper = cellEdgeResultColors->legendConfig()->scalarMapper();
|
||||
|
||||
double ignoredScalarValue = cellEdgeResultSlot->ignoredScalarValue();
|
||||
double ignoredScalarValue = cellEdgeResultColors->ignoredScalarValue();
|
||||
|
||||
const std::vector<cvf::ubyte>* isWellPipeVisible = NULL;
|
||||
cvf::ref<cvf::UIntArray> gridCellToWellindexMap;
|
||||
|
||||
if (opacityLevel < 1.0f)
|
||||
{
|
||||
isWellPipeVisible = &(cellResultSlot->reservoirView()->wellCollection()->isWellPipesVisible(timeStepIndex));
|
||||
isWellPipeVisible = &(cellResultColors->reservoirView()->wellCollection()->isWellPipesVisible(timeStepIndex));
|
||||
gridCellToWellindexMap = eclipseCase->gridCellToWellIndex(gridIndex);
|
||||
}
|
||||
|
||||
@ -187,14 +187,14 @@ bool RivCellEdgeGeometryUtils::hideScalarValue(double scalarValue, double scalar
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivCellEdgeGeometryUtils::addTernaryCellEdgeResultsToDrawableGeo(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot,
|
||||
void RivCellEdgeGeometryUtils::addTernaryCellEdgeResultsToDrawableGeo(size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors,
|
||||
const cvf::StructGridQuadToCellFaceMapper* quadToCellFaceMapper,
|
||||
cvf::DrawableGeo* geo, size_t gridIndex, float opacityLevel)
|
||||
{
|
||||
RigCaseData* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData();
|
||||
RigCaseData* eclipseCase = cellResultColors->reservoirView()->eclipseCase()->reservoirData();
|
||||
CVF_ASSERT(eclipseCase != NULL);
|
||||
|
||||
cvf::ref<RigResultAccessor> cellEdgeResultAccessor = createCellEdgeCenterResultAccessor(cellResultSlot, cellEdgeResultSlot, timeStepIndex, eclipseCase, eclipseCase->grid(gridIndex));
|
||||
cvf::ref<RigResultAccessor> cellEdgeResultAccessor = createCellEdgeCenterResultAccessor(cellResultColors, cellEdgeResultColors, timeStepIndex, eclipseCase, eclipseCase->grid(gridIndex));
|
||||
|
||||
size_t vertexCount = geo->vertexArray()->size();
|
||||
size_t quadCount = vertexCount / 4;
|
||||
@ -218,12 +218,12 @@ void RivCellEdgeGeometryUtils::addTernaryCellEdgeResultsToDrawableGeo(size_t tim
|
||||
cellEdgeColorTextureCoordsArrays.push_back(colorArray.p());
|
||||
}
|
||||
|
||||
RivTernaryScalarMapper* ternaryCellResultScalarMapper = cellResultSlot->ternaryLegendConfig()->scalarMapper();
|
||||
cvf::ScalarMapper* edgeResultScalarMapper = cellEdgeResultSlot->legendConfig()->scalarMapper();
|
||||
RivTernaryScalarMapper* ternaryCellResultScalarMapper = cellResultColors->ternaryLegendConfig()->scalarMapper();
|
||||
cvf::ScalarMapper* edgeResultScalarMapper = cellEdgeResultColors->legendConfig()->scalarMapper();
|
||||
|
||||
double ignoredScalarValue = cellEdgeResultSlot->ignoredScalarValue();
|
||||
double ignoredScalarValue = cellEdgeResultColors->ignoredScalarValue();
|
||||
|
||||
RivTernaryTextureCoordsCreator texturer(cellResultSlot, cellResultSlot->ternaryLegendConfig(),
|
||||
RivTernaryTextureCoordsCreator texturer(cellResultColors, cellResultColors->ternaryLegendConfig(),
|
||||
timeStepIndex,
|
||||
gridIndex,
|
||||
quadToCellFaceMapper);
|
||||
@ -285,8 +285,8 @@ void RivCellEdgeGeometryUtils::addTernaryCellEdgeResultsToDrawableGeo(size_t tim
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
cvf::ref<RigResultAccessor> RivCellEdgeGeometryUtils::createCellEdgeCenterResultAccessor(
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors,
|
||||
size_t timeStepIndex,
|
||||
RigCaseData* eclipseCase,
|
||||
const RigGridBase* grid)
|
||||
@ -294,8 +294,8 @@ cvf::ref<RigResultAccessor> RivCellEdgeGeometryUtils::createCellEdgeCenterResult
|
||||
cvf::ref<RigCellEdgeResultAccessor> cellEdgeResultAccessor = new RigCellEdgeResultAccessor();
|
||||
{
|
||||
size_t resultIndices[6];
|
||||
cellEdgeResultSlot->gridScalarIndices(resultIndices);
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel());
|
||||
cellEdgeResultColors->gridScalarIndices(resultIndices);
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultColors->porosityModel());
|
||||
|
||||
size_t cubeFaceIdx;
|
||||
for (cubeFaceIdx = 0; cubeFaceIdx < 6; cubeFaceIdx++)
|
||||
@ -312,20 +312,20 @@ cvf::ref<RigResultAccessor> RivCellEdgeGeometryUtils::createCellEdgeCenterResult
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
cvf::ref<RigResultAccessor> RivCellEdgeGeometryUtils::createCellCenterResultAccessor(RimEclipseCellColors* cellResultSlot, size_t timeStepIndex, RigCaseData* eclipseCase, const RigGridBase* grid)
|
||||
cvf::ref<RigResultAccessor> RivCellEdgeGeometryUtils::createCellCenterResultAccessor(RimEclipseCellColors* cellResultColors, size_t timeStepIndex, RigCaseData* eclipseCase, const RigGridBase* grid)
|
||||
{
|
||||
cvf::ref<RigResultAccessor> resultAccessor = NULL;
|
||||
|
||||
if (cellResultSlot->hasResult())
|
||||
if (cellResultColors->hasResult())
|
||||
{
|
||||
if (!cellResultSlot->hasDynamicResult())
|
||||
if (!cellResultColors->hasDynamicResult())
|
||||
{
|
||||
// Static result values are located at time step 0
|
||||
timeStepIndex = 0;
|
||||
}
|
||||
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel());
|
||||
resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, grid->gridIndex(), porosityModel, timeStepIndex, cellResultSlot->resultVariable());
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultColors->porosityModel());
|
||||
resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, grid->gridIndex(), porosityModel, timeStepIndex, cellResultColors->resultVariable());
|
||||
}
|
||||
|
||||
if (resultAccessor.isNull())
|
||||
|
@ -39,16 +39,16 @@ class RivCellEdgeGeometryUtils
|
||||
{
|
||||
public:
|
||||
static void addCellEdgeResultsToDrawableGeo(size_t timeStepIndex,
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors,
|
||||
const cvf::StructGridQuadToCellFaceMapper* quadToCellFaceMapper,
|
||||
cvf::DrawableGeo* geo,
|
||||
size_t gridIndex,
|
||||
float opacityLevel);
|
||||
|
||||
static void addTernaryCellEdgeResultsToDrawableGeo(size_t timeStepIndex,
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors,
|
||||
const cvf::StructGridQuadToCellFaceMapper* quadToCellFaceMapper,
|
||||
cvf::DrawableGeo* geo,
|
||||
size_t gridIndex,
|
||||
@ -57,14 +57,14 @@ public:
|
||||
|
||||
private:
|
||||
static cvf::ref<RigResultAccessor> createCellCenterResultAccessor(
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
size_t timeStepIndex,
|
||||
RigCaseData* eclipseCase,
|
||||
const RigGridBase* grid);
|
||||
|
||||
static cvf::ref<RigResultAccessor> createCellEdgeCenterResultAccessor(
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors,
|
||||
size_t timeStepIndex,
|
||||
RigCaseData* eclipseCase,
|
||||
const RigGridBase* grid);
|
||||
|
@ -94,40 +94,40 @@ void RivFaultPartMgr::applySingleColorEffect()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivFaultPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot)
|
||||
void RivFaultPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors)
|
||||
{
|
||||
CVF_ASSERT(cellResultSlot);
|
||||
CVF_ASSERT(cellResultColors);
|
||||
|
||||
updateNNCColors(cellResultSlot);
|
||||
updateNNCColors(cellResultColors);
|
||||
|
||||
size_t scalarSetIndex = cellResultSlot->scalarResultIndex();
|
||||
size_t scalarSetIndex = cellResultColors->scalarResultIndex();
|
||||
|
||||
// If the result is static, only read that.
|
||||
size_t resTimeStepIdx = timeStepIndex;
|
||||
if (cellResultSlot->hasStaticResult()) resTimeStepIdx = 0;
|
||||
if (cellResultColors->hasStaticResult()) resTimeStepIdx = 0;
|
||||
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel());
|
||||
RimEclipseView* eclipseView = cellResultSlot->reservoirView();
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultColors->porosityModel());
|
||||
RimEclipseView* eclipseView = cellResultColors->reservoirView();
|
||||
RigCaseData* eclipseCase = eclipseView->eclipseCase()->reservoirData();
|
||||
|
||||
// Faults
|
||||
if (m_nativeFaultFaces.notNull())
|
||||
{
|
||||
if (cellResultSlot->isTernarySaturationSelected())
|
||||
if (cellResultColors->isTernarySaturationSelected())
|
||||
{
|
||||
RivTernaryTextureCoordsCreator texturer(cellResultSlot, cellResultSlot->ternaryLegendConfig(),
|
||||
RivTernaryTextureCoordsCreator texturer(cellResultColors, cellResultColors->ternaryLegendConfig(),
|
||||
timeStepIndex,
|
||||
m_grid->gridIndex(),
|
||||
m_nativeFaultGenerator->quadToCellFaceMapper());
|
||||
|
||||
texturer.createTextureCoords(m_nativeFaultFacesTextureCoords.p());
|
||||
|
||||
const RivTernaryScalarMapper* mapper = cellResultSlot->ternaryLegendConfig()->scalarMapper();
|
||||
const RivTernaryScalarMapper* mapper = cellResultColors->ternaryLegendConfig()->scalarMapper();
|
||||
RivScalarMapperUtils::applyTernaryTextureResultsToPart(m_nativeFaultFaces.p(), m_nativeFaultFacesTextureCoords.p(), mapper, m_opacityLevel, this->faceCullingMode(), eclipseView->isLightingDisabled());
|
||||
}
|
||||
else
|
||||
{
|
||||
RivTextureCoordsCreator texturer(cellResultSlot,
|
||||
RivTextureCoordsCreator texturer(cellResultColors,
|
||||
timeStepIndex,
|
||||
m_grid->gridIndex(),
|
||||
m_nativeFaultGenerator->quadToCellFaceMapper());
|
||||
@ -139,28 +139,28 @@ void RivFaultPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCell
|
||||
|
||||
texturer.createTextureCoords(m_nativeFaultFacesTextureCoords.p());
|
||||
|
||||
const cvf::ScalarMapper* mapper = cellResultSlot->legendConfig()->scalarMapper();
|
||||
const cvf::ScalarMapper* mapper = cellResultColors->legendConfig()->scalarMapper();
|
||||
RivScalarMapperUtils::applyTextureResultsToPart(m_nativeFaultFaces.p(), m_nativeFaultFacesTextureCoords.p(), mapper, m_opacityLevel, this->faceCullingMode(), eclipseView->isLightingDisabled());
|
||||
}
|
||||
}
|
||||
|
||||
if (m_oppositeFaultFaces.notNull())
|
||||
{
|
||||
if (cellResultSlot->isTernarySaturationSelected())
|
||||
if (cellResultColors->isTernarySaturationSelected())
|
||||
{
|
||||
RivTernaryTextureCoordsCreator texturer(cellResultSlot, cellResultSlot->ternaryLegendConfig(),
|
||||
RivTernaryTextureCoordsCreator texturer(cellResultColors, cellResultColors->ternaryLegendConfig(),
|
||||
timeStepIndex,
|
||||
m_grid->gridIndex(),
|
||||
m_oppositeFaultGenerator->quadToCellFaceMapper());
|
||||
|
||||
texturer.createTextureCoords(m_oppositeFaultFacesTextureCoords.p());
|
||||
|
||||
const RivTernaryScalarMapper* mapper = cellResultSlot->ternaryLegendConfig()->scalarMapper();
|
||||
const RivTernaryScalarMapper* mapper = cellResultColors->ternaryLegendConfig()->scalarMapper();
|
||||
RivScalarMapperUtils::applyTernaryTextureResultsToPart(m_oppositeFaultFaces.p(), m_oppositeFaultFacesTextureCoords.p(), mapper, m_opacityLevel, this->faceCullingMode(), eclipseView->isLightingDisabled());
|
||||
}
|
||||
else
|
||||
{
|
||||
RivTextureCoordsCreator texturer(cellResultSlot,
|
||||
RivTextureCoordsCreator texturer(cellResultColors,
|
||||
timeStepIndex,
|
||||
m_grid->gridIndex(),
|
||||
m_oppositeFaultGenerator->quadToCellFaceMapper());
|
||||
@ -172,7 +172,7 @@ void RivFaultPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCell
|
||||
|
||||
texturer.createTextureCoords(m_oppositeFaultFacesTextureCoords.p());
|
||||
|
||||
const cvf::ScalarMapper* mapper = cellResultSlot->legendConfig()->scalarMapper();
|
||||
const cvf::ScalarMapper* mapper = cellResultColors->legendConfig()->scalarMapper();
|
||||
RivScalarMapperUtils::applyTextureResultsToPart(m_oppositeFaultFaces.p(), m_oppositeFaultFacesTextureCoords.p(), mapper, m_opacityLevel, this->faceCullingMode(), eclipseView->isLightingDisabled());
|
||||
}
|
||||
}
|
||||
@ -181,9 +181,9 @@ void RivFaultPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCell
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivFaultPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot)
|
||||
void RivFaultPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors)
|
||||
{
|
||||
updateNNCColors(cellResultSlot);
|
||||
updateNNCColors(cellResultColors);
|
||||
|
||||
if (m_nativeFaultFaces.notNull())
|
||||
{
|
||||
@ -192,7 +192,7 @@ void RivFaultPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipse
|
||||
{
|
||||
cvf::ref<cvf::Effect> eff = RivScalarMapperUtils::createCellEdgeEffect(dg, m_nativeFaultGenerator->quadToCellFaceMapper(),
|
||||
m_grid->gridIndex(),
|
||||
timeStepIndex, cellResultSlot, cellEdgeResultSlot, m_opacityLevel, m_defaultColor, this->faceCullingMode(), cellResultSlot->reservoirView()->isLightingDisabled());
|
||||
timeStepIndex, cellResultColors, cellEdgeResultColors, m_opacityLevel, m_defaultColor, this->faceCullingMode(), cellResultColors->reservoirView()->isLightingDisabled());
|
||||
|
||||
m_nativeFaultFaces->setEffect(eff.p());
|
||||
}
|
||||
@ -204,7 +204,7 @@ void RivFaultPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipse
|
||||
if (dg)
|
||||
{
|
||||
cvf::ref<cvf::Effect> eff = RivScalarMapperUtils::createCellEdgeEffect(dg, m_oppositeFaultGenerator->quadToCellFaceMapper(), m_grid->gridIndex(),
|
||||
timeStepIndex, cellResultSlot, cellEdgeResultSlot, m_opacityLevel, m_defaultColor, this->faceCullingMode(), cellResultSlot->reservoirView()->isLightingDisabled());
|
||||
timeStepIndex, cellResultColors, cellEdgeResultColors, m_opacityLevel, m_defaultColor, this->faceCullingMode(), cellResultColors->reservoirView()->isLightingDisabled());
|
||||
|
||||
m_oppositeFaultFaces->setEffect(eff.p());
|
||||
}
|
||||
@ -643,15 +643,15 @@ caf::FaceCulling RivFaultPartMgr::faceCullingMode() const
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivFaultPartMgr::updateNNCColors(RimEclipseCellColors* cellResultSlot)
|
||||
void RivFaultPartMgr::updateNNCColors(RimEclipseCellColors* cellResultColors)
|
||||
{
|
||||
if (m_NNCFaces.isNull()) return;
|
||||
|
||||
bool showNncsWithScalarMappedColor = false;
|
||||
|
||||
if (cellResultSlot)
|
||||
if (cellResultColors)
|
||||
{
|
||||
size_t scalarSetIndex = cellResultSlot->scalarResultIndex();
|
||||
size_t scalarSetIndex = cellResultColors->scalarResultIndex();
|
||||
|
||||
if (m_grid->mainGrid()->nncData()->hasScalarValues(scalarSetIndex))
|
||||
{
|
||||
@ -661,9 +661,9 @@ void RivFaultPartMgr::updateNNCColors(RimEclipseCellColors* cellResultSlot)
|
||||
|
||||
if (showNncsWithScalarMappedColor)
|
||||
{
|
||||
size_t scalarSetIndex = cellResultSlot->scalarResultIndex();
|
||||
size_t scalarSetIndex = cellResultColors->scalarResultIndex();
|
||||
|
||||
const cvf::ScalarMapper* mapper = cellResultSlot->legendConfig()->scalarMapper();
|
||||
const cvf::ScalarMapper* mapper = cellResultColors->legendConfig()->scalarMapper();
|
||||
|
||||
m_NNCGenerator->textureCoordinates(m_NNCTextureCoords.p(), mapper, scalarSetIndex);
|
||||
|
||||
|
@ -55,8 +55,8 @@ public:
|
||||
|
||||
void applySingleColorEffect();
|
||||
void setOpacityLevel(float opacity) { m_opacityLevel = opacity; }
|
||||
void updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot);
|
||||
void updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors);
|
||||
void updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors);
|
||||
|
||||
void appendNativeFaultFacesToModel(cvf::ModelBasicList* model);
|
||||
void appendOppositeFaultFacesToModel(cvf::ModelBasicList* model);
|
||||
@ -68,7 +68,7 @@ private:
|
||||
void generatePartGeometry();
|
||||
void updatePartEffect();
|
||||
|
||||
void updateNNCColors(RimEclipseCellColors* cellResultSlot);
|
||||
void updateNNCColors(RimEclipseCellColors* cellResultColors);
|
||||
|
||||
caf::FaceCulling faceCullingMode() const;
|
||||
|
||||
|
@ -221,32 +221,32 @@ void RivGridPartMgr::updateCellColor(cvf::Color4f color)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivGridPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot)
|
||||
void RivGridPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors)
|
||||
{
|
||||
CVF_ASSERT(cellResultSlot);
|
||||
CVF_ASSERT(cellResultColors);
|
||||
|
||||
RigCaseData* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData();
|
||||
RigCaseData* eclipseCase = cellResultColors->reservoirView()->eclipseCase()->reservoirData();
|
||||
|
||||
cvf::ref<cvf::Color3ubArray> surfaceFacesColorArray;
|
||||
|
||||
// Outer surface
|
||||
if (m_surfaceFaces.notNull())
|
||||
{
|
||||
if (cellResultSlot->isTernarySaturationSelected())
|
||||
if (cellResultColors->isTernarySaturationSelected())
|
||||
{
|
||||
RivTernaryTextureCoordsCreator texturer(cellResultSlot, cellResultSlot->ternaryLegendConfig(),
|
||||
RivTernaryTextureCoordsCreator texturer(cellResultColors, cellResultColors->ternaryLegendConfig(),
|
||||
timeStepIndex,
|
||||
m_grid->gridIndex(),
|
||||
m_surfaceGenerator.quadToCellFaceMapper());
|
||||
|
||||
texturer.createTextureCoords(m_surfaceFacesTextureCoords.p());
|
||||
|
||||
const RivTernaryScalarMapper* mapper = cellResultSlot->ternaryLegendConfig()->scalarMapper();
|
||||
RivScalarMapperUtils::applyTernaryTextureResultsToPart(m_surfaceFaces.p(), m_surfaceFacesTextureCoords.p(), mapper, m_opacityLevel, caf::FC_NONE, cellResultSlot->reservoirView()->isLightingDisabled());
|
||||
const RivTernaryScalarMapper* mapper = cellResultColors->ternaryLegendConfig()->scalarMapper();
|
||||
RivScalarMapperUtils::applyTernaryTextureResultsToPart(m_surfaceFaces.p(), m_surfaceFacesTextureCoords.p(), mapper, m_opacityLevel, caf::FC_NONE, cellResultColors->reservoirView()->isLightingDisabled());
|
||||
}
|
||||
else
|
||||
{
|
||||
RivTextureCoordsCreator texturer(cellResultSlot,
|
||||
RivTextureCoordsCreator texturer(cellResultColors,
|
||||
timeStepIndex,
|
||||
m_grid->gridIndex(),
|
||||
m_surfaceGenerator.quadToCellFaceMapper());
|
||||
@ -257,8 +257,8 @@ void RivGridPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCellC
|
||||
|
||||
texturer.createTextureCoords(m_surfaceFacesTextureCoords.p());
|
||||
|
||||
const cvf::ScalarMapper* mapper = cellResultSlot->legendConfig()->scalarMapper();
|
||||
RivScalarMapperUtils::applyTextureResultsToPart(m_surfaceFaces.p(), m_surfaceFacesTextureCoords.p(), mapper, m_opacityLevel, caf::FC_NONE, cellResultSlot->reservoirView()->isLightingDisabled());
|
||||
const cvf::ScalarMapper* mapper = cellResultColors->legendConfig()->scalarMapper();
|
||||
RivScalarMapperUtils::applyTextureResultsToPart(m_surfaceFaces.p(), m_surfaceFacesTextureCoords.p(), mapper, m_opacityLevel, caf::FC_NONE, cellResultColors->reservoirView()->isLightingDisabled());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -266,7 +266,7 @@ void RivGridPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCellC
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivGridPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot)
|
||||
void RivGridPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors)
|
||||
{
|
||||
if (m_surfaceFaces.notNull())
|
||||
{
|
||||
@ -274,7 +274,7 @@ void RivGridPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseC
|
||||
if (dg)
|
||||
{
|
||||
cvf::ref<cvf::Effect> eff = RivScalarMapperUtils::createCellEdgeEffect(dg, m_surfaceGenerator.quadToCellFaceMapper(), m_grid->gridIndex(),
|
||||
timeStepIndex, cellResultSlot, cellEdgeResultSlot, m_opacityLevel, m_defaultColor, caf::FC_NONE, cellResultSlot->reservoirView()->isLightingDisabled());
|
||||
timeStepIndex, cellResultColors, cellEdgeResultColors, m_opacityLevel, m_defaultColor, caf::FC_NONE, cellResultColors->reservoirView()->isLightingDisabled());
|
||||
|
||||
m_surfaceFaces->setEffect(eff.p());
|
||||
}
|
||||
|
@ -57,10 +57,10 @@ public:
|
||||
cvf::ref<cvf::UByteArray> cellVisibility() { return m_cellVisibility;}
|
||||
|
||||
void updateCellColor(cvf::Color4f color);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors);
|
||||
|
||||
void updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot);
|
||||
void updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors);
|
||||
|
||||
void appendPartsToModel(cvf::ModelBasicList* model);
|
||||
|
||||
|
@ -142,8 +142,8 @@ void RivReservoirFaultsPartMgr::appendPartsToModel(cvf::ModelBasicList* model)
|
||||
}
|
||||
|
||||
// Parts that is not overridden by the grid settings
|
||||
RimEclipseFaultColors* faultResultSlot = m_reservoirView->faultResultSettings();
|
||||
RimEclipseCellColors* cellResultSlot = m_reservoirView->cellResult();
|
||||
RimEclipseFaultColors* faultResultColors = m_reservoirView->faultResultSettings();
|
||||
RimEclipseCellColors* cellResultColors = m_reservoirView->cellResult();
|
||||
|
||||
if (rimFault->showFault() && faultCollection->showFaultCollection())
|
||||
{
|
||||
@ -153,13 +153,13 @@ void RivReservoirFaultsPartMgr::appendPartsToModel(cvf::ModelBasicList* model)
|
||||
if (faultCollection->hideNncsWhenNoResultIsAvailable())
|
||||
{
|
||||
size_t scalarResultIndex = cvf::UNDEFINED_SIZE_T;
|
||||
if (faultResultSlot->showCustomFaultResult())
|
||||
if (faultResultColors->showCustomFaultResult())
|
||||
{
|
||||
scalarResultIndex = faultResultSlot->customFaultResult()->scalarResultIndex();
|
||||
scalarResultIndex = faultResultColors->customFaultResult()->scalarResultIndex();
|
||||
}
|
||||
else
|
||||
{
|
||||
scalarResultIndex = cellResultSlot->scalarResultIndex();
|
||||
scalarResultIndex = cellResultColors->scalarResultIndex();
|
||||
}
|
||||
|
||||
RigMainGrid* mainGrid = m_reservoirView->eclipseCase()->reservoirData()->mainGrid();
|
||||
@ -200,7 +200,7 @@ void RivReservoirFaultsPartMgr::applySingleColorEffect()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirFaultsPartMgr::updateColors(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot)
|
||||
void RivReservoirFaultsPartMgr::updateColors(size_t timeStepIndex, RimEclipseCellColors* cellResultColors)
|
||||
{
|
||||
if (!m_reservoirView) return;
|
||||
|
||||
@ -211,9 +211,9 @@ void RivReservoirFaultsPartMgr::updateColors(size_t timeStepIndex, RimEclipseCel
|
||||
{
|
||||
RimFault* rimFault = faultCollection->faults[i];
|
||||
|
||||
if (cellResultSlot && (cellResultSlot->hasResult() || cellResultSlot->isTernarySaturationSelected()) )
|
||||
if (cellResultColors && (cellResultColors->hasResult() || cellResultColors->isTernarySaturationSelected()) )
|
||||
{
|
||||
m_faultParts[i]->updateCellResultColor(timeStepIndex, cellResultSlot);
|
||||
m_faultParts[i]->updateCellResultColor(timeStepIndex, cellResultColors);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -225,11 +225,11 @@ void RivReservoirFaultsPartMgr::updateColors(size_t timeStepIndex, RimEclipseCel
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirFaultsPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot)
|
||||
void RivReservoirFaultsPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors)
|
||||
{
|
||||
for (size_t i = 0; i < m_faultParts.size(); i++)
|
||||
{
|
||||
m_faultParts[i]->updateCellEdgeResultColor(timeStepIndex, cellResultSlot, cellEdgeResultSlot);
|
||||
m_faultParts[i]->updateCellEdgeResultColor(timeStepIndex, cellResultColors, cellEdgeResultColors);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -49,9 +49,9 @@ public:
|
||||
|
||||
void setOpacityLevel(float opacity);
|
||||
void applySingleColorEffect();
|
||||
void updateColors(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot);
|
||||
void updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot);
|
||||
void updateColors(size_t timeStepIndex, RimEclipseCellColors* cellResultColors);
|
||||
void updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors);
|
||||
|
||||
void appendPartsToModel(cvf::ModelBasicList* model);
|
||||
|
||||
|
@ -111,22 +111,22 @@ void RivReservoirPartMgr::updateCellColor(cvf::Color4f color)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot)
|
||||
void RivReservoirPartMgr::updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors)
|
||||
{
|
||||
for (size_t i = 0; i < m_allGrids.size() ; ++i)
|
||||
{
|
||||
m_allGrids[i]->updateCellResultColor(timeStepIndex, cellResultSlot);
|
||||
m_allGrids[i]->updateCellResultColor(timeStepIndex, cellResultColors);
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot)
|
||||
void RivReservoirPartMgr::updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors)
|
||||
{
|
||||
for (size_t i = 0; i < m_allGrids.size() ; ++i)
|
||||
{
|
||||
m_allGrids[i]->updateCellEdgeResultColor(timeStepIndex, cellResultSlot, cellEdgeResultSlot);
|
||||
m_allGrids[i]->updateCellEdgeResultColor(timeStepIndex, cellResultColors, cellEdgeResultColors);
|
||||
}
|
||||
}
|
||||
|
||||
@ -158,11 +158,11 @@ void RivReservoirPartMgr::appendGridPartsToModel(cvf::ModelBasicList* model, con
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirPartMgr::updateFaultColors(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot)
|
||||
void RivReservoirPartMgr::updateFaultColors(size_t timeStepIndex, RimEclipseCellColors* cellResultColors)
|
||||
{
|
||||
if (m_faultsPartMgr.notNull())
|
||||
{
|
||||
m_faultsPartMgr->updateColors(timeStepIndex, cellResultSlot);
|
||||
m_faultsPartMgr->updateColors(timeStepIndex, cellResultColors);
|
||||
}
|
||||
}
|
||||
|
||||
@ -202,11 +202,11 @@ void RivReservoirPartMgr::setFaultForceVisibility(bool isGeneratedByFilter)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirPartMgr::updateFaultCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot)
|
||||
void RivReservoirPartMgr::updateFaultCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors)
|
||||
{
|
||||
if (m_faultsPartMgr.notNull())
|
||||
{
|
||||
m_faultsPartMgr->updateCellEdgeResultColor(timeStepIndex, cellResultSlot, cellEdgeResultSlot);
|
||||
m_faultsPartMgr->updateCellEdgeResultColor(timeStepIndex, cellResultColors, cellEdgeResultColors);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -57,17 +57,17 @@ public:
|
||||
cellVisibility(size_t gridIdx);
|
||||
|
||||
void updateCellColor(cvf::Color4f color);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot);
|
||||
void updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot);
|
||||
void updateCellResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors);
|
||||
void updateCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors);
|
||||
|
||||
void appendGridPartsToModel(cvf::ModelBasicList* model, const std::vector<size_t>& gridIdxes);
|
||||
void appendGridPartsToModel(cvf::ModelBasicList* model);
|
||||
|
||||
// Faults
|
||||
void updateFaultColors(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot);
|
||||
void updateFaultCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot);
|
||||
void updateFaultColors(size_t timeStepIndex, RimEclipseCellColors* cellResultColors);
|
||||
void updateFaultCellEdgeResultColor(size_t timeStepIndex, RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors);
|
||||
void appendFaultPartsToModel(cvf::ModelBasicList* model);
|
||||
void appendFaultLabelPartsToModel(cvf::ModelBasicList* model);
|
||||
private:
|
||||
|
@ -789,28 +789,28 @@ void RivReservoirViewPartMgr::updateCellColor(RivCellSetEnum geometryType, cvf::
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirViewPartMgr::updateCellResultColor(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultSlot)
|
||||
void RivReservoirViewPartMgr::updateCellResultColor(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultColors)
|
||||
{
|
||||
RivReservoirPartMgr * pmgr = reservoirPartManager( geometryType, timeStepIndex );
|
||||
pmgr->updateCellResultColor(timeStepIndex, cellResultSlot);
|
||||
pmgr->updateCellResultColor(timeStepIndex, cellResultColors);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirViewPartMgr::updateCellEdgeResultColor(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot)
|
||||
void RivReservoirViewPartMgr::updateCellEdgeResultColor(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors)
|
||||
{
|
||||
RivReservoirPartMgr * pmgr = reservoirPartManager( geometryType, timeStepIndex );
|
||||
pmgr->updateCellEdgeResultColor(timeStepIndex, cellResultSlot, cellEdgeResultSlot);
|
||||
pmgr->updateCellEdgeResultColor(timeStepIndex, cellResultColors, cellEdgeResultColors);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirViewPartMgr::updateFaultCellEdgeResultColor(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultSlot, RimCellEdgeColors* cellEdgeResultSlot)
|
||||
void RivReservoirViewPartMgr::updateFaultCellEdgeResultColor(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultColors, RimCellEdgeColors* cellEdgeResultColors)
|
||||
{
|
||||
RivReservoirPartMgr * pmgr = reservoirPartManager(geometryType, timeStepIndex);
|
||||
pmgr->updateFaultCellEdgeResultColor(timeStepIndex, cellResultSlot, cellEdgeResultSlot);
|
||||
pmgr->updateFaultCellEdgeResultColor(timeStepIndex, cellResultColors, cellEdgeResultColors);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@ -841,7 +841,7 @@ RivReservoirPartMgr * RivReservoirViewPartMgr::reservoirPartManager(RivCellSetEn
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RivReservoirViewPartMgr::updateFaultColors(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultSlot)
|
||||
void RivReservoirViewPartMgr::updateFaultColors(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultColors)
|
||||
{
|
||||
if (geometryType == PROPERTY_FILTERED && timeStepIndex >= m_propFilteredGeometryFrames.size())
|
||||
{
|
||||
@ -854,7 +854,7 @@ void RivReservoirViewPartMgr::updateFaultColors(RivCellSetEnum geometryType, siz
|
||||
}
|
||||
|
||||
RivReservoirPartMgr* pmgr = reservoirPartManager(geometryType, timeStepIndex);
|
||||
pmgr->updateFaultColors(timeStepIndex, cellResultSlot);
|
||||
pmgr->updateFaultColors(timeStepIndex, cellResultColors);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
@ -50,18 +50,18 @@ public:
|
||||
void updateCellColor (RivCellSetEnum geometryType, size_t timeStepIndex,
|
||||
cvf::Color4f color);
|
||||
void updateCellResultColor (RivCellSetEnum geometryType, size_t timeStepIndex,
|
||||
RimEclipseCellColors* cellResultSlot);
|
||||
RimEclipseCellColors* cellResultColors);
|
||||
void updateCellEdgeResultColor(RivCellSetEnum geometryType, size_t timeStepIndex,
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot);
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors);
|
||||
|
||||
// Faults
|
||||
void appendFaultsStaticGeometryPartsToModel(cvf::ModelBasicList* model, RivCellSetEnum geometryType);
|
||||
void appendFaultsDynamicGeometryPartsToModel(cvf::ModelBasicList* model, RivCellSetEnum geometryType, size_t frameIndex);
|
||||
void updateFaultColors(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultSlot);
|
||||
void updateFaultColors(RivCellSetEnum geometryType, size_t timeStepIndex, RimEclipseCellColors* cellResultColors);
|
||||
void updateFaultCellEdgeResultColor( RivCellSetEnum geometryType, size_t timeStepIndex,
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot);
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors);
|
||||
|
||||
// Fault labels
|
||||
RivCellSetEnum geometryTypeForFaultLabels(const std::vector<RivCellSetEnum>& geometryTypes) const;
|
||||
|
@ -71,29 +71,29 @@ cvf::ref<cvf::Effect> RivScalarMapperUtils::createCellEdgeEffect(cvf::DrawableGe
|
||||
const cvf::StructGridQuadToCellFaceMapper* quadToCellFaceMapper,
|
||||
size_t gridIndex,
|
||||
size_t timeStepIndex,
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors,
|
||||
float opacityLevel,
|
||||
cvf::Color3f defaultColor,
|
||||
caf::FaceCulling faceCulling,
|
||||
bool disableLighting)
|
||||
{
|
||||
CellEdgeEffectGenerator cellFaceEffectGen(cellEdgeResultSlot->legendConfig()->scalarMapper());
|
||||
CellEdgeEffectGenerator cellFaceEffectGen(cellEdgeResultColors->legendConfig()->scalarMapper());
|
||||
|
||||
if (cellResultSlot->isTernarySaturationSelected())
|
||||
if (cellResultColors->isTernarySaturationSelected())
|
||||
{
|
||||
RivCellEdgeGeometryUtils::addTernaryCellEdgeResultsToDrawableGeo(timeStepIndex, cellResultSlot, cellEdgeResultSlot,
|
||||
RivCellEdgeGeometryUtils::addTernaryCellEdgeResultsToDrawableGeo(timeStepIndex, cellResultColors, cellEdgeResultColors,
|
||||
quadToCellFaceMapper, dg, gridIndex, opacityLevel);
|
||||
|
||||
RivTernaryScalarMapper* ternaryCellScalarMapper = cellResultSlot->ternaryLegendConfig()->scalarMapper();
|
||||
RivTernaryScalarMapper* ternaryCellScalarMapper = cellResultColors->ternaryLegendConfig()->scalarMapper();
|
||||
cellFaceEffectGen.setTernaryScalarMapper(ternaryCellScalarMapper);
|
||||
}
|
||||
else
|
||||
{
|
||||
RivCellEdgeGeometryUtils::addCellEdgeResultsToDrawableGeo(timeStepIndex, cellResultSlot, cellEdgeResultSlot,
|
||||
RivCellEdgeGeometryUtils::addCellEdgeResultsToDrawableGeo(timeStepIndex, cellResultColors, cellEdgeResultColors,
|
||||
quadToCellFaceMapper, dg, gridIndex, opacityLevel);
|
||||
|
||||
cvf::ScalarMapper* cellScalarMapper = cellResultSlot->legendConfig()->scalarMapper();
|
||||
cvf::ScalarMapper* cellScalarMapper = cellResultColors->legendConfig()->scalarMapper();
|
||||
cellFaceEffectGen.setScalarMapper(cellScalarMapper);
|
||||
}
|
||||
|
||||
|
@ -50,8 +50,8 @@ public:
|
||||
const cvf::StructGridQuadToCellFaceMapper* quadToCellFaceMapper,
|
||||
size_t gridIndex,
|
||||
size_t timeStepIndex,
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimCellEdgeColors* cellEdgeResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimCellEdgeColors* cellEdgeResultColors,
|
||||
float opacityLevel,
|
||||
cvf::Color3f defaultColor,
|
||||
caf::FaceCulling faceCulling,
|
||||
|
@ -38,22 +38,22 @@
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RivTernaryTextureCoordsCreator::RivTernaryTextureCoordsCreator(
|
||||
RimEclipseCellColors* cellResultSlot,
|
||||
RimEclipseCellColors* cellResultColors,
|
||||
RimTernaryLegendConfig* ternaryLegendConfig,
|
||||
size_t timeStepIndex,
|
||||
size_t gridIndex,
|
||||
const cvf::StructGridQuadToCellFaceMapper* quadMapper)
|
||||
{
|
||||
RigCaseData* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData();
|
||||
RigCaseData* eclipseCase = cellResultColors->reservoirView()->eclipseCase()->reservoirData();
|
||||
|
||||
m_quadMapper = quadMapper;
|
||||
CVF_ASSERT(quadMapper && eclipseCase );
|
||||
|
||||
size_t resTimeStepIdx = timeStepIndex;
|
||||
|
||||
if (cellResultSlot->hasStaticResult()) resTimeStepIdx = 0;
|
||||
if (cellResultColors->hasStaticResult()) resTimeStepIdx = 0;
|
||||
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel());
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultColors->porosityModel());
|
||||
|
||||
cvf::ref<RigResultAccessor> soil = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, resTimeStepIdx, "SOIL");
|
||||
cvf::ref<RigResultAccessor> sgas = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, resTimeStepIdx, "SGAS");
|
||||
@ -62,7 +62,7 @@ RivTernaryTextureCoordsCreator::RivTernaryTextureCoordsCreator(
|
||||
m_resultAccessor = new RigTernaryResultAccessor();
|
||||
m_resultAccessor->setTernaryResultAccessors(soil.p(), sgas.p(), swat.p());
|
||||
|
||||
cvf::ref<RigPipeInCellEvaluator> pipeInCellEval = new RigPipeInCellEvaluator( cellResultSlot->reservoirView()->wellCollection()->isWellPipesVisible(timeStepIndex),
|
||||
cvf::ref<RigPipeInCellEvaluator> pipeInCellEval = new RigPipeInCellEvaluator( cellResultColors->reservoirView()->wellCollection()->isWellPipesVisible(timeStepIndex),
|
||||
eclipseCase->gridCellToWellIndex(gridIndex));
|
||||
|
||||
const RivTernaryScalarMapper* mapper = ternaryLegendConfig->scalarMapper();
|
||||
|
@ -41,7 +41,7 @@ namespace cvf
|
||||
class RivTernaryTextureCoordsCreator
|
||||
{
|
||||
public:
|
||||
RivTernaryTextureCoordsCreator( RimEclipseCellColors* cellResultSlot,
|
||||
RivTernaryTextureCoordsCreator( RimEclipseCellColors* cellResultColors,
|
||||
RimTernaryLegendConfig* ternaryLegendConfig,
|
||||
size_t timeStepIndex,
|
||||
size_t gridIndex,
|
||||
|
@ -32,25 +32,25 @@
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RivTextureCoordsCreator::RivTextureCoordsCreator(RimEclipseCellColors* cellResultSlot, size_t timeStepIndex, size_t gridIndex, const cvf::StructGridQuadToCellFaceMapper* quadMapper)
|
||||
RivTextureCoordsCreator::RivTextureCoordsCreator(RimEclipseCellColors* cellResultColors, size_t timeStepIndex, size_t gridIndex, const cvf::StructGridQuadToCellFaceMapper* quadMapper)
|
||||
{
|
||||
RigCaseData* eclipseCase = cellResultSlot->reservoirView()->eclipseCase()->reservoirData();
|
||||
RigCaseData* eclipseCase = cellResultColors->reservoirView()->eclipseCase()->reservoirData();
|
||||
|
||||
m_quadMapper = quadMapper;
|
||||
CVF_ASSERT(quadMapper && eclipseCase );
|
||||
|
||||
size_t resTimeStepIdx = timeStepIndex;
|
||||
|
||||
if (cellResultSlot->hasStaticResult()) resTimeStepIdx = 0;
|
||||
if (cellResultColors->hasStaticResult()) resTimeStepIdx = 0;
|
||||
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultSlot->porosityModel());
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResultColors->porosityModel());
|
||||
|
||||
m_resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, resTimeStepIdx, cellResultSlot->resultVariable());
|
||||
m_resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, resTimeStepIdx, cellResultColors->resultVariable());
|
||||
|
||||
cvf::ref<RigPipeInCellEvaluator> pipeInCellEval = new RigPipeInCellEvaluator(cellResultSlot->reservoirView()->wellCollection()->isWellPipesVisible(timeStepIndex),
|
||||
cvf::ref<RigPipeInCellEvaluator> pipeInCellEval = new RigPipeInCellEvaluator(cellResultColors->reservoirView()->wellCollection()->isWellPipesVisible(timeStepIndex),
|
||||
eclipseCase->gridCellToWellIndex(gridIndex));
|
||||
|
||||
const cvf::ScalarMapper* mapper = cellResultSlot->legendConfig()->scalarMapper();
|
||||
const cvf::ScalarMapper* mapper = cellResultColors->legendConfig()->scalarMapper();
|
||||
|
||||
m_texMapper = new RivResultToTextureMapper(mapper, pipeInCellEval.p());
|
||||
CVF_ASSERT(m_texMapper.notNull());
|
||||
|
@ -36,7 +36,7 @@ namespace cvf
|
||||
class RivTextureCoordsCreator
|
||||
{
|
||||
public:
|
||||
RivTextureCoordsCreator(RimEclipseCellColors* cellResultSlot,
|
||||
RivTextureCoordsCreator(RimEclipseCellColors* cellResultColors,
|
||||
size_t timeStepIndex,
|
||||
size_t gridIndex,
|
||||
const cvf::StructGridQuadToCellFaceMapper* quadMapper);
|
||||
|
@ -906,7 +906,7 @@ void RimEclipseView::updateLegends()
|
||||
updateMinMaxValuesAndAddLegendToView(QString("Cell Results: \n"), this->cellResult(), results);
|
||||
if (this->faultResultSettings()->showCustomFaultResult() && this->faultResultSettings()->hasValidCustomResult())
|
||||
{
|
||||
updateMinMaxValuesAndAddLegendToView(QString("Fault Results: \n"), this->currentFaultResultSlot(), results);
|
||||
updateMinMaxValuesAndAddLegendToView(QString("Fault Results: \n"), this->currentFaultResultColors(), results);
|
||||
}
|
||||
|
||||
if (this->cellEdgeResult()->hasResult())
|
||||
@ -932,21 +932,21 @@ void RimEclipseView::updateLegends()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimEclipseView::updateMinMaxValuesAndAddLegendToView(QString legendLabel, RimEclipseCellColors* resultSlot, RigCaseCellResultsData* cellResultsData)
|
||||
void RimEclipseView::updateMinMaxValuesAndAddLegendToView(QString legendLabel, RimEclipseCellColors* resultColors, RigCaseCellResultsData* cellResultsData)
|
||||
{
|
||||
if (resultSlot->hasResult())
|
||||
if (resultColors->hasResult())
|
||||
{
|
||||
double globalMin, globalMax;
|
||||
double globalPosClosestToZero, globalNegClosestToZero;
|
||||
cellResultsData->minMaxCellScalarValues(resultSlot->scalarResultIndex(), globalMin, globalMax);
|
||||
cellResultsData->posNegClosestToZero(resultSlot->scalarResultIndex(), globalPosClosestToZero, globalNegClosestToZero);
|
||||
cellResultsData->minMaxCellScalarValues(resultColors->scalarResultIndex(), globalMin, globalMax);
|
||||
cellResultsData->posNegClosestToZero(resultColors->scalarResultIndex(), globalPosClosestToZero, globalNegClosestToZero);
|
||||
|
||||
double localMin, localMax;
|
||||
double localPosClosestToZero, localNegClosestToZero;
|
||||
if (resultSlot->hasDynamicResult())
|
||||
if (resultColors->hasDynamicResult())
|
||||
{
|
||||
cellResultsData->minMaxCellScalarValues(resultSlot->scalarResultIndex(), m_currentTimeStep, localMin, localMax);
|
||||
cellResultsData->posNegClosestToZero(resultSlot->scalarResultIndex(), m_currentTimeStep, localPosClosestToZero, localNegClosestToZero);
|
||||
cellResultsData->minMaxCellScalarValues(resultColors->scalarResultIndex(), m_currentTimeStep, localMin, localMax);
|
||||
cellResultsData->posNegClosestToZero(resultColors->scalarResultIndex(), m_currentTimeStep, localPosClosestToZero, localNegClosestToZero);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -957,22 +957,22 @@ void RimEclipseView::updateMinMaxValuesAndAddLegendToView(QString legendLabel, R
|
||||
localNegClosestToZero = globalNegClosestToZero;
|
||||
}
|
||||
|
||||
resultSlot->legendConfig->setClosestToZeroValues(globalPosClosestToZero, globalNegClosestToZero, localPosClosestToZero, localNegClosestToZero);
|
||||
resultSlot->legendConfig->setAutomaticRanges(globalMin, globalMax, localMin, localMax);
|
||||
resultColors->legendConfig->setClosestToZeroValues(globalPosClosestToZero, globalNegClosestToZero, localPosClosestToZero, localNegClosestToZero);
|
||||
resultColors->legendConfig->setAutomaticRanges(globalMin, globalMax, localMin, localMax);
|
||||
|
||||
m_viewer->addColorLegendToBottomLeftCorner(resultSlot->legendConfig->legend());
|
||||
resultSlot->legendConfig->legend()->setTitle(cvfqt::Utils::toString(legendLabel + resultSlot->resultVariable()));
|
||||
m_viewer->addColorLegendToBottomLeftCorner(resultColors->legendConfig->legend());
|
||||
resultColors->legendConfig->legend()->setTitle(cvfqt::Utils::toString(legendLabel + resultColors->resultVariable()));
|
||||
}
|
||||
else
|
||||
{
|
||||
resultSlot->legendConfig->setClosestToZeroValues(0, 0, 0, 0);
|
||||
resultSlot->legendConfig->setAutomaticRanges(cvf::UNDEFINED_DOUBLE, cvf::UNDEFINED_DOUBLE, cvf::UNDEFINED_DOUBLE, cvf::UNDEFINED_DOUBLE);
|
||||
resultColors->legendConfig->setClosestToZeroValues(0, 0, 0, 0);
|
||||
resultColors->legendConfig->setAutomaticRanges(cvf::UNDEFINED_DOUBLE, cvf::UNDEFINED_DOUBLE, cvf::UNDEFINED_DOUBLE, cvf::UNDEFINED_DOUBLE);
|
||||
}
|
||||
|
||||
size_t maxTimeStepCount = cellResultsData->maxTimeStepCount();
|
||||
if (resultSlot->isTernarySaturationSelected() && maxTimeStepCount > 1)
|
||||
if (resultColors->isTernarySaturationSelected() && maxTimeStepCount > 1)
|
||||
{
|
||||
RimReservoirCellResultsStorage* gridCellResults = resultSlot->currentGridCellResults();
|
||||
RimReservoirCellResultsStorage* gridCellResults = resultColors->currentGridCellResults();
|
||||
{
|
||||
double globalMin = 0.0;
|
||||
double globalMax = 1.0;
|
||||
@ -985,7 +985,7 @@ void RimEclipseView::updateMinMaxValuesAndAddLegendToView(QString legendLabel, R
|
||||
cellResultsData->minMaxCellScalarValues(scalarSetIndex, globalMin, globalMax);
|
||||
cellResultsData->minMaxCellScalarValues(scalarSetIndex, m_currentTimeStep, localMin, localMax);
|
||||
|
||||
resultSlot->ternaryLegendConfig()->setAutomaticRanges(RimTernaryLegendConfig::TERNARY_SOIL_IDX, globalMin, globalMax, localMin, localMax);
|
||||
resultColors->ternaryLegendConfig()->setAutomaticRanges(RimTernaryLegendConfig::TERNARY_SOIL_IDX, globalMin, globalMax, localMin, localMax);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1001,7 +1001,7 @@ void RimEclipseView::updateMinMaxValuesAndAddLegendToView(QString legendLabel, R
|
||||
cellResultsData->minMaxCellScalarValues(scalarSetIndex, globalMin, globalMax);
|
||||
cellResultsData->minMaxCellScalarValues(scalarSetIndex, m_currentTimeStep, localMin, localMax);
|
||||
|
||||
resultSlot->ternaryLegendConfig()->setAutomaticRanges(RimTernaryLegendConfig::TERNARY_SGAS_IDX, globalMin, globalMax, localMin, localMax);
|
||||
resultColors->ternaryLegendConfig()->setAutomaticRanges(RimTernaryLegendConfig::TERNARY_SGAS_IDX, globalMin, globalMax, localMin, localMax);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1017,14 +1017,14 @@ void RimEclipseView::updateMinMaxValuesAndAddLegendToView(QString legendLabel, R
|
||||
cellResultsData->minMaxCellScalarValues(scalarSetIndex, globalMin, globalMax);
|
||||
cellResultsData->minMaxCellScalarValues(scalarSetIndex, m_currentTimeStep, localMin, localMax);
|
||||
|
||||
resultSlot->ternaryLegendConfig()->setAutomaticRanges(RimTernaryLegendConfig::TERNARY_SWAT_IDX, globalMin, globalMax, localMin, localMax);
|
||||
resultColors->ternaryLegendConfig()->setAutomaticRanges(RimTernaryLegendConfig::TERNARY_SWAT_IDX, globalMin, globalMax, localMin, localMax);
|
||||
}
|
||||
}
|
||||
|
||||
if (resultSlot->ternaryLegendConfig->legend())
|
||||
if (resultColors->ternaryLegendConfig->legend())
|
||||
{
|
||||
resultSlot->ternaryLegendConfig->legend()->setTitle(cvfqt::Utils::toString(legendLabel));
|
||||
m_viewer->addColorLegendToBottomLeftCorner(resultSlot->ternaryLegendConfig->legend());
|
||||
resultColors->ternaryLegendConfig->legend()->setTitle(cvfqt::Utils::toString(legendLabel));
|
||||
m_viewer->addColorLegendToBottomLeftCorner(resultColors->ternaryLegendConfig->legend());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1371,17 +1371,17 @@ void RimEclipseView::updateFaultColors()
|
||||
// Update all fault geometry
|
||||
std::vector<RivCellSetEnum> faultGeometriesToRecolor = visibleFaultGeometryTypes();
|
||||
|
||||
RimEclipseCellColors* faultResultSlot = currentFaultResultSlot();
|
||||
RimEclipseCellColors* faultResultColors = currentFaultResultColors();
|
||||
|
||||
for (size_t i = 0; i < faultGeometriesToRecolor.size(); ++i)
|
||||
{
|
||||
if (this->hasUserRequestedAnimation() && this->cellEdgeResult()->hasResult())
|
||||
{
|
||||
m_reservoirGridPartManager->updateFaultCellEdgeResultColor(faultGeometriesToRecolor[i], m_currentTimeStep, faultResultSlot, this->cellEdgeResult());
|
||||
m_reservoirGridPartManager->updateFaultCellEdgeResultColor(faultGeometriesToRecolor[i], m_currentTimeStep, faultResultColors, this->cellEdgeResult());
|
||||
}
|
||||
else
|
||||
{
|
||||
m_reservoirGridPartManager->updateFaultColors(faultGeometriesToRecolor[i], m_currentTimeStep, faultResultSlot);
|
||||
m_reservoirGridPartManager->updateFaultColors(faultGeometriesToRecolor[i], m_currentTimeStep, faultResultColors);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1414,16 +1414,16 @@ bool RimEclipseView::isTimeStepDependentDataVisible() const
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimEclipseCellColors* RimEclipseView::currentFaultResultSlot()
|
||||
RimEclipseCellColors* RimEclipseView::currentFaultResultColors()
|
||||
{
|
||||
RimEclipseCellColors* faultResultSlot = this->cellResult();
|
||||
RimEclipseCellColors* faultResultColors = this->cellResult();
|
||||
|
||||
if (this->faultResultSettings()->showCustomFaultResult())
|
||||
{
|
||||
faultResultSlot = this->faultResultSettings()->customFaultResult();
|
||||
faultResultColors = this->faultResultSettings()->customFaultResult();
|
||||
}
|
||||
|
||||
return faultResultSlot;
|
||||
return faultResultColors;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
@ -103,7 +103,7 @@ public:
|
||||
|
||||
RimReservoirCellResultsStorage* currentGridCellResults();
|
||||
RigActiveCellInfo* currentActiveCellInfo();
|
||||
RimEclipseCellColors* currentFaultResultSlot();
|
||||
RimEclipseCellColors* currentFaultResultColors();
|
||||
|
||||
void setEclipseCase(RimEclipseCase* reservoir);
|
||||
RimEclipseCase* eclipseCase();
|
||||
@ -142,7 +142,7 @@ private:
|
||||
virtual void updateStaticCellColors();
|
||||
void updateStaticCellColors(RivCellSetEnum geometryType);
|
||||
void updateLegends();
|
||||
void updateMinMaxValuesAndAddLegendToView(QString legendLabel, RimEclipseCellColors* resultSlot, RigCaseCellResultsData* cellResultsData);
|
||||
void updateMinMaxValuesAndAddLegendToView(QString legendLabel, RimEclipseCellColors* resultColors, RigCaseCellResultsData* cellResultsData);
|
||||
virtual void resetLegendsInViewer();
|
||||
virtual void updateViewerWidgetWindowTitle();
|
||||
|
||||
|
@ -887,14 +887,14 @@ void RimUiTreeView::slotWriteBinaryResultAsInputProperty()
|
||||
RimUiTreeModelPdm* myModel = dynamic_cast<RimUiTreeModelPdm*>(model());
|
||||
caf::PdmUiTreeItem* uiItem = myModel->getTreeItemFromIndex(currentIndex());
|
||||
|
||||
RimEclipseCellColors* resultSlot = dynamic_cast<RimEclipseCellColors*>(uiItem->dataObject().p());
|
||||
if (!resultSlot) return;
|
||||
if (!resultSlot->reservoirView()) return;
|
||||
if (!resultSlot->reservoirView()->eclipseCase()) return;
|
||||
if (!resultSlot->reservoirView()->eclipseCase()->reservoirData()) return;
|
||||
RimEclipseCellColors* resultColors = dynamic_cast<RimEclipseCellColors*>(uiItem->dataObject().p());
|
||||
if (!resultColors) return;
|
||||
if (!resultColors->reservoirView()) return;
|
||||
if (!resultColors->reservoirView()->eclipseCase()) return;
|
||||
if (!resultColors->reservoirView()->eclipseCase()->reservoirData()) return;
|
||||
|
||||
RimBinaryExportSettings exportSettings;
|
||||
exportSettings.eclipseKeyword = resultSlot->resultVariable();
|
||||
exportSettings.eclipseKeyword = resultColors->resultVariable();
|
||||
|
||||
{
|
||||
QString projectFolder;
|
||||
@ -908,10 +908,10 @@ void RimUiTreeView::slotWriteBinaryResultAsInputProperty()
|
||||
}
|
||||
else
|
||||
{
|
||||
projectFolder = resultSlot->reservoirView()->eclipseCase()->locationOnDisc();
|
||||
projectFolder = resultColors->reservoirView()->eclipseCase()->locationOnDisc();
|
||||
}
|
||||
|
||||
QString outputFileName = projectFolder + "/" + resultSlot->resultVariable();
|
||||
QString outputFileName = projectFolder + "/" + resultColors->resultVariable();
|
||||
|
||||
exportSettings.fileName = outputFileName;
|
||||
}
|
||||
@ -919,10 +919,10 @@ void RimUiTreeView::slotWriteBinaryResultAsInputProperty()
|
||||
caf::PdmUiPropertyDialog propertyDialog(this, &exportSettings, "Export Binary Eclipse Data to Text File");
|
||||
if (propertyDialog.exec() == QDialog::Accepted)
|
||||
{
|
||||
size_t timeStep = resultSlot->reservoirView()->currentTimeStep();
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultSlot->porosityModel());
|
||||
size_t timeStep = resultColors->reservoirView()->currentTimeStep();
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultColors->porosityModel());
|
||||
|
||||
bool isOk = RifEclipseInputFileTools::writeBinaryResultToTextFile(exportSettings.fileName, resultSlot->reservoirView()->eclipseCase()->reservoirData(), porosityModel, timeStep, resultSlot->resultVariable(), exportSettings.eclipseKeyword, exportSettings.undefinedValue);
|
||||
bool isOk = RifEclipseInputFileTools::writeBinaryResultToTextFile(exportSettings.fileName, resultColors->reservoirView()->eclipseCase()->reservoirData(), porosityModel, timeStep, resultColors->resultVariable(), exportSettings.eclipseKeyword, exportSettings.undefinedValue);
|
||||
if (!isOk)
|
||||
{
|
||||
QMessageBox::critical(NULL, "File export", "Failed to exported current result to " + exportSettings.fileName);
|
||||
|
@ -141,7 +141,7 @@ QString RiuFemResultTextBuilder::gridResultDetails()
|
||||
{
|
||||
RigGeoMechCaseData* eclipseCaseData = m_reservoirView->geoMechCase()->geoMechData();
|
||||
|
||||
this->appendTextFromResultSlot(eclipseCaseData, m_gridIndex, m_cellIndex, m_timeStepIndex, m_reservoirView->cellResult(), &text);
|
||||
this->appendTextFromResultColors(eclipseCaseData, m_gridIndex, m_cellIndex, m_timeStepIndex, m_reservoirView->cellResult(), &text);
|
||||
|
||||
if (!text.isEmpty())
|
||||
{
|
||||
@ -156,22 +156,22 @@ QString RiuFemResultTextBuilder::gridResultDetails()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuFemResultTextBuilder::appendTextFromResultSlot(RigGeoMechCaseData* geomData, int gridIndex, int cellIndex, int timeStepIndex, RimGeoMechCellColors* resultSlot, QString* resultInfoText)
|
||||
void RiuFemResultTextBuilder::appendTextFromResultColors(RigGeoMechCaseData* geomData, int gridIndex, int cellIndex, int timeStepIndex, RimGeoMechCellColors* resultColors, QString* resultInfoText)
|
||||
{
|
||||
if (!resultSlot)
|
||||
if (!resultColors)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (resultSlot->hasResult())
|
||||
if (resultColors->hasResult())
|
||||
{
|
||||
const std::vector<float>& scalarResults = geomData->femPartResults()->resultValues(resultSlot->resultAddress(), gridIndex, timeStepIndex);
|
||||
const std::vector<float>& scalarResults = geomData->femPartResults()->resultValues(resultColors->resultAddress(), gridIndex, timeStepIndex);
|
||||
if (scalarResults.size())
|
||||
{
|
||||
caf::AppEnum<RigFemResultPosEnum> resPosAppEnum = resultSlot->resultPositionType();
|
||||
caf::AppEnum<RigFemResultPosEnum> resPosAppEnum = resultColors->resultPositionType();
|
||||
resultInfoText->append(resPosAppEnum.uiText() + ", ");
|
||||
resultInfoText->append(resultSlot->resultFieldUiName()+ ", ") ;
|
||||
resultInfoText->append(resultSlot->resultComponentUiName() + ":\n");
|
||||
resultInfoText->append(resultColors->resultFieldUiName()+ ", ") ;
|
||||
resultInfoText->append(resultColors->resultComponentUiName() + ":\n");
|
||||
|
||||
|
||||
RigFemPart* femPart = geomData->femParts()->part(gridIndex);
|
||||
@ -183,7 +183,7 @@ void RiuFemResultTextBuilder::appendTextFromResultSlot(RigGeoMechCaseData* geomD
|
||||
|
||||
float scalarValue = std::numeric_limits<float>::infinity();
|
||||
int nodeIdx = elmentConn[lNodeIdx];
|
||||
if (resultSlot->resultPositionType() == RIG_NODAL)
|
||||
if (resultColors->resultPositionType() == RIG_NODAL)
|
||||
{
|
||||
|
||||
scalarValue = scalarResults[nodeIdx];
|
||||
@ -215,21 +215,21 @@ void RiuFemResultTextBuilder::appendDetails(QString& text, const QString& detail
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
QString RiuFemResultTextBuilder::closestNodeResultText(RimGeoMechCellColors* resultSlot)
|
||||
QString RiuFemResultTextBuilder::closestNodeResultText(RimGeoMechCellColors* resultColors)
|
||||
{
|
||||
QString text;
|
||||
if (!resultSlot)
|
||||
if (!resultColors)
|
||||
{
|
||||
return text;
|
||||
}
|
||||
|
||||
if (resultSlot->hasResult())
|
||||
if (resultColors->hasResult())
|
||||
{
|
||||
if (! (m_reservoirView->geoMechCase() && m_reservoirView->geoMechCase()->geoMechData())) return text;
|
||||
|
||||
RigGeoMechCaseData* geomData = m_reservoirView->geoMechCase()->geoMechData();
|
||||
|
||||
const std::vector<float>& scalarResults = geomData->femPartResults()->resultValues(resultSlot->resultAddress(), m_gridIndex, m_timeStepIndex);
|
||||
const std::vector<float>& scalarResults = geomData->femPartResults()->resultValues(resultColors->resultAddress(), m_gridIndex, m_timeStepIndex);
|
||||
if (scalarResults.size())
|
||||
{
|
||||
|
||||
@ -259,7 +259,7 @@ QString RiuFemResultTextBuilder::closestNodeResultText(RimGeoMechCellColors* res
|
||||
|
||||
float scalarValue = std::numeric_limits<float>::infinity();
|
||||
int nodeIdx = elmentConn[closestLocalNode];
|
||||
if (resultSlot->resultPositionType() == RIG_NODAL)
|
||||
if (resultColors->resultPositionType() == RIG_NODAL)
|
||||
{
|
||||
|
||||
scalarValue = scalarResults[nodeIdx];
|
||||
|
@ -53,9 +53,9 @@ private:
|
||||
|
||||
QString gridResultDetails();
|
||||
|
||||
QString closestNodeResultText(RimGeoMechCellColors* resultSlot);
|
||||
QString closestNodeResultText(RimGeoMechCellColors* resultColors);
|
||||
|
||||
void appendTextFromResultSlot(RigGeoMechCaseData* eclipseCase, int gridIndex, int cellIndex, int timeStepIndex, RimGeoMechCellColors* resultSlot, QString* resultInfoText);
|
||||
void appendTextFromResultColors(RigGeoMechCaseData* eclipseCase, int gridIndex, int cellIndex, int timeStepIndex, RimGeoMechCellColors* resultColors, QString* resultInfoText);
|
||||
|
||||
private:
|
||||
caf::PdmPointer<RimGeoMechView> m_reservoirView;
|
||||
|
@ -176,7 +176,7 @@ QString RiuResultTextBuilder::gridResultDetails()
|
||||
RigCaseData* eclipseCaseData = m_reservoirView->eclipseCase()->reservoirData();
|
||||
RigGridBase* grid = eclipseCaseData->grid(m_gridIndex);
|
||||
|
||||
this->appendTextFromResultSlot(eclipseCaseData, m_gridIndex, m_cellIndex, m_timeStepIndex, m_reservoirView->cellResult(), &text);
|
||||
this->appendTextFromResultColors(eclipseCaseData, m_gridIndex, m_cellIndex, m_timeStepIndex, m_reservoirView->cellResult(), &text);
|
||||
|
||||
if (!text.isEmpty())
|
||||
{
|
||||
@ -213,7 +213,7 @@ QString RiuResultTextBuilder::faultResultDetails()
|
||||
if (m_reservoirView->faultResultSettings()->hasValidCustomResult())
|
||||
{
|
||||
text += "Fault result data:\n";
|
||||
this->appendTextFromResultSlot(eclipseCaseData, m_gridIndex, m_cellIndex, m_timeStepIndex, m_reservoirView->currentFaultResultSlot(), &text);
|
||||
this->appendTextFromResultColors(eclipseCaseData, m_gridIndex, m_cellIndex, m_timeStepIndex, m_reservoirView->currentFaultResultColors(), &text);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -252,7 +252,7 @@ QString RiuResultTextBuilder::faultResultText()
|
||||
cvf::StructGridInterface::FaceEnum faceHelper(m_face);
|
||||
if (m_reservoirView->faultResultSettings()->hasValidCustomResult())
|
||||
{
|
||||
text = cellResultText(m_reservoirView->currentFaultResultSlot());
|
||||
text = cellResultText(m_reservoirView->currentFaultResultColors());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -285,13 +285,13 @@ QString RiuResultTextBuilder::nncResultText()
|
||||
const RigConnection& conn = nncData->connections()[m_nncIndex];
|
||||
cvf::StructGridInterface::FaceEnum face(conn.m_c1Face);
|
||||
|
||||
if (m_reservoirView->currentFaultResultSlot())
|
||||
if (m_reservoirView->currentFaultResultColors())
|
||||
{
|
||||
size_t scalarResultIdx = m_reservoirView->currentFaultResultSlot()->scalarResultIndex();
|
||||
size_t scalarResultIdx = m_reservoirView->currentFaultResultColors()->scalarResultIndex();
|
||||
const std::vector<double>* nncValues = nncData->connectionScalarResult(scalarResultIdx);
|
||||
if (nncValues)
|
||||
{
|
||||
QString resultVar = m_reservoirView->currentFaultResultSlot()->resultVariable();
|
||||
QString resultVar = m_reservoirView->currentFaultResultColors()->resultVariable();
|
||||
double scalarValue = (*nncValues)[m_nncIndex];
|
||||
|
||||
text = QString("%1 : %2").arg(resultVar).arg(scalarValue);
|
||||
@ -307,17 +307,17 @@ QString RiuResultTextBuilder::nncResultText()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuResultTextBuilder::appendTextFromResultSlot(RigCaseData* eclipseCase, size_t gridIndex, size_t cellIndex, size_t timeStepIndex, RimEclipseCellColors* resultSlot, QString* resultInfoText)
|
||||
void RiuResultTextBuilder::appendTextFromResultColors(RigCaseData* eclipseCase, size_t gridIndex, size_t cellIndex, size_t timeStepIndex, RimEclipseCellColors* resultColors, QString* resultInfoText)
|
||||
{
|
||||
if (!resultSlot)
|
||||
if (!resultColors)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultSlot->porosityModel());
|
||||
if (resultSlot->isTernarySaturationSelected())
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultColors->porosityModel());
|
||||
if (resultColors->isTernarySaturationSelected())
|
||||
{
|
||||
RimReservoirCellResultsStorage* gridCellResults = resultSlot->currentGridCellResults();
|
||||
RimReservoirCellResultsStorage* gridCellResults = resultColors->currentGridCellResults();
|
||||
if (gridCellResults)
|
||||
{
|
||||
size_t soilScalarSetIndex = gridCellResults->findOrLoadScalarResult(RimDefines::DYNAMIC_NATIVE, "SOIL");
|
||||
@ -343,14 +343,14 @@ void RiuResultTextBuilder::appendTextFromResultSlot(RigCaseData* eclipseCase, si
|
||||
resultInfoText->append(QString("SWAT : %1\n").arg(scalarValue));
|
||||
}
|
||||
}
|
||||
else if (resultSlot->hasResult())
|
||||
else if (resultColors->hasResult())
|
||||
{
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultSlot->porosityModel());
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultColors->porosityModel());
|
||||
cvf::ref<RigResultAccessor> resultAccessor;
|
||||
|
||||
if (resultSlot->hasStaticResult())
|
||||
if (resultColors->hasStaticResult())
|
||||
{
|
||||
if (resultSlot->resultVariable().compare(RimDefines::combinedTransmissibilityResultName(), Qt::CaseInsensitive) == 0)
|
||||
if (resultColors->resultVariable().compare(RimDefines::combinedTransmissibilityResultName(), Qt::CaseInsensitive) == 0)
|
||||
{
|
||||
cvf::ref<RigResultAccessor> transResultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, 0, RimDefines::combinedTransmissibilityResultName());
|
||||
{
|
||||
@ -364,7 +364,7 @@ void RiuResultTextBuilder::appendTextFromResultSlot(RigCaseData* eclipseCase, si
|
||||
resultInfoText->append(QString("Tran Z : %1\n").arg(scalarValue));
|
||||
}
|
||||
}
|
||||
else if (resultSlot->resultVariable().compare(RimDefines::combinedMultResultName(), Qt::CaseInsensitive) == 0)
|
||||
else if (resultColors->resultVariable().compare(RimDefines::combinedMultResultName(), Qt::CaseInsensitive) == 0)
|
||||
{
|
||||
cvf::ref<RigResultAccessor> multResultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, 0, RimDefines::combinedMultResultName());
|
||||
{
|
||||
@ -386,7 +386,7 @@ void RiuResultTextBuilder::appendTextFromResultSlot(RigCaseData* eclipseCase, si
|
||||
resultInfoText->append(QString("MULTZ- : %1\n").arg(scalarValue));
|
||||
}
|
||||
}
|
||||
else if (resultSlot->resultVariable().compare(RimDefines::combinedRiTranResultName(), Qt::CaseInsensitive) == 0)
|
||||
else if (resultColors->resultVariable().compare(RimDefines::combinedRiTranResultName(), Qt::CaseInsensitive) == 0)
|
||||
{
|
||||
cvf::ref<RigResultAccessor> transResultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, 0, RimDefines::combinedRiTranResultName());
|
||||
{
|
||||
@ -400,7 +400,7 @@ void RiuResultTextBuilder::appendTextFromResultSlot(RigCaseData* eclipseCase, si
|
||||
resultInfoText->append(QString("riTran Z : %1\n").arg(scalarValue));
|
||||
}
|
||||
}
|
||||
else if (resultSlot->resultVariable().compare(RimDefines::combinedRiMultResultName(), Qt::CaseInsensitive) == 0)
|
||||
else if (resultColors->resultVariable().compare(RimDefines::combinedRiMultResultName(), Qt::CaseInsensitive) == 0)
|
||||
{
|
||||
cvf::ref<RigResultAccessor> resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, 0, RimDefines::combinedRiMultResultName());
|
||||
{
|
||||
@ -414,7 +414,7 @@ void RiuResultTextBuilder::appendTextFromResultSlot(RigCaseData* eclipseCase, si
|
||||
resultInfoText->append(QString("riMult Z : %1\n").arg(scalarValue));
|
||||
}
|
||||
}
|
||||
else if (resultSlot->resultVariable().compare(RimDefines::combinedRiAreaNormTranResultName(), Qt::CaseInsensitive) == 0)
|
||||
else if (resultColors->resultVariable().compare(RimDefines::combinedRiAreaNormTranResultName(), Qt::CaseInsensitive) == 0)
|
||||
{
|
||||
cvf::ref<RigResultAccessor> resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, 0, RimDefines::combinedRiAreaNormTranResultName());
|
||||
{
|
||||
@ -430,19 +430,19 @@ void RiuResultTextBuilder::appendTextFromResultSlot(RigCaseData* eclipseCase, si
|
||||
}
|
||||
else
|
||||
{
|
||||
resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, 0, resultSlot->scalarResultIndex());
|
||||
resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, 0, resultColors->scalarResultIndex());
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, timeStepIndex, resultSlot->scalarResultIndex());
|
||||
resultAccessor = RigResultAccessorFactory::createResultAccessor(eclipseCase, gridIndex, porosityModel, timeStepIndex, resultColors->scalarResultIndex());
|
||||
}
|
||||
|
||||
if (resultAccessor.notNull())
|
||||
{
|
||||
double scalarValue = resultAccessor->cellScalar(cellIndex);
|
||||
resultInfoText->append("Cell result : ");
|
||||
resultInfoText->append(resultSlot->resultVariable());
|
||||
resultInfoText->append(resultColors->resultVariable());
|
||||
resultInfoText->append(QString(" : %1\n").arg(scalarValue));
|
||||
}
|
||||
}
|
||||
@ -574,7 +574,7 @@ void RiuResultTextBuilder::appendDetails(QString& text, const QString& details)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
QString RiuResultTextBuilder::cellResultText(RimEclipseCellColors* resultSlot)
|
||||
QString RiuResultTextBuilder::cellResultText(RimEclipseCellColors* resultColors)
|
||||
{
|
||||
QString text;
|
||||
|
||||
@ -583,11 +583,11 @@ QString RiuResultTextBuilder::cellResultText(RimEclipseCellColors* resultSlot)
|
||||
RigCaseData* eclipseCaseData = m_reservoirView->eclipseCase()->reservoirData();
|
||||
RigGridBase* grid = eclipseCaseData->grid(m_gridIndex);
|
||||
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultSlot->porosityModel());
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(resultColors->porosityModel());
|
||||
|
||||
QString resultVar = resultSlot->resultVariable();
|
||||
QString resultVar = resultColors->resultVariable();
|
||||
|
||||
if (resultSlot->isTernarySaturationSelected())
|
||||
if (resultColors->isTernarySaturationSelected())
|
||||
{
|
||||
RimReservoirCellResultsStorage* gridCellResults = m_reservoirView->cellResult()->currentGridCellResults();
|
||||
if (gridCellResults)
|
||||
|
@ -62,9 +62,9 @@ private:
|
||||
QString nncResultText();
|
||||
QString wellResultText();
|
||||
|
||||
QString cellResultText(RimEclipseCellColors* resultSlot);
|
||||
QString cellResultText(RimEclipseCellColors* resultColors);
|
||||
|
||||
void appendTextFromResultSlot(RigCaseData* eclipseCase, size_t gridIndex, size_t cellIndex, size_t timeStepIndex, RimEclipseCellColors* resultSlot, QString* resultInfoText);
|
||||
void appendTextFromResultColors(RigCaseData* eclipseCase, size_t gridIndex, size_t cellIndex, size_t timeStepIndex, RimEclipseCellColors* resultColors, QString* resultInfoText);
|
||||
|
||||
private:
|
||||
caf::PdmPointer<RimEclipseView> m_reservoirView;
|
||||
|
Loading…
Reference in New Issue
Block a user