+2014-03-07 Carl Hetherington <cth@carlh.net>
+
+ * Add subtitle view.
+
+ 2014-04-27 Carl Hetherington <cth@carlh.net>
+
+ * Version 1.66.16 released.
+
+ 2014-04-27 Carl Hetherington <cth@carlh.net>
+
+ * Add .dpx to the list of acceptable image files.
+
+ * Slightly better handling of uncaught exceptions.
+
+ * Use our own directory picker on 14.04 (as well as 13.04 and 13.10) as
+ it appears that the same bug remains.
+
+ 2014-04-25 Carl Hetherington <cth@carlh.net>
+
+ * Version 1.66.15 released.
+
+ 2014-04-25 Carl Hetherington <cth@carlh.net>
+
+ * Fix subtitle display when the next subtitle is decoded before the previous
+ one has finished.
+
+ 2014-04-24 Carl Hetherington <cth@carlh.net>
+
+ * Version 1.66.14 released.
+
+ 2014-04-23 Carl Hetherington <cth@carlh.net>
+
+ * Version 1.66.13 released.
+
+ 2014-04-21 Carl Hetherington <cth@carlh.net>
+
+ * Update to es_ES translation from Manuel AC.
+
+ * Update to fr_FR translation from Thierry Journet.
+
+ 2014-04-17 Carl Hetherington <cth@carlh.net>
+
+ * Fix update of the gain control when using the gain calculator
+ dialog.
+
+ * Version 1.66.12 released.
+
2014-04-07 Carl Hetherington <cth@carlh.net>
* Version 1.66.11 released.
--- /dev/null
-class Piece;
-class Image;
-class Player;
-
-struct IncomingVideo
-{
-public:
- boost::weak_ptr<Piece> weak_piece;
- boost::shared_ptr<const Image> image;
- Eyes eyes;
- bool same;
- VideoContent::Frame frame;
- Time extra;
-};
+ /*
+ Copyright (C) 2013-2014 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
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+ */
+
+ #ifndef DCPOMATIC_PIECE_H
+ #define DCPOMATIC_PIECE_H
+
+ #include "types.h"
+ #include "video_content.h"
+
+ class Content;
+ class Decoder;
- Piece (boost::shared_ptr<Content> c);
- Piece (boost::shared_ptr<Content> c, boost::shared_ptr<Decoder> d);
- void set_repeat (IncomingVideo video, int num);
- void reset_repeat ();
- bool repeating () const;
- void repeat (Player* player);
-
+
+ class Piece
+ {
+ public:
- /** Time of the last video we emitted relative to the start of the DCP */
- Time video_position;
- /** Time of the last audio we emitted relative to the start of the DCP */
- Time audio_position;
-
- IncomingVideo repeat_video;
- int repeat_to_do;
- int repeat_done;
++ Piece (boost::shared_ptr<Content> c, boost::shared_ptr<Decoder> d, FrameRateChange f)
++ : content (c)
++ , decoder (d)
++ , frc (f)
++ {}
++
+ boost::shared_ptr<Content> content;
+ boost::shared_ptr<Decoder> decoder;
++ FrameRateChange frc;
+ };
+
+ #endif
#include "content.h"
#include "film.h"
#include "rect.h"
-#include "audio_merger.h"
#include "audio_content.h"
-#include "subtitle.h"
+#include "dcpomatic_time.h"
+#include "content_subtitle.h"
+#include "position_image.h"
+ #include "piece.h"
class Job;
class Film;
class AudioContent;
class Piece;
class Image;
-class Resampler;
+class DCPVideo;
+class Decoder;
+
+class PlayerStatistics
+{
+public:
+ struct Video {
+ Video ()
+ : black (0)
+ , repeat (0)
+ , good (0)
+ , skip (0)
+ {}
+
+ int black;
+ int repeat;
+ int good;
+ int skip;
+ } video;
+
+ struct Audio {
+ Audio ()
+ : silence (0)
+ , good (0)
+ , skip (0)
+ {}
+
+ DCPTime silence;
+ int64_t good;
+ int64_t skip;
+ } audio;
+
+ void dump (boost::shared_ptr<Log>) const;
+};
- class Piece
+ /** A wrapper for an Image which contains some pending operations; these may
+ * not be necessary if the receiver of the PlayerImage throws it away.
+ */
+ class PlayerImage
{
public:
- Piece (boost::shared_ptr<Content> c, boost::shared_ptr<Decoder> d, FrameRateChange f)
- : content (c)
- , decoder (d)
- , frc (f)
- {}
-
- boost::shared_ptr<Content> content;
- boost::shared_ptr<Decoder> decoder;
- FrameRateChange frc;
- PlayerImage (boost::shared_ptr<const Image>, Crop, libdcp::Size, libdcp::Size, Scaler const *);
++ PlayerImage (boost::shared_ptr<const Image>, Crop, dcp::Size, dcp::Size, Scaler const *);
+
+ void set_subtitle (boost::shared_ptr<const Image>, Position<int>);
+
+ boost::shared_ptr<Image> image ();
-
++
+ private:
+ boost::shared_ptr<const Image> _in;
+ Crop _crop;
- libdcp::Size _inter_size;
- libdcp::Size _out_size;
++ dcp::Size _inter_size;
++ dcp::Size _out_size;
+ Scaler const * _scaler;
+ boost::shared_ptr<const Image> _subtitle_image;
+ Position<int> _subtitle_position;
};
-
+
/** @class Player
- * @brief A class which can `play' a Playlist; emitting its audio and video.
+ * @brief A class which can `play' a Playlist.
*/
class Player : public boost::enable_shared_from_this<Player>, public boost::noncopyable
{