X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fdcp_video.cc;h=4a505a7e18e65996b4666d59f541e67b0f993c06;hb=c7917ecfce3200d807091cb64241e54066822cbf;hp=153f4997ed7dbdbaf14afe693a76ae0476fa7c1a;hpb=190bff4e7b55c0de8f271e3c311f1d0cf5a2426a;p=dcpomatic.git diff --git a/src/lib/dcp_video.cc b/src/lib/dcp_video.cc index 153f4997e..4a505a7e1 100644 --- a/src/lib/dcp_video.cc +++ b/src/lib/dcp_video.cc @@ -128,7 +128,8 @@ DCPVideo::encode_locally () auto const comment = Config::instance()->dcp_j2k_comment(); ArrayData enc = {}; - int const minimum_size = Config::instance()->minimum_frame_size(); + /* This was empirically derived by a user: see #1902 */ + int const minimum_size = 16384; LOG_GENERAL ("Using minimum frame size %1", minimum_size); auto xyz = convert_to_xyz (_frame, boost::bind(&Log::dcp_log, dcpomatic_log.get(), _1, _2)); @@ -226,7 +227,7 @@ DCPVideo::encode_remotely (EncodeServerDescription serv, int timeout) /* Send XML metadata */ auto xml = doc.write_to_string ("UTF-8"); socket->write (xml.length() + 1); - socket->write ((uint8_t *) xml.c_str(), xml.length() + 1); + socket->write ((uint8_t *) xml.c_str(), xml.bytes() + 1); /* Send binary data */ LOG_TIMING("start-remote-send thread=%1", thread_id ());