summaryrefslogtreecommitdiff
path: root/src/cpl.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2012-07-30 23:47:57 +0100
committerCarl Hetherington <cth@carlh.net>2012-07-30 23:47:57 +0100
commit9a9d4e014c16be88d72914a9480343445bc785a5 (patch)
tree1857fcdd8963d51ac50f1467d9ae81d4d9be5f8e /src/cpl.h
parent34a25d89b16a33b5f619ae0eaaa03c17f93980af (diff)
Various.
Diffstat (limited to 'src/cpl.h')
-rw-r--r--src/cpl.h85
1 files changed, 84 insertions, 1 deletions
diff --git a/src/cpl.h b/src/cpl.h
index 6ec55e61..643a243b 100644
--- a/src/cpl.h
+++ b/src/cpl.h
@@ -1,8 +1,91 @@
+#include <boost/shared_ptr.hpp>
#include "xml.h"
-class CPL : public XML
+namespace libdcp {
+
+class MainPicture : public XMLNode
+{
+public:
+ MainPicture () {}
+ MainPicture (xmlpp::Node const * node);
+
+ std::string id;
+ std::string annotation_text;
+ Fraction edit_rate;
+ int intrinsic_duration;
+ int entry_point;
+ int duration;
+ Fraction frame_rate;
+ Fraction screen_aspect_ratio;
+};
+
+class MainSound : public XMLNode
+{
+public:
+ MainSound () {}
+ MainSound (xmlpp::Node const * node);
+
+ std::string id;
+ std::string annotation_text;
+ Fraction edit_rate;
+ int intrinsic_duration;
+ int entry_point;
+ int duration;
+};
+
+class CPLAssetList : public XMLNode
+{
+public:
+ CPLAssetList () {}
+ CPLAssetList (xmlpp::Node const * node);
+
+ boost::shared_ptr<MainPicture> main_picture;
+ boost::shared_ptr<MainSound> main_sound;
+};
+
+class Reel : public XMLNode
+{
+public:
+ Reel () {}
+ Reel (xmlpp::Node const * node);
+
+ std::string id;
+ boost::shared_ptr<CPLAssetList> asset_list;
+};
+
+class ReelList : public XMLNode
+{
+public:
+ ReelList () {}
+ ReelList (xmlpp::Node const * node);
+
+ std::list<boost::shared_ptr<Reel> > reels;
+};
+
+class ContentVersion : public XMLNode
+{
+public:
+ ContentVersion () {}
+ ContentVersion (xmlpp::Node const * node);
+
+ std::string id;
+ std::string label_text;
+};
+
+class CPL : public XMLFile
{
public:
CPL (std::string file);
+ std::string id;
+ std::string annotation_text;
+ std::string issue_date;
+ std::string creator;
+ std::string content_title_text;
+ std::string content_kind;
+ boost::shared_ptr<ContentVersion> content_version;
+ boost::shared_ptr<ReelList> reel_list;
};
+
+}
+