Hey guys,
I want to change data of a graph, when new measurement data is ready. The data will be displayed from start of the graph to the end and then data on the start will be replaced by new data. Until now I use QVector
to change the data and then I use plot->graph(0)->setData(v1,v2)
. I only have to replace the value, not the key of the graph. I tried to get access to the QCPDataMap
of the graph, but without doing dirty hacks like const_cast
... it won't work.
So is there another way of getting access to the stored data in the graph, without even passing the whole data again to it?