mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-12-25 04:11:44 +00:00
mkvmerge: allow appending video tracks with differing pixel dimensions
Implements #2582.
This commit is contained in:
parent
1aefcdc2cb
commit
2548a7f349
8
NEWS.md
8
NEWS.md
@ -1,3 +1,11 @@
|
||||
# Version ?
|
||||
|
||||
## New features and enhancements
|
||||
|
||||
* mkvmerge: mkvmerge now allows appending AV1, VP8, VP9, h.264/AVC and
|
||||
h.265/HEVC tracks whose pixel dimensions differ. Implements #2582.
|
||||
|
||||
|
||||
# Version 35.0.0 "All The Love In The World" 2019-06-22
|
||||
|
||||
## New features and enhancements
|
||||
|
@ -142,14 +142,11 @@ av1_video_packetizer_c::set_is_unframed() {
|
||||
|
||||
connection_result_e
|
||||
av1_video_packetizer_c::can_connect_to(generic_packetizer_c *src,
|
||||
std::string &error_message) {
|
||||
std::string &) {
|
||||
auto psrc = dynamic_cast<av1_video_packetizer_c *>(src);
|
||||
if (!psrc)
|
||||
return CAN_CONNECT_NO_FORMAT;
|
||||
|
||||
connect_check_v_width( m_hvideo_pixel_width, psrc->m_hvideo_pixel_width);
|
||||
connect_check_v_height(m_hvideo_pixel_height, psrc->m_hvideo_pixel_height);
|
||||
|
||||
return CAN_CONNECT_YES;
|
||||
}
|
||||
|
||||
|
@ -128,10 +128,6 @@ avc_video_packetizer_c::can_connect_to(generic_packetizer_c *src,
|
||||
if (!vsrc)
|
||||
return CAN_CONNECT_NO_FORMAT;
|
||||
|
||||
auto result = generic_video_packetizer_c::can_connect_to(src, error_message);
|
||||
if (CAN_CONNECT_YES != result)
|
||||
return result;
|
||||
|
||||
if (m_ti.m_private_data && vsrc->m_ti.m_private_data && memcmp(m_ti.m_private_data->get_buffer(), vsrc->m_ti.m_private_data->get_buffer(), m_ti.m_private_data->get_size())) {
|
||||
error_message = fmt::format(Y("The codec's private data does not match. Both have the same length ({0}) but different content."), m_ti.m_private_data->get_size());
|
||||
return CAN_CONNECT_MAYBE_CODECPRIVATE;
|
||||
|
@ -231,9 +231,6 @@ avc_es_video_packetizer_c::can_connect_to(generic_packetizer_c *src,
|
||||
if (!vsrc)
|
||||
return CAN_CONNECT_NO_FORMAT;
|
||||
|
||||
connect_check_v_width( m_hvideo_pixel_width, vsrc->m_hvideo_pixel_width);
|
||||
connect_check_v_height(m_hvideo_pixel_height, vsrc->m_hvideo_pixel_height);
|
||||
connect_check_codec_id(m_hcodec_id, vsrc->m_hcodec_id);
|
||||
connect_check_codec_private(src);
|
||||
|
||||
return CAN_CONNECT_YES;
|
||||
|
@ -96,10 +96,6 @@ hevc_video_packetizer_c::can_connect_to(generic_packetizer_c *src,
|
||||
if (!vsrc)
|
||||
return CAN_CONNECT_NO_FORMAT;
|
||||
|
||||
auto result = generic_video_packetizer_c::can_connect_to(src, error_message);
|
||||
if (CAN_CONNECT_YES != result)
|
||||
return result;
|
||||
|
||||
if (m_ti.m_private_data && vsrc->m_ti.m_private_data && memcmp(m_ti.m_private_data->get_buffer(), vsrc->m_ti.m_private_data->get_buffer(), m_ti.m_private_data->get_size())) {
|
||||
error_message = fmt::format(Y("The codec's private data does not match. Both have the same length ({0}) but different content."), m_ti.m_private_data->get_size());
|
||||
return CAN_CONNECT_MAYBE_CODECPRIVATE;
|
||||
|
@ -212,9 +212,6 @@ hevc_es_video_packetizer_c::can_connect_to(generic_packetizer_c *src,
|
||||
if (!vsrc)
|
||||
return CAN_CONNECT_NO_FORMAT;
|
||||
|
||||
connect_check_v_width( m_hvideo_pixel_width, vsrc->m_hvideo_pixel_width);
|
||||
connect_check_v_height(m_hvideo_pixel_height, vsrc->m_hvideo_pixel_height);
|
||||
connect_check_codec_id(m_hcodec_id, vsrc->m_hcodec_id);
|
||||
connect_check_codec_private(src);
|
||||
|
||||
return CAN_CONNECT_YES;
|
||||
|
@ -121,9 +121,6 @@ vpx_video_packetizer_c::can_connect_to(generic_packetizer_c *src,
|
||||
|
||||
connect_check_codec_id(m_hcodec_id, psrc->m_hcodec_id);
|
||||
|
||||
connect_check_v_width(m_hvideo_pixel_width, psrc->m_hvideo_pixel_width);
|
||||
connect_check_v_height(m_hvideo_pixel_height, psrc->m_hvideo_pixel_height);
|
||||
|
||||
return CAN_CONNECT_YES;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user