X-Git-Url: https://git.carlh.net/gitweb/?p=dcpomatic.git;a=blobdiff_plain;f=src%2Flib%2Ftypes.h;fp=src%2Flib%2Ftypes.h;h=e858d1e1feb6b7827ce09d79822e5817b4fa3df0;hp=35c7a91f9785865e1dada8d2449fa725f4149ae4;hb=39bc73fe192f932ed6695eb87b19de446e8b4f55;hpb=bb0a36c3a6bea9cd1ebdde7b8a3a04765e317569 diff --git a/src/lib/types.h b/src/lib/types.h index 35c7a91f9..e858d1e1f 100644 --- a/src/lib/types.h +++ b/src/lib/types.h @@ -34,11 +34,19 @@ class SubtitleContent; class FFmpegContent; class AudioBuffers; +namespace cxml { + class Node; +} + +namespace xmlpp { + class Node; +} + /** The version number of the protocol used to communicate * with servers. Intended to be bumped when incompatibilities * are introduced. */ -#define SERVER_LINK_VERSION 1 +#define SERVER_LINK_VERSION 2 typedef std::vector > ContentList; typedef std::vector > VideoContentList; @@ -85,6 +93,15 @@ enum Eyes EYES_COUNT }; +enum Part +{ + PART_LEFT_HALF, + PART_RIGHT_HALF, + PART_TOP_HALF, + PART_BOTTOM_HALF, + PART_WHOLE +}; + /** @struct Crop * @brief A description of the crop of an image or video. */ @@ -92,6 +109,7 @@ struct Crop { Crop () : left (0), right (0), top (0), bottom (0) {} Crop (int l, int r, int t, int b) : left (l), right (r), top (t), bottom (b) {} + Crop (boost::shared_ptr); /** Number of pixels to remove from the left-hand side */ int left; @@ -116,6 +134,8 @@ struct Crop return s; } + + void as_xml (xmlpp::Node *) const; }; extern bool operator== (Crop const & a, Crop const & b);