mirror of
https://github.com/OPM/ResInsight.git
synced 2025-01-09 23:53:04 -06:00
#2192 RelPerm Plot: Utilize new functionality in opm-flowdiagnostics-applications to show the pressure in case-units
This commit is contained in:
parent
5641ecc1c2
commit
56febb9e92
@ -135,21 +135,29 @@ public:
|
||||
try
|
||||
{
|
||||
m_eclPvtCurveCollection.reset(new Opm::ECLPVT::ECLPvtCurveCollection(*m_eclGraph, initData));
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
RiaLogging::warning("Unsupported PVT table format. Could not initialize PVT plotting functionality.");
|
||||
}
|
||||
|
||||
// Try and set output unit system to the same system as the eclipse case system
|
||||
std::unique_ptr<const Opm::ECLUnits::UnitSystem> eclUnitSystem;
|
||||
if (caseUnitSystem == RiaEclipseUnitTools::UNITS_METRIC) eclUnitSystem = Opm::ECLUnits::metricUnitConventions();
|
||||
else if (caseUnitSystem == RiaEclipseUnitTools::UNITS_FIELD) eclUnitSystem = Opm::ECLUnits::fieldUnitConventions();
|
||||
else if (caseUnitSystem == RiaEclipseUnitTools::UNITS_LAB) eclUnitSystem = Opm::ECLUnits::labUnitConventions();
|
||||
|
||||
if (eclUnitSystem)
|
||||
{
|
||||
if (m_eclSaturationFunc)
|
||||
{
|
||||
m_eclSaturationFunc->setOutputUnits(eclUnitSystem->clone());
|
||||
}
|
||||
if (m_eclPvtCurveCollection)
|
||||
{
|
||||
m_eclPvtCurveCollection->setOutputUnits(eclUnitSystem->clone());
|
||||
}
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
RiaLogging::warning("Unsupported PVT table format. Could not initialize PVT plotting functionality.");
|
||||
}
|
||||
}
|
||||
|
||||
public:
|
||||
|
Loading…
Reference in New Issue
Block a user