started with eval
This commit is contained in:
29
Helper.h
Normal file
29
Helper.h
Normal file
@@ -0,0 +1,29 @@
|
||||
#ifndef LEHELPER_H
|
||||
#define LEHELPER_H
|
||||
|
||||
#include <fstream>
|
||||
#include <Indoor/geo/EarthPos.h>
|
||||
|
||||
class LeHelper {
|
||||
|
||||
public:
|
||||
|
||||
static void writeGoogleLine(std::vector<EarthPos>& poss) {
|
||||
const std::string file = "/apps/android/workspace/OTHER2017/osm/googleLine.js";
|
||||
std::ofstream out(file);
|
||||
out << "function getLines() {return [\n";
|
||||
out.precision(15);
|
||||
|
||||
for (const EarthPos& pos : poss) {
|
||||
out << "\t{" << "lat:" << pos.lat << ", lng:" << pos.lon << "},\n";
|
||||
}
|
||||
|
||||
out << "];}";
|
||||
out.flush();
|
||||
out.close();
|
||||
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
#endif // HELPER_H
|
||||
Reference in New Issue
Block a user