36 #define SUMOTime_MAX std::numeric_limits<SUMOTime>::max() 37 #define SUMOTime_MIN std::numeric_limits<SUMOTime>::min() 38 #define SUMOTIME_MAXSTRING "9223372036854774" // SUMOTime_MAX / 1000 - 1 (because of rounding errors) 44 #define TS (static_cast<double>(DELTA_T/1000.)) 47 #define SPEED2DIST(x) ((x)*TS) 49 #define DIST2SPEED(x) ((x)/TS) 51 #define ACCEL2DIST(x) ((x)*TS*TS) 53 #define ACCEL2SPEED(x) ((x)*TS) 55 #define SPEED2ACCEL(x) ((x)/TS) 57 #define STEPS2TIME(x) (static_cast<double>((x)/1000.)) 59 #define TIME2STEPS(x) (static_cast<SUMOTime>((x)*1000 + ((x) >= 0 ? 0.5 : -0.5))) 60 #define STEPFLOOR(x) (int(x/DELTA_T)*DELTA_T) 61 #define STEPS2MS(x) (x) 63 #define SIMSTEP MSNet::getInstance()->getCurrentTimeStep() 64 #define SIMTIME STEPS2TIME(MSNet::getInstance()->getCurrentTimeStep())
std::string time2string(SUMOTime t)
SUMOTime string2time(const std::string &r)