many changes
This commit is contained in:
@@ -19,6 +19,7 @@ class PlotErrFunc {
|
||||
};
|
||||
|
||||
std::vector<Entry> entries;
|
||||
std::vector<K::GnuplotPlotElementLines*> lines;
|
||||
|
||||
K::Gnuplot gp;
|
||||
K::GnuplotPlot gplot;
|
||||
@@ -39,6 +40,15 @@ public:
|
||||
/** add one curve */
|
||||
void add(const std::string name, const K::Statistics<float> stats) {
|
||||
entries.push_back(Entry(name, stats));
|
||||
K::GnuplotPlotElementLines* gpel = new K::GnuplotPlotElementLines();
|
||||
gpel->setTitle(name);
|
||||
gpel->setLineWidth(2);
|
||||
lines.push_back(gpel);
|
||||
gplot.add(gpel);
|
||||
}
|
||||
|
||||
void clear() {
|
||||
entries.clear();
|
||||
}
|
||||
|
||||
K::Gnuplot& getGP() {
|
||||
@@ -57,12 +67,11 @@ public:
|
||||
for (size_t i = 0; i < entries.size(); ++i) {
|
||||
|
||||
const Entry e = entries[i];
|
||||
K::GnuplotPlotElementLines* line = lines[i];
|
||||
|
||||
K::GnuplotPlotElementLines* line = new K::GnuplotPlotElementLines();
|
||||
line->setTitle(e.name);
|
||||
line->clear();
|
||||
//line.setTitle(e.name);
|
||||
line->setColorHex(colors[i]);
|
||||
line->setLineWidth(2);
|
||||
gplot.add(line);
|
||||
|
||||
// 0 - 80%
|
||||
for (int i = 0; i <= 85; i+= 5) {
|
||||
@@ -83,7 +92,6 @@ public:
|
||||
}
|
||||
|
||||
gp.flush();
|
||||
gp.close();
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user