X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fffmpeg_content.h;h=f5bbbd31e27654ae1d5da742842ab0d07af4fd50;hb=36774ee2b48f0bfde43b743592e5816ff58bb7d2;hp=c5797d5d1b63761d6409fe055ed69692e8db6518;hpb=7fff85ef947f9353317c0125dc37f1f16faecbf1;p=dcpomatic.git diff --git a/src/lib/ffmpeg_content.h b/src/lib/ffmpeg_content.h index c5797d5d1..f5bbbd31e 100644 --- a/src/lib/ffmpeg_content.h +++ b/src/lib/ffmpeg_content.h @@ -20,12 +20,8 @@ #ifndef DCPOMATIC_FFMPEG_CONTENT_H #define DCPOMATIC_FFMPEG_CONTENT_H -#include "video_content.h" #include "audio_content.h" #include "subtitle_content.h" -#include "audio_mapping.h" -#include -#include struct AVFormatContext; struct AVStream; @@ -33,18 +29,20 @@ struct AVStream; class Filter; class FFmpegSubtitleStream; class FFmpegAudioStream; +class VideoContent; struct ffmpeg_pts_offset_test; struct audio_sampling_rate_test; -class FFmpegContentProperty : public VideoContentProperty +class FFmpegContentProperty { public: static int const SUBTITLE_STREAMS; + /** The chosen subtitle stream, or something about it */ static int const SUBTITLE_STREAM; static int const FILTERS; }; -class FFmpegContent : public VideoContent, public AudioContent, public SubtitleContent +class FFmpegContent : public AudioContent, public SubtitleContent { public: FFmpegContent (boost::shared_ptr, boost::filesystem::path); @@ -72,6 +70,7 @@ public: /* SubtitleContent */ bool has_text_subtitles () const; bool has_image_subtitles () const; + double subtitle_video_frame_rate () const; void set_filters (std::vector const &); @@ -102,7 +101,15 @@ public: return _first_video; } - std::list subtitles_during (ContentTimePeriod, bool starting) const; + std::list image_subtitles_during (ContentTimePeriod, bool starting) const; + std::list text_subtitles_during (ContentTimePeriod, bool starting) const; + + void signal_subtitle_stream_changed (); + + boost::shared_ptr video; + +protected: + void add_properties (std::list &) const; private: friend struct ffmpeg_pts_offset_test; @@ -114,6 +121,12 @@ private: boost::optional _first_video; /** Video filters that should be used when generating DCPs */ std::vector _filters; + + AVColorRange _color_range; + AVColorPrimaries _color_primaries; + AVColorTransferCharacteristic _color_trc; + AVColorSpace _colorspace; + boost::optional _bits_per_pixel; }; #endif