Merge branch 'content-burn-subs' into 2.0
[dcpomatic.git] / src / lib / player.h
index e515fced345bdd39a610e70c24c1a9383866663a..6edfa49b7d20ada1a4acb15d1c1171ea39a3560b 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2015 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
@@ -44,7 +44,7 @@ class Resampler;
 class PlayerVideo;
 class ImageProxy;
 class Font;
+
 class PlayerStatistics
 {
 public:
@@ -55,7 +55,7 @@ public:
                        , good (0)
                        , skip (0)
                {}
-               
+
                int black;
                int repeat;
                int good;
@@ -68,7 +68,7 @@ public:
                        , good (0)
                        , skip (0)
                {}
-               
+
                DCPTime silence;
                int64_t good;
                int64_t skip;
@@ -87,16 +87,16 @@ public:
 
        std::list<boost::shared_ptr<PlayerVideo> > get_video (DCPTime time, bool accurate);
        boost::shared_ptr<AudioBuffers> get_audio (DCPTime time, DCPTime length, bool accurate);
-       PlayerSubtitles get_subtitles (DCPTime time, DCPTime length, bool starting);
+       PlayerSubtitles get_subtitles (DCPTime time, DCPTime length, bool starting, bool burnt);
        std::list<boost::shared_ptr<Font> > get_subtitle_fonts ();
 
        void set_video_container_size (dcp::Size);
        void set_ignore_video ();
        void set_enable_subtitles (bool enable);
-       void set_burn_subtitles (bool burn);
+       void set_always_burn_subtitles (bool burn);
 
        PlayerStatistics const & statistics () const;
-       
+
        /** Emitted when something has changed such that if we went back and emitted
         *  the last frame again it would look different.  This is not emitted after
         *  a seek.
@@ -141,10 +141,10 @@ private:
                                overlaps.push_back (*i);
                        }
                }
-               
+
                return overlaps;
        }
-       
+
        boost::shared_ptr<const Film> _film;
 
        /** Our pieces are ready to go; if this is false the pieces must be (re-)created before they are used */
@@ -157,8 +157,10 @@ private:
 
        /** true if the player should ignore all video; i.e. never produce any */
        bool _ignore_video;
-       /** true if the player should burn subtitles into the video */
-       bool _burn_subtitles;
+       /** true if the player should always burn subtitles into the video regardless
+           of content settings
+       */
+       bool _always_burn_subtitles;
 
        boost::shared_ptr<AudioProcessor> _audio_processor;