#include "film.h"
#include "exceptions.h"
+#include "i18n.h"
+
using std::cout;
using boost::shared_ptr;
using libdcp::Size;
ImageMagickDecoder::ImageMagickDecoder (
- boost::shared_ptr<Film> f, DecodeOptions o, Job* j)
- : Decoder (f, o, j)
- , VideoDecoder (f, o, j)
+ boost::shared_ptr<Film> f, DecodeOptions o)
+ : Decoder (f, o)
+ , VideoDecoder (f, o)
{
if (boost::filesystem::is_directory (_film->content_path())) {
for (
ImageMagickDecoder::native_size () const
{
if (_files.empty ()) {
- throw DecodeError ("no still image files found");
+ throw DecodeError (_("no still image files found"));
}
/* Look at the first file and assume its size holds for all */
return true;
}
- repeat_last_video ();
+ emit_video (_image, true, double (video_frame()) / frames_per_second());
return false;
}
delete magick_image;
- image = image->crop (_film->crop(), true);
-
- emit_video (image, 0);
+ _image = image->crop (_film->crop(), true);
+
+ emit_video (_image, false, double (video_frame()) / frames_per_second());
++_iter;
return false;
OutputChanged ();
}
}
+
+float
+ImageMagickDecoder::frames_per_second () const
+{
+ return _film->source_frame_rate ();
+}