mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2026-04-22 23:17:48 +08:00
fixup! lavc/rkmppenc: add RKMPP H264 and HEVC encoder
fix global_header (extradata) cannot be disabled. Signed-off-by: nyanmisaka <nst799610810@gmail.com>
This commit is contained in:
@@ -1214,8 +1214,9 @@ static av_cold int rkmpp_encode_init(AVCodecContext *avctx)
|
||||
else if (avctx->codec_id == AV_CODEC_ID_MJPEG)
|
||||
r->async_frames = MJPEG_ASYNC_FRAMES;
|
||||
|
||||
if (avctx->codec_id == AV_CODEC_ID_H264 ||
|
||||
avctx->codec_id == AV_CODEC_ID_HEVC) {
|
||||
if ((avctx->flags & AV_CODEC_FLAG_GLOBAL_HEADER) &&
|
||||
(avctx->codec_id == AV_CODEC_ID_H264 ||
|
||||
avctx->codec_id == AV_CODEC_ID_HEVC)) {
|
||||
RK_U8 enc_hdr_buf[H26X_HEADER_SIZE];
|
||||
size_t pkt_len = 0;
|
||||
void *pkt_pos = NULL;
|
||||
|
||||
Reference in New Issue
Block a user