diff options
author | Anton Khirnov <anton@khirnov.net> | 2024-03-22 21:22:22 +0100 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2024-03-28 08:40:11 +0100 |
commit | c9a90c052ab5304474cb6d2409870f1e480755c0 (patch) | |
tree | 27d10f336f80beec6559b1b2d0ec4484610a4400 | |
parent | e0de84ad2e25632b9a2f402f9e71a222c00567bb (diff) | |
download | ffmpeg-c9a90c052ab5304474cb6d2409870f1e480755c0.tar.gz |
fftools/ffmpeg_enc: stop copying demuxer side data to the muxer
All side data should be propagated through the trancoding pipeline.
-rw-r--r-- | fftools/ffmpeg_enc.c | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/fftools/ffmpeg_enc.c b/fftools/ffmpeg_enc.c index 260af435e9..6161e8e3d5 100644 --- a/fftools/ffmpeg_enc.c +++ b/fftools/ffmpeg_enc.c @@ -359,29 +359,6 @@ int enc_open(void *opaque, const AVFrame *frame) return ret; } - /* - * Add global input side data. For now this is naive, and copies it - * from the input stream's global side data. All side data should - * really be funneled over AVFrame and libavfilter, then added back to - * packet side data, and then potentially using the first packet for - * global side data. - */ - if (ist) { - for (int i = 0; i < ist->st->codecpar->nb_coded_side_data; i++) { - AVPacketSideData *sd_src = &ist->st->codecpar->coded_side_data[i]; - if (sd_src->type != AV_PKT_DATA_CPB_PROPERTIES) { - AVPacketSideData *sd_dst = av_packet_side_data_new(&ost->par_in->coded_side_data, - &ost->par_in->nb_coded_side_data, - sd_src->type, sd_src->size, 0); - if (!sd_dst) - return AVERROR(ENOMEM); - memcpy(sd_dst->data, sd_src->data, sd_src->size); - if (ist->autorotate && sd_src->type == AV_PKT_DATA_DISPLAYMATRIX) - av_display_rotation_set((int32_t *)sd_dst->data, 0); - } - } - } - // copy timebase while removing common factors if (ost->st->time_base.num <= 0 || ost->st->time_base.den <= 0) ost->st->time_base = av_add_q(ost->enc_ctx->time_base, (AVRational){0, 1}); |