Remove unnecessary Film variable in ContentPart.
authorCarl Hetherington <cth@carlh.net>
Fri, 13 May 2016 13:43:27 +0000 (14:43 +0100)
committerCarl Hetherington <cth@carlh.net>
Wed, 18 May 2016 10:50:29 +0000 (11:50 +0100)
16 files changed:
src/lib/audio_content.cc
src/lib/audio_content.h
src/lib/content_part.h
src/lib/dcp_content.cc
src/lib/dcp_subtitle_content.cc
src/lib/ffmpeg_content.cc
src/lib/image_content.cc
src/lib/sndfile_content.cc
src/lib/subtitle_content.cc
src/lib/subtitle_content.h
src/lib/text_subtitle_content.cc
src/lib/video_content.cc
src/lib/video_content.h
test/audio_decoder_test.cc
test/data
test/ffmpeg_pts_offset_test.cc

index 540279a95b862e980d66d00f664ac8d48bd79b72..6cce9536e4170f05446fa5765ce28f593f232335 100644 (file)
@@ -48,8 +48,8 @@ int const AudioContentProperty::STREAMS = 200;
 int const AudioContentProperty::GAIN = 201;
 int const AudioContentProperty::DELAY = 202;
 
-AudioContent::AudioContent (Content* parent, shared_ptr<const Film> film)
-       : ContentPart (parent, film)
+AudioContent::AudioContent (Content* parent)
+       : ContentPart (parent)
        , _gain (0)
        , _delay (Config::instance()->default_audio_delay ())
 {
@@ -57,17 +57,17 @@ AudioContent::AudioContent (Content* parent, shared_ptr<const Film> film)
 }
 
 shared_ptr<AudioContent>
-AudioContent::from_xml (Content* parent, shared_ptr<const Film> film, cxml::ConstNodePtr node)
+AudioContent::from_xml (Content* parent, cxml::ConstNodePtr node)
 {
        if (!node->optional_number_child<double> ("AudioGain")) {
                return shared_ptr<AudioContent> ();
        }
 
-       return shared_ptr<AudioContent> (new AudioContent (parent, film, node));
+       return shared_ptr<AudioContent> (new AudioContent (parent, node));
 }
 
-AudioContent::AudioContent (Content* parent, shared_ptr<const Film> film, cxml::ConstNodePtr node)
-       : ContentPart (parent, film)
+AudioContent::AudioContent (Content* parent, cxml::ConstNodePtr node)
+       : ContentPart (parent)
 {
        _gain = node->number_child<double> ("AudioGain");
        _delay = node->number_child<int> ("AudioDelay");
@@ -79,8 +79,8 @@ AudioContent::AudioContent (Content* parent, shared_ptr<const Film> film, cxml::
        }
 }
 
