Fix incorrect alpha channel scaling with RGBA64.
[dcpomatic.git] / src / lib / ffmpeg_encoder.cc
index 9816ddec8c230a93bb02a9b88bd25f48de92f01d..60241b23319f3816b265a5b3beacebb07d4ee62b 100644 (file)
@@ -144,8 +144,8 @@ FFmpegEncoder::go ()
        for (int i = 0; i < files; ++i) {
 
                boost::filesystem::path filename = _output;
-               string extension = boost::filesystem::extension (filename);
-               filename = boost::filesystem::change_extension (filename, "");
+               auto extension = dcp::filesystem::extension(filename);
+               filename = dcp::filesystem::change_extension(filename, "");
 
                if (files > 1) {
                        /// TRANSLATORS: _reel%1 here is to be added to an export filename to indicate
@@ -190,12 +190,12 @@ FFmpegEncoder::go ()
 
                for (int j = 0; j < gets_per_frame; ++j) {
                        Butler::Error e;
-                       auto v = _butler.get_video(Butler::Behaviour::BLOCKING, &e);
+                       auto video = _butler.get_video(Butler::Behaviour::BLOCKING, &e);
                        _butler.rethrow();
-                       if (v.first) {
-                               auto fe = encoder->get (v.first->eyes());
+                       if (video.first) {
+                               auto fe = encoder->get(video.first->eyes());
                                if (fe) {
-                                       fe->video(v.first, v.second - reel->from);
+                                       fe->video(video.first, video.second - reel->from);
                                }
                        } else {
                                if (e.code != Butler::Error::Code::FINISHED) {
@@ -261,14 +261,14 @@ FFmpegEncoder::FileEncoderSet::FileEncoderSet (
        )
 {
        if (three_d) {
-               /// TRANSLATORS: L here is an abbreviation for "left", to indicate the left-eye part of a 3D export
                _encoders[Eyes::LEFT] = make_shared<FFmpegFileEncoder>(
                        video_frame_size, video_frame_rate, audio_frame_rate, channels, format,
+                       // TRANSLATORS: L here is an abbreviation for "left", to indicate the left-eye part of a 3D export
                        audio_stream_per_channel, x264_crf, String::compose("%1_%2%3", output.string(), _("L"), extension)
                        );
-               /// TRANSLATORS: R here is an abbreviation for "right", to indicate the right-eye part of a 3D export
                _encoders[Eyes::RIGHT] = make_shared<FFmpegFileEncoder>(
                        video_frame_size, video_frame_rate, audio_frame_rate, channels, format,
+                       // TRANSLATORS: R here is an abbreviation for "right", to indicate the right-eye part of a 3D export
                        audio_stream_per_channel, x264_crf, String::compose("%1_%2%3", output.string(), _("R"), extension)
                        );
        } else {