mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Show ternary info in result info by picking on cells
This commit is contained in:
parent
d10177494e
commit
79b523522d
@ -140,6 +140,11 @@ void Rim3dOverlayInfoConfig::update3DInfo()
|
||||
"<b>Cell count. Total:</b> %2 <b>Active:</b> %3 <br>"
|
||||
"<b>Main Grid I,J,K:</b> %4, %5, %6 <b>Z-Scale:</b> %7<br>").arg(caseName, totCellCount, activeCellCountText, iSize, jSize, kSize, zScale);
|
||||
|
||||
if (m_reservoirView->cellResult()->isTernarySaturationSelected())
|
||||
{
|
||||
infoText += QString("<b>Cell Property:</b> %1 ").arg(propName);
|
||||
}
|
||||
|
||||
if (m_reservoirView->animationMode() && m_reservoirView->cellResult()->hasResult())
|
||||
{
|
||||
infoText += QString("<b>Cell Property:</b> %1 ").arg(propName);
|
||||
@ -196,7 +201,8 @@ void Rim3dOverlayInfoConfig::update3DInfo()
|
||||
|
||||
if ( m_reservoirView->cellResult()->hasDynamicResult()
|
||||
|| m_reservoirView->propertyFilterCollection()->hasActiveDynamicFilters()
|
||||
|| m_reservoirView->wellCollection()->hasVisibleWellPipes())
|
||||
|| m_reservoirView->wellCollection()->hasVisibleWellPipes()
|
||||
|| m_reservoirView->cellResult()->isTernarySaturationSelected())
|
||||
{
|
||||
int currentTimeStep = m_reservoirView->currentTimeStep();
|
||||
QDateTime date = m_reservoirView->currentGridCellResults()->cellResults()->timeStepDate(0, currentTimeStep);
|
||||
|
@ -1107,7 +1107,38 @@ void RimReservoirView::appendCellResultInfo(size_t gridIndex, size_t cellIndex,
|
||||
RigCaseData* eclipseCase = m_reservoir->reservoirData();
|
||||
RigGridBase* grid = eclipseCase->grid(gridIndex);
|
||||
|
||||
if (this->cellResult()->hasResult())
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResult()->porosityModel());
|
||||
cvf::ref<cvf::StructGridScalarDataAccess> dataAccessObject;
|
||||
|
||||
if (this->cellResult()->isTernarySaturationSelected())
|
||||
{
|
||||
RimReservoirCellResultsStorage* gridCellResults = this->cellResult()->currentGridCellResults();
|
||||
if (gridCellResults)
|
||||
{
|
||||
size_t soilScalarSetIndex = gridCellResults->findOrLoadScalarResult(RimDefines::DYNAMIC_NATIVE, "SOIL");
|
||||
size_t sgasScalarSetIndex = gridCellResults->findOrLoadScalarResult(RimDefines::DYNAMIC_NATIVE, "SGAS");
|
||||
size_t swatScalarSetIndex = gridCellResults->findOrLoadScalarResult(RimDefines::DYNAMIC_NATIVE, "SWAT");
|
||||
|
||||
cvf::ref<cvf::StructGridScalarDataAccess> dataAccessObjectX = eclipseCase->dataAccessObject(grid, porosityModel, 0, soilScalarSetIndex);
|
||||
cvf::ref<cvf::StructGridScalarDataAccess> dataAccessObjectY = eclipseCase->dataAccessObject(grid, porosityModel, 0, sgasScalarSetIndex);
|
||||
cvf::ref<cvf::StructGridScalarDataAccess> dataAccessObjectZ = eclipseCase->dataAccessObject(grid, porosityModel, 0, swatScalarSetIndex);
|
||||
|
||||
double scalarValue = 0.0;
|
||||
|
||||
if (dataAccessObjectX.notNull()) scalarValue = dataAccessObjectX->cellScalar(cellIndex);
|
||||
else scalarValue = 0.0;
|
||||
resultInfoText->append(QString("SOIL : %1\n").arg(scalarValue));
|
||||
|
||||
if (dataAccessObjectY.notNull()) scalarValue = dataAccessObjectY->cellScalar(cellIndex);
|
||||
else scalarValue = 0.0;
|
||||
resultInfoText->append(QString("SGAS : %1\n").arg(scalarValue));
|
||||
|
||||
if (dataAccessObjectZ.notNull()) scalarValue = dataAccessObjectZ->cellScalar(cellIndex);
|
||||
else scalarValue = 0.0;
|
||||
resultInfoText->append(QString("SWAT : %1\n").arg(scalarValue));
|
||||
}
|
||||
}
|
||||
else if (this->cellResult()->hasResult())
|
||||
{
|
||||
RifReaderInterface::PorosityModelResultType porosityModel = RigCaseCellResultsData::convertFromProjectModelPorosityModel(cellResult()->porosityModel());
|
||||
cvf::ref<cvf::StructGridScalarDataAccess> dataAccessObject;
|
||||
|
Loading…
Reference in New Issue
Block a user