Give a better reason for not referencing when there is a 2K/4K mismatch.
[dcpomatic.git] / src / lib / dcpomatic_time.h
index 204af3c1eb4cc6df8fbae1c290f9b98577f1e2ab..c687569ecb0dac578809d0ae9294ccaf607960ad 100644 (file)
@@ -125,6 +125,10 @@ public:
                return Time<S, O> (llrint (HZ * frames_floor(r) / r));
        }
 
+       Time<S, O> round (double r) const {
+               return Time<S, O> (llrint (HZ * frames_round(r) / r));
+       }
+
        double seconds () const {
                return double (_t) / HZ;
        }
@@ -217,12 +221,13 @@ public:
                return Time<S, O> (INT64_MAX);
        }
 
+       static const int HZ = 96000;
+
 private:
        friend struct dcpomatic_time_ceil_test;
        friend struct dcpomatic_time_floor_test;
 
        Type _t;
-       static const int HZ = 96000;
 };
 
 class ContentTimeDifferentiator {};