1 #include "black_content.h"
2 #include "black_decoder.h"
4 #include "raw_image_proxy.h"
5 #include "video_decoder.h"
8 using std::make_shared;
10 using namespace dcpomatic;
13 BlackDecoder::BlackDecoder (shared_ptr<const Film> film, shared_ptr<const BlackContent> content)
16 , _video_frame_rate(film->video_frame_rate())
18 video = make_shared<VideoDecoder>(this, content);
19 _image = make_shared<Image>(AV_PIX_FMT_RGB24, dcp::Size(128, 128), Image::Alignment::PADDED);
20 _image->make_black ();
21 _proxy = make_shared<const RawImageProxy>(_image);
26 BlackDecoder::seek (ContentTime time, bool)
28 _position = DCPTime(time.get());
35 if (_position >= _content->end(film())) {
39 video->emit(film(), _proxy, _position.frames_round(_video_frame_rate));
40 _position += DCPTime::from_frames(1, _video_frame_rate);