Added "unixoffset" field to stream info JSON, containing the offset between unix time (in milliseconds) and stream timestamps.

This commit is contained in:
Thulinma 2021-04-07 15:43:44 +02:00
parent 586c4ab47b
commit 3f6e1c8768

View file

@ -487,6 +487,9 @@ namespace Mist{
json_resp["height"] = (hasVideo ? 480 : 20);
}
json_resp["type"] = (M.getVod() ? "vod" : "live");
if (M.getLive()){
json_resp["unixoffset"] = M.getBootMsOffset() + (Util::unixMS() - Util::bootMS());
}
// show ALL the meta datas!
M.toJSON(json_resp["meta"], true);