Basic grunt-work, untested and unfinished, but it compiles.
[dcpomatic.git] / src / lib / ffmpeg_content.cc
index bc913a9ae280169dfba3e0ed7ac7fb7131149703..44e1b2afb22363499a8b5d9c0b772ade907c1931 100644 (file)
@@ -411,28 +411,6 @@ FFmpegContent::identifier () const
        return s;
 }
 
-list<ContentTimePeriod>
-FFmpegContent::image_subtitles_during (ContentTimePeriod period, bool starting) const
-{
-       shared_ptr<FFmpegSubtitleStream> stream = subtitle_stream ();
-       if (!stream) {
-               return list<ContentTimePeriod> ();
-       }
-
-       return stream->image_subtitles_during (period, starting);
-}
-
-list<ContentTimePeriod>
-FFmpegContent::text_subtitles_during (ContentTimePeriod period, bool starting) const
-{
-       shared_ptr<FFmpegSubtitleStream> stream = subtitle_stream ();
-       if (!stream) {
-               return list<ContentTimePeriod> ();
-       }
-
-       return stream->text_subtitles_during (period, starting);
-}
-
 void
 FFmpegContent::set_default_colour_conversion ()
 {
@@ -517,10 +495,12 @@ FFmpegContent::add_properties (list<UserProperty>& p) const
                        _("SMPTE 240M"),
                        _("Film"),
                        _("BT2020"),
-                       _("SMPTE ST 428-1 (CIE 1931 XYZ)")
+                       _("SMPTE ST 428-1 (CIE 1931 XYZ)"),
+                       _("SMPTE ST 431-2 (2011)"),
+                       _("SMPTE ST 432-1 D65 (2010)")
                };
 
-               DCPOMATIC_ASSERT (AVCOL_PRI_NB <= 11);
+               DCPOMATIC_ASSERT (AVCOL_PRI_NB <= 13);
                p.push_back (UserProperty (UserProperty::VIDEO, _("Colour primaries"), primaries[_color_primaries]));
 
                char const * transfers[] = {
@@ -560,9 +540,10 @@ FFmpegContent::add_properties (list<UserProperty>& p) const
                        _("YCOCG"),
                        _("BT2020 non-constant luminance"),
                        _("BT2020 constant luminance"),
+                       _("SMPTE 2085, Y'D'zD'x"),
                };
 
-               DCPOMATIC_ASSERT (AVCOL_SPC_NB == 11);
+               DCPOMATIC_ASSERT (AVCOL_SPC_NB == 12);
                p.push_back (UserProperty (UserProperty::VIDEO, _("Colourspace"), spaces[_colorspace]));
 
                if (_bits_per_pixel) {
@@ -599,3 +580,12 @@ FFmpegContent::ffmpeg_audio_streams () const
 
        return fa;
 }
+
+void
+FFmpegContent::use_template (shared_ptr<const Content> c)
+{
+       Content::use_template (c);
+
+       shared_ptr<const FFmpegContent> fc = dynamic_pointer_cast<const FFmpegContent> (c);
+       _filters = fc->_filters;
+}