#13392 Summary Plot: Wrong values for "Time From Simulation Start"

The ensemble curve values are cached for performance reasons. Include the time settings in the hash function used to control the cache. This will make sure that the curve values are recreated when the time setting changes.
This commit is contained in:
Magne Sjaastad committed 2026-01-15 12:15:35 +01:00
1 parent 5bb431ef33
commit 2d4df3abf4
1 file changed
+11 -3
@@ -53,6 +53,7 @@
#include "RimSummaryEnsemble.h"
#include "RimSummaryMultiPlot.h"
#include "RimSummaryPlot.h"
#include "RimSummaryTimeAxisProperties.h"
#include "RimTimeAxisAnnotation.h"
#include "RimTimeStepFilter.h"
@@ -2119,9 +2120,16 @@ void RimEnsembleCurveSet::updateEnsembleCurves( const std::vector<RimSummaryCase
auto plot = firstAncestorOrThisOfTypeAsserted<RimSummaryPlot>();
auto yAddressText = m_yValuesSummaryAddress()->address().toEclipseTextAddress();
auto xAddressText = m_xAddressSelector->summaryAddress().toEclipseTextAddress();
auto newRealizationHash = RiaHashTools::hash( sumCases, yAddressText, xAddressText );
auto yAddressText = m_yValuesSummaryAddress()->address().toEclipseTextAddress();
auto xAddressText = m_xAddressSelector->summaryAddress().toEclipseTextAddress();
int timeMode = 0;
auto timeScale = 0.0;
if ( auto timeAxisProps = plot->timeAxisProperties() )
{
timeMode = std::to_underlying( timeAxisProps->timeMode() );
timeScale = timeAxisProps->fromTimeTToDisplayUnitScale();
}
auto newRealizationHash = RiaHashTools::hash( sumCases, yAddressText, xAddressText, timeMode, timeScale );
if ( newRealizationHash != m_realizationHash )
{
deleteEnsembleCurves();