#1948 PLT plot. Support for stacked curve grouping

This commit is contained in:
Bjørn Erik Jensen
2017-10-27 15:17:24 +02:00
parent 7dd42d2da4
commit 0c6fd31e07
6 changed files with 59 additions and 17 deletions

View File

@@ -87,6 +87,22 @@ QString RimWellFlowRateCurve::wellLogChannelName() const
return "AccumulatedFlowRate";
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RimWellFlowRateCurve::setGroupId(int groupId)
{
m_groupId = groupId;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
int RimWellFlowRateCurve::groupId() const
{
return m_groupId;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
@@ -181,7 +197,13 @@ void RimWellFlowRateCurve::updateStackedPlotData()
std::vector< std::pair<size_t, size_t> > polyLineStartStopIndices = m_curveData->polylineStartStopIndices();
std::vector<double> stackedValues(depthValues.size(), 0.0);
std::vector<RimWellFlowRateCurve*> stackedCurves = wellLogTrack->visibleStackedCurves();
std::map<int, std::vector<RimWellFlowRateCurve*>> stackedCurveGroups = wellLogTrack->visibleStackedCurves();
std::vector<RimWellFlowRateCurve*> stackedCurves;
if (stackedCurveGroups.count(groupId()) > 0)
{
stackedCurves = stackedCurveGroups[groupId()];
}
double zPos = -0.1;
for ( RimWellFlowRateCurve * stCurve: stackedCurves )
{