diff options
| author | Carl Hetherington <cth@carlh.net> | 2013-03-02 19:16:25 +0000 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2013-03-02 19:16:25 +0000 |
| commit | 99d2e172f5c7fae21e5126a063014727871e9948 (patch) | |
| tree | 1d796a5c0dd91c9d44cb0e360c8668a9b3acc29d /src/lib/format.h | |
| parent | 53eb16342d492236aca77e4b73c0911a5d5eec9f (diff) | |
Add similar format description,
Diffstat (limited to 'src/lib/format.h')
| -rw-r--r-- | src/lib/format.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/lib/format.h b/src/lib/format.h index 783ff25ce..305524628 100644 --- a/src/lib/format.h +++ b/src/lib/format.h @@ -31,11 +31,12 @@ class Film; class Format { public: - Format (libdcp::Size dcp, std::string id, std::string n, std::string d) + Format (libdcp::Size dcp, std::string id, std::string n, std::string d, std::string e) : _dcp_size (dcp) , _id (id) , _nickname (n) , _dci_name (d) + , _description (e) {} /** @return the aspect ratio multiplied by 100 @@ -75,6 +76,10 @@ public: return _dci_name; } + std::string description () const { + return _description; + } + std::string as_metadata () const; static Format const * from_nickname (std::string n); @@ -94,6 +99,7 @@ protected: /** nickname (e.g. Flat, Scope) */ std::string _nickname; std::string _dci_name; + std::string _description; private: /** all available formats */ @@ -107,7 +113,7 @@ private: class FixedFormat : public Format { public: - FixedFormat (int, libdcp::Size, std::string, std::string, std::string); + FixedFormat (int, libdcp::Size, std::string, std::string, std::string, std::string); int ratio_as_integer (boost::shared_ptr<const Film>) const { return _ratio; @@ -128,7 +134,7 @@ private: class VariableFormat : public Format { public: - VariableFormat (libdcp::Size, std::string, std::string, std::string); + VariableFormat (libdcp::Size, std::string, std::string, std::string, std::string); int ratio_as_integer (boost::shared_ptr<const Film> f) const; float ratio_as_float (boost::shared_ptr<const Film> f) const; |
