Use FileGroup in FFmpeg.
[dcpomatic.git] / src / lib / ffmpeg_content.cc
index 24378ed3da0aebb2e64adea52e4ead5fa5f88344..4ca2ddc2933ff34e7a323c0a9b038c2a22d5e52f 100644 (file)
@@ -59,8 +59,8 @@ FFmpegContent::FFmpegContent (shared_ptr<const Film> f, shared_ptr<const cxml::N
        , AudioContent (f, node)
        , SubtitleContent (f, node)
 {
-       list<shared_ptr<cxml::Node> > c = node->node_children ("SubtitleStream");
-       for (list<shared_ptr<cxml::Node> >::const_iterator i = c.begin(); i != c.end(); ++i) {
+       list<cxml::NodePtr> c = node->node_children ("SubtitleStream");
+       for (list<cxml::NodePtr>::const_iterator i = c.begin(); i != c.end(); ++i) {
                _subtitle_streams.push_back (shared_ptr<FFmpegSubtitleStream> (new FFmpegSubtitleStream (*i)));
                if ((*i)->optional_number_child<int> ("Selected")) {
                        _subtitle_stream = _subtitle_streams.back ();
@@ -68,7 +68,7 @@ FFmpegContent::FFmpegContent (shared_ptr<const Film> f, shared_ptr<const cxml::N
        }
 
        c = node->node_children ("AudioStream");
-       for (list<shared_ptr<cxml::Node> >::const_iterator i = c.begin(); i != c.end(); ++i) {
+       for (list<cxml::NodePtr>::const_iterator i = c.begin(); i != c.end(); ++i) {
                _audio_streams.push_back (shared_ptr<FFmpegAudioStream> (new FFmpegAudioStream (*i)));
                if ((*i)->optional_number_child<int> ("Selected")) {
                        _audio_stream = _audio_streams.back ();
@@ -76,7 +76,7 @@ FFmpegContent::FFmpegContent (shared_ptr<const Film> f, shared_ptr<const cxml::N
        }
 
        c = node->node_children ("Filter");
-       for (list<shared_ptr<cxml::Node> >::iterator i = c.begin(); i != c.end(); ++i) {
+       for (list<cxml::NodePtr>::iterator i = c.begin(); i != c.end(); ++i) {
                _filters.push_back (Filter::from_id ((*i)->content ()));
        }
 
@@ -167,7 +167,7 @@ string
 FFmpegContent::summary () const
 {
        /* Get the string() here so that the name does not have quotes around it */
-       return String::compose (_("%1 [movie]"), path().filename().string());
+       return String::compose (_("%1 [movie]"), path_summary ());
 }
 
 string
@@ -187,6 +187,7 @@ FFmpegContent::technical_summary () const
        
        return Content::technical_summary() + " - "
                + VideoContent::technical_summary() + " - "
+               + AudioContent::technical_summary() + " - "
                + String::compose (
                        "ffmpeg: audio %1, subtitle %2, filters %3 %4", as, ss, filt.first, filt.second
                        );
@@ -345,7 +346,7 @@ FFmpegSubtitleStream::as_xml (xmlpp::Node* root) const
 }
 
 Time
-FFmpegContent::length () const
+FFmpegContent::full_length () const
 {
        shared_ptr<const Film> film = _film.lock ();
        assert (film);