2 Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or
7 (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
26 #include <libxml++/libxml++.h>
27 #include <boost/shared_ptr.hpp>
28 #include <boost/function.hpp>
39 class ReelPictureAsset;
41 class ReelSubtitleAsset;
44 /** @brief A reel within a DCP; the part which actually refers to picture, sound and subtitle data */
45 class Reel : public Object
51 boost::shared_ptr<ReelPictureAsset> picture,
52 boost::shared_ptr<ReelSoundAsset> sound,
53 boost::shared_ptr<ReelSubtitleAsset> subtitle
55 : _main_picture (picture)
57 , _main_subtitle (subtitle)
60 Reel (boost::shared_ptr<const cxml::Node>);
62 boost::shared_ptr<ReelPictureAsset> main_picture () const {
66 boost::shared_ptr<ReelSoundAsset> main_sound () const {
70 boost::shared_ptr<ReelSubtitleAsset> main_subtitle () const {
71 return _main_subtitle;
74 void add (boost::shared_ptr<ReelAsset> asset);
76 void write_to_cpl (xmlpp::Element* node, Standard standard) const;
78 bool encrypted () const;
80 bool equals (boost::shared_ptr<const Reel> other, EqualityOptions opt, NoteHandler notes) const;
82 void add (DecryptedKDM const &);
84 void resolve_refs (std::list<boost::shared_ptr<Object> >);
87 boost::shared_ptr<ReelPictureAsset> _main_picture;
88 boost::shared_ptr<ReelSoundAsset> _main_sound;
89 boost::shared_ptr<ReelSubtitleAsset> _main_subtitle;