-AudioContent::AudioContent (Content* parent, shared_ptr<const Film> film, vector<shared_ptr<Content> > c)
-       : ContentPart (parent, film)
+AudioContent::AudioContent (Content* parent, vector<shared_ptr<Content> > c)
+       : ContentPart (parent)
 {
        shared_ptr<AudioContent> ref = c[0]->audio;
        DCPOMATIC_ASSERT (ref);
@@ -187,9 +187,7 @@ AudioContent::resampled_frame_rate () const
        /* Resample to a DCI-approved sample rate */
        double t = has_rate_above_48k() ? 96000 : 48000;
 
-       shared_ptr<const Film> film = _film.lock ();
-       DCPOMATIC_ASSERT (film);
-       FrameRateChange frc (_parent->active_video_frame_rate(), film->video_frame_rate());
+       FrameRateChange frc (_parent->active_video_frame_rate(), _parent->film()->video_frame_rate());
 
        /* Compensate if the DCP is being run at a different frame rate
           to the source; that is, if the video is run such that it will
@@ -297,10 +295,7 @@ AudioContent::add_properties (list<UserProperty>& p) const
                p.push_back (UserProperty (_("Audio"), _("Content audio frame rate"), stream->frame_rate(), _("Hz")));
        }
 
-       shared_ptr<const Film> film = _film.lock ();
-       DCPOMATIC_ASSERT (film);
-
-       FrameRateChange const frc (_parent->active_video_frame_rate(), film->video_frame_rate());
+       FrameRateChange const frc (_parent->active_video_frame_rate(), _parent->film()->video_frame_rate());
        ContentTime const c (_parent->full_length(), frc);
 
        p.push_back (
index e196e15c208e6573441c8c3de736c1d31089e4a3..f6cb447f9a87f8eea6acd5cbdc07ae319d6baaad 100644 (file)
@@ -42,8 +42,8 @@ public:
 class AudioContent : public ContentPart
 {
 public:
-       AudioContent (Content* parent, boost::shared_ptr<const Film>);
-       AudioContent (Content* parent, boost::shared_ptr<const Film>, std::vector<boost::shared_ptr<Content> >);
+       AudioContent (Content* parent);
+       AudioContent (Content* parent, std::vector<boost::shared_ptr<Content> >);
 
        void as_xml (xmlpp::Node *) const;
        std::string technical_summary () const;
@@ -81,11 +81,11 @@ public:
 
        void add_properties (std::list<UserProperty> &) const;
 
-       static boost::shared_ptr<AudioContent> from_xml (Content* parent, boost::shared_ptr<const Film>, cxml::ConstNodePtr);
+       static boost::shared_ptr<AudioContent> from_xml (Content* parent, cxml::ConstNodePtr);
 
 private:
 
-       AudioContent (Content* parent, boost::shared_ptr<const Film>, cxml::ConstNodePtr);
+       AudioContent (Content* parent, cxml::ConstNodePtr);
 
        /** Gain to apply to audio in dB */
        double _gain;
index dbc5232395bed3c49b8db3215b19b644df55b3cb..98e9a6d1ce2c046ea25d9bd13959a38c9ab347e7 100644 (file)
@@ -30,9 +30,8 @@ class Film;
 class ContentPart
 {
 public:
-       ContentPart (Content* parent, boost::shared_ptr<const Film> film)
+       ContentPart (Content* parent)
                : _parent (parent)
-               , _film (film)
        {}
 
 protected:
@@ -65,7 +64,6 @@ protected:
        }
 
        Content* _parent;
-       boost::weak_ptr<const Film> _film;
        mutable boost::mutex _mutex;
 };
 
