From 4f7636694a752fa8c652c684a3c9ebf1488ceaa4 Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Wed, 17 Jan 2018 10:25:20 +0100 Subject: Cosmetics for TimestampDecoder --- src/TimestampDecoder.h | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) (limited to 'src/TimestampDecoder.h') diff --git a/src/TimestampDecoder.h b/src/TimestampDecoder.h index ff52e4c..1a13394 100644 --- a/src/TimestampDecoder.h +++ b/src/TimestampDecoder.h @@ -26,14 +26,11 @@ #pragma once -#include +#include #include #include -#include #include #include -#include "Eti.h" -#include "Log.h" #include "RemoteControl.h" struct frame_timestamp @@ -55,16 +52,14 @@ struct frame_timestamp this->timestamp_sec += lrintf(offset_secs); this->timestamp_pps += lrintf(offset_pps * 16384000.0); - while (this->timestamp_pps >= 16384000) - { + while (this->timestamp_pps >= 16384000) { this->timestamp_pps -= 16384000; this->timestamp_sec += 1; - }; + } return *this; } - const frame_timestamp operator+(const double diff) - { + const frame_timestamp operator+(const double diff) { frame_timestamp ts = *this; ts += diff; return ts; @@ -86,8 +81,7 @@ struct frame_timestamp return ns; } - void print(const char* t) - { + void print(const char* t) const { fprintf(stderr, "%s \n", t, this->timestamp_valid ? "valid" : "invalid", -- cgit v1.2.3