fixed Vis timestamp issue

This commit is contained in:
kazu
2016-05-03 11:47:04 +02:00
parent 1e8f4259a2
commit 5bde96df3a
2 changed files with 8 additions and 1 deletions

View File

@@ -138,11 +138,17 @@ public:
} }
} }
uint64_t firstTs = 0;
void setTimestamp(uint64_t ts) { void setTimestamp(uint64_t ts) {
static uint64_t firstTs = ts; if (firstTs == 0) {firstTs = ts;}
//static uint64_t firstTs = ts;
gp << "set label 1 \"" << ((ts-firstTs)/1000.0f) << "\" at screen 0.02,0.98\n"; gp << "set label 1 \"" << ((ts-firstTs)/1000.0f) << "\" at screen 0.02,0.98\n";
} }
void resetTimestamp() {
firstTs = 0;
}
void setFilteringMedian(double median){ void setFilteringMedian(double median){
gp << "set label 2 \"" << median << "\" at screen 0.02,0.90\n"; gp << "set label 2 \"" << median << "\" at screen 0.02,0.90\n";
} }

View File

@@ -363,6 +363,7 @@ public:
//std::ofstream statsout2("/tmp/smoothed_" + runName + ".stats"); //std::ofstream statsout2("/tmp/smoothed_" + runName + ".stats");
//stats.reset(); //stats.reset();
bf->reset(); bf->reset();
vis.resetTimestamp();
MyState estBF; MyState estBF;