index 83374fc3051759f815819cf8c71cb6bb0c57a672..b28e91dd5cb30d74bf964ae827efa771bb378124 100644 (file)
@@ -62,8 +62,8 @@ DCPContent::DCPContent (shared_ptr<const Film> film, boost::filesystem::path p)
        , _reference_audio (false)
        , _reference_subtitle (false)
 {
-       video.reset (new VideoContent (this, film));
-       audio.reset (new AudioContent (this, film));
+       video.reset (new VideoContent (this));
+       audio.reset (new AudioContent (this));
 
        read_directory (p);
        set_default_colour_conversion ();
@@ -72,9 +72,9 @@ DCPContent::DCPContent (shared_ptr<const Film> film, boost::filesystem::path p)
 DCPContent::DCPContent (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
        : Content (film, node)
 {
-       video = VideoContent::from_xml (this, film, node, version);
-       audio = AudioContent::from_xml (this, film, node);
-       subtitle = SubtitleContent::from_xml (this, film, node, version);
+       video = VideoContent::from_xml (this, node, version);
+       audio = AudioContent::from_xml (this, node);
+       subtitle = SubtitleContent::from_xml (this, node, version);
 
        audio->set_stream (
                AudioStreamPtr (
@@ -138,7 +138,7 @@ DCPContent::examine (shared_ptr<Job> job)
                boost::mutex::scoped_lock lm (_mutex);
                _name = examiner->name ();
                if (examiner->has_subtitles ()) {
-                       subtitle.reset (new SubtitleContent (this, film()));
+                       subtitle.reset (new SubtitleContent (this));
                }
                _encrypted = examiner->encrypted ();
                _kdm_valid = examiner->kdm_valid ();
index a806c9cbd764125bf56ba72f7ecf34f0fd7dc3e4..bd5d5d70e26ace96ced1ce9bca5355b743f14bfb 100644 (file)
@@ -38,14 +38,14 @@ using boost::dynamic_pointer_cast;
 DCPSubtitleContent::DCPSubtitleContent (shared_ptr<const Film> film, boost::filesystem::path path)
        : Content (film, path)
 {
-       subtitle.reset (new SubtitleContent (this, film));
+       subtitle.reset (new SubtitleContent (this));
 }
 
 DCPSubtitleContent::DCPSubtitleContent (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
        : Content (film, node)
        , _length (node->number_child<ContentTime::Type> ("Length"))
 {
-       subtitle = SubtitleContent::from_xml (this, film, node, version);
+       subtitle = SubtitleContent::from_xml (this, node, version);
 }
 
 void
index 628c47b350c8f14303b7af47de430774c4c12a1f..9a3348301382e88aa0b36e2dd8ef9dabcccaf1e7 100644 (file)
@@ -70,9 +70,9 @@ FFmpegContent::FFmpegContent (shared_ptr<const Film> film, boost::filesystem::pa
 FFmpegContent::FFmpegContent (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version, list<string>& notes)
        : Content (film, node)
 {
-       video = VideoContent::from_xml (this, film, node, version);
-       audio = AudioContent::from_xml (this, film, node);
-       subtitle = SubtitleContent::from_xml (this, film, node, version);
+       video = VideoContent::from_xml (this, node, version);
+       audio = AudioContent::from_xml (this, node);
+       subtitle = SubtitleContent::from_xml (this, node, version);
 
        list<cxml::NodePtr> c = node->node_children ("SubtitleStream");
        for (list<cxml::NodePtr>::const_iterator i = c.begin(); i != c.end(); ++i) {
@@ -120,9 +120,9 @@ FFmpegContent::FFmpegContent (shared_ptr<const Film> film, cxml::ConstNodePtr no
 FFmpegContent::FFmpegContent (shared_ptr<const Film> film, vector<boost::shared_ptr<Content> > c)
        : Content (film, c)
 {
-       video.reset (new VideoContent (this, film, c));
-       audio.reset (new AudioContent (this, film, c));
-       subtitle.reset (new SubtitleContent (this, film, c));
+       video.reset (new VideoContent (this, c));
+       audio.reset (new AudioContent (this, c));
+       subtitle.reset (new SubtitleContent (this, c));
 
        shared_ptr<FFmpegContent> ref = dynamic_pointer_cast<FFmpegContent> (c[0]);
        DCPOMATIC_ASSERT (ref);
@@ -208,7 +208,7 @@ FFmpegContent::examine (shared_ptr<Job> job)
        shared_ptr<FFmpegExaminer> examiner (new FFmpegExaminer (shared_from_this (), job));
 
        if (examiner->has_video ()) {
-               video.reset (new VideoContent (this, film ()));
+               video.reset (new VideoContent (this));
                video->take_from_examiner (examiner);
                set_default_colour_conversion ();
        }
@@ -226,7 +226,7 @@ FFmpegContent::examine (shared_ptr<Job> job)
                }
 
                if (!examiner->audio_streams().empty ()) {
-                       audio.reset (new AudioContent (this, film ()));
+                       audio.reset (new AudioContent (this));
 
                        BOOST_FOREACH (shared_ptr<FFmpegAudioStream> i, examiner->audio_streams ()) {
                                audio->add_stream (i);
@@ -240,7 +240,7 @@ FFmpegContent::examine (shared_ptr<Job> job)
 
                _subtitle_streams = examiner->subtitle_streams ();
                if (!_subtitle_streams.empty ()) {
-                       subtitle.reset (new SubtitleContent (this, film ()));
+                       subtitle.reset (new SubtitleContent (this));
                        _subtitle_stream = _subtitle_streams.front ();
                }
 
index ef82b3779d29d60b4a2231fb2e4f0ab200e88857..6d1738419bab10287a9df5149d2d31bec911a255 100644 (file)
@@ -41,7 +41,7 @@ using boost::shared_ptr;
 ImageContent::ImageContent (shared_ptr<const Film> film, boost::filesystem::path p)
        : Content (film)
 {
-       video.reset (new VideoContent (this, film));
+       video.reset (new VideoContent (this));
 
        if (boost::filesystem::is_regular_file (p) && valid_image_file (p)) {
                _paths.push_back (p);
@@ -66,7 +66,7 @@ ImageContent::ImageContent (shared_ptr<const Film> film, boost::filesystem::path
 ImageContent::ImageContent (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
        : Content (film, node)
 {
-       video = VideoContent::from_xml (this, film, node, version);
+       video = VideoContent::from_xml (this, node, version);
 }
 
 string
index 81e467d1d27feb2878fe4175f4890b28f23914fd..aa31f52c0aafe4cb09d16d4e97d05f536ef020d3 100644 (file)
@@ -41,13 +41,13 @@ using boost::shared_ptr;
 SndfileContent::SndfileContent (shared_ptr<const Film> film, boost::filesystem::path p)
        : Content (film, p)
 {
-       audio.reset (new AudioContent (this, film));
+       audio.reset (new AudioContent (this));
 }
 
 SndfileContent::SndfileContent (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
        : Content (film, node)
 {
-       audio = AudioContent::from_xml (this, film, node);
+       audio = AudioContent::from_xml (this, node);
 
        if (audio) {
                audio->set_stream (
index 89953b0e5d5c791c1db7fcd2aa94aff61fa6c3a1..01db0cee6f9c14991d1dbbfd391174d4e9cee09c 100644 (file)
@@ -24,7 +24,6 @@
 #include "font.h"
 #include "raw_convert.h"
 #include "content.h"
-#include "film.h"
 #include <libcxml/cxml.h>
 #include <libxml++/libxml++.h>
 #include <boost/foreach.hpp>
@@ -51,8 +50,8 @@ int const SubtitleContentProperty::COLOUR = 508;
 int const SubtitleContentProperty::OUTLINE = 509;
 int const SubtitleContentProperty::OUTLINE_COLOUR = 510;
 
-SubtitleContent::SubtitleContent (Content* parent, shared_ptr<const Film> film)
-       : ContentPart (parent, film)
+SubtitleContent::SubtitleContent (Content* parent)
+       : ContentPart (parent)
        , _use (false)
        , _burn (false)
        , _x_offset (0)
@@ -67,17 +66,17 @@ SubtitleContent::SubtitleContent (Content* parent, shared_ptr<const Film> film)
 }
 
 shared_ptr<SubtitleContent>
-SubtitleContent::from_xml (Content* parent, shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
+SubtitleContent::from_xml (Content* parent, cxml::ConstNodePtr node, int version)
 {
        if (!node->optional_number_child<double>("SubtitleXOffset") && !node->optional_number_child<double>("SubtitleOffset")) {
                return shared_ptr<SubtitleContent> ();
        }
 
-       return shared_ptr<SubtitleContent> (new SubtitleContent (parent, film, node, version));
+       return shared_ptr<SubtitleContent> (new SubtitleContent (parent, node, version));
 }
 
-SubtitleContent::SubtitleContent (Content* parent, shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
-       : ContentPart (parent, film)
+SubtitleContent::SubtitleContent (Content* parent, cxml::ConstNodePtr node, int version)
+       : ContentPart (parent)
        , _use (false)
        , _burn (false)
        , _x_offset (0)
@@ -125,8 +124,8 @@ SubtitleContent::SubtitleContent (Content* parent, shared_ptr<const Film> film,
        connect_to_fonts ();
 }
 
-SubtitleContent::SubtitleContent (Content* parent, shared_ptr<const Film> film, vector<shared_ptr<Content> > c)
-       : ContentPart (parent, film)
+SubtitleContent::SubtitleContent (Content* parent, vector<shared_ptr<Content> > c)
+       : ContentPart (parent)
 {
        shared_ptr<SubtitleContent> ref = c[0]->subtitle;
        DCPOMATIC_ASSERT (ref);
index db22863394840b65f382da8241f76b4cdac11e3b..5b8f9fc7169ed4f11300a37b0fe6e065d46c87df 100644 (file)
@@ -46,8 +46,8 @@ public:
 class SubtitleContent : public ContentPart
 {
 public:
-       SubtitleContent (Content* parent, boost::shared_ptr<const Film>);
-       SubtitleContent (Content* parent, boost::shared_ptr<const Film>, std::vector<boost::shared_ptr<Content> >);
+       SubtitleContent (Content* parent);
+       SubtitleContent (Content* parent, std::vector<boost::shared_ptr<Content> >);
 
        void as_xml (xmlpp::Node *) const;
        std::string identifier () const;
@@ -128,7 +128,7 @@ public:
                return _outline_colour;
        }
 
-       static boost::shared_ptr<SubtitleContent> from_xml (Content* parent, boost::shared_ptr<const Film>, cxml::ConstNodePtr, int version);
+       static boost::shared_ptr<SubtitleContent> from_xml (Content* parent, cxml::ConstNodePtr, int version);
 
 protected:
        /** subtitle language (e.g. "German") or empty if it is not known */
@@ -137,7 +137,7 @@ protected:
 private:
        friend struct ffmpeg_pts_offset_test;
 
-       SubtitleContent (Content* parent, boost::shared_ptr<const Film>, cxml::ConstNodePtr, int version);
+       SubtitleContent (Content* parent, cxml::ConstNodePtr, int version);
        void font_changed ();
        void connect_to_fonts ();
 
index 4fdd690c370af4ad0f53aa3e46246ce96c998829..bb5ade0c41fbaab5d4b3cb90f31f15646b35e7ae 100644 (file)
@@ -38,14 +38,14 @@ std::string const TextSubtitleContent::font_id = "font";
 TextSubtitleContent::TextSubtitleContent (shared_ptr<const Film> film, boost::filesystem::path path)
        : Content (film, path)
 {
-       subtitle.reset (new SubtitleContent (this, film));
+       subtitle.reset (new SubtitleContent (this));
 }
 
 TextSubtitleContent::TextSubtitleContent (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
        : Content (film, node)
        , _length (node->number_child<ContentTime::Type> ("Length"))
 {
-       subtitle = SubtitleContent::from_xml (this, film, node, version);
+       subtitle = SubtitleContent::from_xml (this, node, version);
 }
 
 void
index 75d94510ad3d97a7e1ab9e5ce61d96fc9c8f9124..fce90ad7bded1913f8bf0a93a5d62a93f85e32df 100644 (file)
@@ -39,7 +39,7 @@
 
 #include "i18n.h"
 
-#define LOG_GENERAL(...) film->log()->log (String::compose (__VA_ARGS__), LogEntry::TYPE_GENERAL);
+#define LOG_GENERAL(...) _parent->film()->log()->log (String::compose (__VA_ARGS__), LogEntry::TYPE_GENERAL);
 
 int const VideoContentProperty::SIZE     = 0;
 int const VideoContentProperty::FRAME_TYPE  = 1;
@@ -63,8 +63,8 @@ using boost::shared_ptr;
 using boost::optional;
 using boost::dynamic_pointer_cast;
 
-VideoContent::VideoContent (Content* parent, shared_ptr<const Film> film)
-       : ContentPart (parent, film)
+VideoContent::VideoContent (Content* parent)
+       : ContentPart (parent)
        , _length (0)
        , _frame_type (VIDEO_FRAME_TYPE_2D)
        , _scale (VideoContentScale (Ratio::from_id ("178")))
@@ -76,17 +76,17 @@ VideoContent::VideoContent (Content* parent, shared_ptr<const Film> film)
 }
 
 shared_ptr<VideoContent>
-VideoContent::from_xml (Content* parent, shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
+VideoContent::from_xml (Content* parent, cxml::ConstNodePtr node, int version)
 {
        if (!node->optional_number_child<int> ("VideoWidth")) {
                return shared_ptr<VideoContent> ();
        }
 
-       return shared_ptr<VideoContent> (new VideoContent (parent, film, node, version));
+       return shared_ptr<VideoContent> (new VideoContent (parent, node, version));
 }
 
-VideoContent::VideoContent (Content* parent, shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
-       : ContentPart (parent, film)
+VideoContent::VideoContent (Content* parent, cxml::ConstNodePtr node, int version)
+       : ContentPart (parent)
 {
        _size.width = node->number_child<int> ("VideoWidth");
        _size.height = node->number_child<int> ("VideoHeight");
@@ -129,8 +129,8 @@ VideoContent::VideoContent (Content* parent, shared_ptr<const Film> film, cxml::
        }
 }
 
-VideoContent::VideoContent (Content* parent, shared_ptr<const Film> film, vector<shared_ptr<Content> > c)
-       : ContentPart (parent, film)
+VideoContent::VideoContent (Content* parent, vector<shared_ptr<Content> > c)
+       : ContentPart (parent)
        , _length (0)
        , _yuv (false)
 {
@@ -222,8 +222,6 @@ VideoContent::take_from_examiner (shared_ptr<VideoExaminer> d)
                        );
        }
 
-       shared_ptr<const Film> film = _film.lock ();
-       DCPOMATIC_ASSERT (film);
        LOG_GENERAL ("Video length obtained from header as %1 frames", _length);
 
        if (d->video_frame_rate()) {
@@ -301,8 +299,7 @@ VideoContent::size_after_crop () const
 void
 VideoContent::scale_and_crop_to_fit_width ()
 {
-       shared_ptr<const Film> film = _film.lock ();
-       DCPOMATIC_ASSERT (film);
+       shared_ptr<const Film> film = _parent->film ();
        set_scale (VideoContentScale (film->container ()));
 
        int const crop = max (0, int (size().height - double (film->frame_size().height) * size().width / film->frame_size().width));
@@ -315,8 +312,7 @@ VideoContent::scale_and_crop_to_fit_width ()
 void
 VideoContent::scale_and_crop_to_fit_height ()
 {
-       shared_ptr<const Film> film = _film.lock ();
-       DCPOMATIC_ASSERT (film);
+       shared_ptr<const Film> film = _parent->film ();
        set_scale (VideoContentScale (film->container ()));
 
        int const crop = max (0, int (size().width - double (film->frame_size().width) * size().height / film->frame_size().height));
@@ -332,8 +328,7 @@ VideoContent::fade (Frame f) const
 {
        DCPOMATIC_ASSERT (f >= 0);
 
-       shared_ptr<const Film> film = _film.lock ();
-       DCPOMATIC_ASSERT (film);
+       shared_ptr<const Film> film = _parent->film ();
 
        double const vfr = _parent->active_video_frame_rate ();
 
@@ -384,8 +379,7 @@ VideoContent::processing_description () const
                d << " (" << fixed << setprecision(2) << cropped.ratio () << ":1)\n";
        }
 
-       shared_ptr<const Film> film = _film.lock ();
-       DCPOMATIC_ASSERT (film);
+       shared_ptr<const Film> film = _parent->film ();
        dcp::Size const container_size = film->frame_size ();
        dcp::Size const scaled = scale().size (shared_from_this(), container_size, container_size);
 
index ef54a6be4657c322731a235a550e7265c12dae27..7d24b30ff166c770a1d1a52a162ddd2c6d63b2da 100644 (file)
@@ -50,8 +50,8 @@ public:
 class VideoContent : public ContentPart, public boost::enable_shared_from_this<VideoContent>
 {
 public:
-       VideoContent (Content* parent, boost::shared_ptr<const Film>);
-       VideoContent (Content* parent, boost::shared_ptr<const Film>, std::vector<boost::shared_ptr<Content> >);
+       VideoContent (Content* parent);
+       VideoContent (Content* parent, std::vector<boost::shared_ptr<Content> >);
 
        void as_xml (xmlpp::Node *) const;
        std::string technical_summary () const;
@@ -166,7 +166,7 @@ public:
        void take_from_examiner (boost::shared_ptr<VideoExaminer>);
        void add_properties (std::list<UserProperty> &) const;
 
-       static boost::shared_ptr<VideoContent> from_xml (Content* parent, boost::shared_ptr<const Film>, cxml::ConstNodePtr, int);
+       static boost::shared_ptr<VideoContent> from_xml (Content* parent, cxml::ConstNodePtr, int);
 
 private:
 
@@ -175,7 +175,7 @@ private:
        friend struct best_dcp_frame_rate_test_double;
        friend struct audio_sampling_rate_test;
 
-       VideoContent (Content* parent, boost::shared_ptr<const Film>, cxml::ConstNodePtr, int);
+       VideoContent (Content* parent, cxml::ConstNodePtr, int);
        void setup_default_colour_conversion ();
 
        Frame _length;
index 7dba67b5a8505a821127221eaf18a5ee9d693f3b..45617bc41547c49b451b06831019da8dbc427c59 100644 (file)
@@ -41,7 +41,7 @@ public:
        TestAudioContent (shared_ptr<const Film> film)
                : Content (film)
        {
-               audio.reset (new AudioContent (this, film));
+               audio.reset (new AudioContent (this));
                audio->set_stream (AudioStreamPtr (new AudioStream (48000, audio_length(), 2)));
        }
 
index f70fddede90fdb87ff8ee2339f208d2658c665aa..caafd158432719c233e4a6c255f32b78c1c545a2 160000 (submodule)
--- a/test/data
+++ b/test/data
@@ -1 +1 @@
-Subproject commit f70fddede90fdb87ff8ee2339f208d2658c665aa
+Subproject commit caafd158432719c233e4a6c255f32b78c1c545a2
index a10e505dd0796946c46107dfd4c498276f3396dd..141569217531225e387c31c0f528c68f64c6e968 100644 (file)
@@ -38,7 +38,7 @@ BOOST_AUTO_TEST_CASE (ffmpeg_pts_offset_test)
        film->examine_and_add_content (content);
        wait_for_jobs ();
 
-       content->audio.reset (new AudioContent (content.get(), film));
+       content->audio.reset (new AudioContent (content.get()));
        content->audio->add_stream (shared_ptr<FFmpegAudioStream> (new FFmpegAudioStream));
        content->_video_frame_rate = 24;