X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Ftypes.h;h=dafea92f83948faba000c4391be42b169aaecf7a;hb=2e504b33eb9f38cac629ad31b7c107fb0cf5efda;hp=d4d66387d0c5c17c08183b1f04aecfe6ce2cebff;hpb=45f9912aa850546e319e32a4052517d67f4e3d8f;p=dcpomatic.git diff --git a/src/lib/types.h b/src/lib/types.h index d4d66387d..dafea92f8 100644 --- a/src/lib/types.h +++ b/src/lib/types.h @@ -23,9 +23,14 @@ #include #include #include -#include +#include +#include "dcpomatic_time.h" class Content; +class VideoContent; +class AudioContent; +class SubtitleContent; +class FFmpegContent; class AudioBuffers; /** The version number of the protocol used to communicate @@ -34,33 +39,32 @@ class AudioBuffers; */ #define SERVER_LINK_VERSION 1 -typedef int64_t Time; -#define TIME_MAX INT64_MAX -#define TIME_HZ ((Time) 96000) -typedef int64_t OutputAudioFrame; -typedef int OutputVideoFrame; typedef std::vector > ContentList; +typedef std::vector > VideoContentList; +typedef std::vector > AudioContentList; +typedef std::vector > SubtitleContentList; +typedef std::vector > FFmpegContentList; -template struct TimedAudioBuffers { TimedAudioBuffers () : time (0) {} - TimedAudioBuffers (boost::shared_ptr a, T t) + TimedAudioBuffers (boost::shared_ptr a, DCPTime t) : audio (a) , time (t) {} boost::shared_ptr audio; - T time; + DCPTime time; }; enum VideoFrameType { VIDEO_FRAME_TYPE_2D, - VIDEO_FRAME_TYPE_3D_LEFT_RIGHT + VIDEO_FRAME_TYPE_3D_LEFT_RIGHT, + VIDEO_FRAME_TYPE_3D_TOP_BOTTOM }; enum Eyes @@ -88,7 +92,7 @@ struct Crop /** Number of pixels to remove from the bottom */ int bottom; - libdcp::Size apply (libdcp::Size s, int minimum = 4) const { + dcp::Size apply (dcp::Size s, int minimum = 4) const { s.width -= left + right; s.height -= top + bottom;