summaryrefslogtreecommitdiff
path: root/lib/timestamp.cpp
blob: 112a7d1d126a92a6d116620091e3b278396bb69b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include "timestamp.h"

#include <time.h>
#include <iostream>
#include <chrono>

double amb::currentTime()
{
	auto tm = std::chrono::steady_clock::now();

	double time = std::chrono::duration_cast<std::chrono::milliseconds>(tm.time_since_epoch()).count() / 1000.00;

	return time;
}