Provide better information on what will happen to JPEG2000 content in inputs (part...
[dcpomatic.git] / src / lib / player_video.cc
index 8d55ffb2e2e5cf51db512f3bf90aacd1f64583e8..1dd64540ac5ec4dc03e622bcdc2652f169df0d66 100644 (file)
@@ -211,9 +211,9 @@ PlayerVideo::add_metadata (xmlpp::Node* node) const
 }
 
 void
-PlayerVideo::send_binary (shared_ptr<Socket> socket) const
+PlayerVideo::write_to_socket (shared_ptr<Socket> socket) const
 {
-       _in->send_binary (socket);
+       _in->write_to_socket (socket);
        if (_text) {
                _text->image->write_to_socket (socket);
        }
@@ -224,6 +224,8 @@ PlayerVideo::has_j2k () const
 {
        /* XXX: maybe other things */
 
+       /* This and DCPContent::processing_description() need to be kept in sync */
+
        shared_ptr<const J2KImageProxy> j2k = dynamic_pointer_cast<const J2KImageProxy> (_in);
        if (!j2k) {
                return false;
@@ -339,7 +341,7 @@ PlayerVideo::reset_metadata (shared_ptr<const Film> film, dcp::Size video_contai
 
        _crop = content->video->crop();
        _fade = content->video->fade(film, _video_frame.get());
-       _inter_size = content->video->scale().size(content->video, video_container_size, film_frame_size);
+       _inter_size = scale_for_display(content->video->scaled_size(film_frame_size), video_container_size, film_frame_size);
        _out_size = video_container_size;
        _colour_conversion = content->video->colour_conversion();
        _video_range = content->video->range();