[FFmpeg-devel] [PATCH 2/6] h264_metadata: Remove redundant setting of SEI payload size

Mark Thompson sw at jkqxz.net
Tue May 8 02:11:27 EEST 2018


This should be derived from the data length rather than set explicitly.
---
 libavcodec/h264_metadata_bsf.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/libavcodec/h264_metadata_bsf.c b/libavcodec/h264_metadata_bsf.c
index 27053dbdcf..1fbc5e3282 100644
--- a/libavcodec/h264_metadata_bsf.c
+++ b/libavcodec/h264_metadata_bsf.c
@@ -341,8 +341,6 @@ static int h264_metadata_filter(AVBSFContext *bsf, AVPacket *out)
             udu->data_length = len + 1;
             memcpy(udu->data, ctx->sei_user_data + i + 1, len + 1);
 
-            payload.payload_size = 16 + udu->data_length;
-
             err = ff_cbs_h264_add_sei_message(ctx->cbc, au, &payload);
             if (err < 0) {
                 av_log(bsf, AV_LOG_ERROR, "Failed to add user data SEI "
-- 
2.16.3



More information about the ffmpeg-devel mailing list