summaryrefslogtreecommitdiff
path: root/src/lib/player.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/player.cc')
-rw-r--r--src/lib/player.cc14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/lib/player.cc b/src/lib/player.cc
index 620efbd0d..647095793 100644
--- a/src/lib/player.cc
+++ b/src/lib/player.cc
@@ -24,6 +24,8 @@
#include "ffmpeg_content.h"
#include "still_image_decoder.h"
#include "still_image_content.h"
+#include "moving_image_decoder.h"
+#include "moving_image_content.h"
#include "sndfile_decoder.h"
#include "sndfile_content.h"
#include "subtitle_content.h"
@@ -462,6 +464,18 @@ Player::setup_pieces ()
piece->decoder = id;
}
+ shared_ptr<const MovingImageContent> mc = dynamic_pointer_cast<const MovingImageContent> (*i);
+ if (mc) {
+ shared_ptr<MovingImageDecoder> md;
+
+ if (!md) {
+ md.reset (new MovingImageDecoder (_film, mc));
+ md->Video.connect (bind (&Player::process_video, this, piece, _1, _2, _3, _4));
+ }
+
+ piece->decoder = md;
+ }
+
shared_ptr<const SndfileContent> sc = dynamic_pointer_cast<const SndfileContent> (*i);
if (sc) {
shared_ptr<AudioDecoder> sd (new SndfileDecoder (_film, sc));