Logging improvements to allow prettier displays in the server GUI.
[dcpomatic.git] / src / lib / frame_rate_change.h
index 6165f684010473e59f458d61ac656eb222ec23e5..3df9225b7f2ded99b3ff55e1e123716dd55defdd 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2012-2015 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+#ifndef DCPOMATIC_FRAME_RATE_CHANGE_H
+#define DCPOMATIC_FRAME_RATE_CHANGE_H
+
 #include <string>
 
 struct FrameRateChange
 {
-       FrameRateChange (float, int);
+       FrameRateChange (double, int);
 
        /** @return factor by which to multiply a source frame rate
            to get the effective rate after any skip or repeat has happened.
        */
-       float factor () const {
+       double factor () const {
                if (skip) {
                        return 0.5;
                }
@@ -34,6 +37,9 @@ struct FrameRateChange
                return repeat;
        }
 
+       double source;
+       int dcp;
+
        /** true to skip every other frame */
        bool skip;
        /** number of times to use each frame (e.g. 1 is normal, 2 means repeat each frame once, and so on) */
@@ -52,7 +58,9 @@ struct FrameRateChange
        /** Amount by which the video is being sped-up in the DCP; e.g. for a
         *  24fps source in a 25fps DCP this would be 25/24.
         */
-       float speed_up;
+       double speed_up;
 
-       std::string description;
+       std::string description () const;
 };
+
+#endif