Fix font_id_map errors when importing DCP subtitles that have no
[dcpomatic.git] / src / lib / player.h
index 31628941f5eb04804249bd95583cdba7d6b6400e..22701cb2ca452c486746f643063c7bb7affa1250 100644 (file)
@@ -81,7 +81,7 @@ public:
        void seek (dcpomatic::DCPTime time, bool accurate);
 
        std::vector<std::shared_ptr<dcpomatic::Font>> get_subtitle_fonts ();
-       std::list<ReferencedReelAsset> get_reel_assets ();
+
        dcp::Size video_container_size () const {
                return _video_container_size;
        }
@@ -155,7 +155,7 @@ private:
        void emit_audio (std::shared_ptr<AudioBuffers> data, dcpomatic::DCPTime time);
        std::shared_ptr<const Playlist> playlist () const;
 
-       /** Mutex to protect the whole Player state.  When it's used for the preview we have
+       /** Mutex to protect the most of the Player state.  When it's used for the preview we have
            seek() and pass() called from the Butler thread and lots of other stuff called
            from the GUI thread.
        */
@@ -173,6 +173,8 @@ private:
         *  the size of preview in a window.
         */
        boost::atomic<dcp::Size> _video_container_size;
+
+       mutable boost::mutex _black_image_mutex;
        std::shared_ptr<Image> _black_image;
 
        /** true if the player should ignore all video; i.e. never produce any */
@@ -225,7 +227,7 @@ private:
        ActiveText _active_texts[static_cast<int>(TextType::COUNT)];
        std::shared_ptr<AudioProcessor> _audio_processor;
 
-       dcpomatic::DCPTime _playback_length;
+       boost::atomic<dcpomatic::DCPTime> _playback_length;
 
        /** Alignment for subtitle images that we create */
        Image::Alignment const _subtitle_alignment = Image::Alignment::PADDED;