class Image;
}
+class ImageMagickContent;
+
class ImageMagickDecoder : public VideoDecoder
{
public:
- ImageMagickDecoder (boost::shared_ptr<Film>, DecodeOptions, Job *);
+ ImageMagickDecoder (boost::shared_ptr<const Film>, boost::shared_ptr<const ImageMagickContent>);
- float frames_per_second () const {
- /* We don't know */
- return 0;
- }
+ /* Decoder */
- libdcp::Size native_size () const;
+ void pass ();
+ void seek (Time);
+ void seek_back ();
+ void seek_forward ();
+ Time next () const;
+ bool done () const;
- SourceFrame length () const {
- /* We don't know */
- return 0;
- }
+ /* VideoDecoder */
- int audio_channels () const {
- return 0;
- }
+ float video_frame_rate () const;
+ libdcp::Size video_size () const;
+ ContentVideoFrame video_length () const;
- int audio_sample_rate () const {
- return 0;
- }
-
- int64_t audio_channel_layout () const {
- return 0;
- }
-
- bool has_subtitles () const {
- return false;
- }
-
- bool seek (double);
- bool seek_to_last ();
-
-protected:
- bool pass ();
- PixelFormat pixel_format () const;
-
- int time_base_numerator () const {
- return 0;
- }
-
- int time_base_denominator () const {
- return 0;
- }
-
- int sample_aspect_ratio_numerator () const {
- /* XXX */
- return 1;
- }
+ /* ImageMagickDecoder */
- int sample_aspect_ratio_denominator () const {
- /* XXX */
- return 1;
+ boost::shared_ptr<const ImageMagickContent> content () const {
+ return _imagemagick_content;
}
private:
- void film_changed (Film::Property);
-
- std::list<std::string> _files;
- std::list<std::string>::iterator _iter;
+ boost::shared_ptr<const ImageMagickContent> _imagemagick_content;
+ boost::shared_ptr<Image> _image;
+ mutable boost::optional<libdcp::Size> _video_size;
};