在使用FFmpeg解码数据后int frameFinished = 0; avcodec_decode_video2(pCodecCtx, pFrame, &fram...
avcodec_send_packet函数返回-1094995529错误,根据FFmpeg的错误信息,得知为AVERROR_INVALIDDATA,猜测是第一种情况 在调用h264_slice_header_parse函数的时候,出现了错误,无法定位PPS 函数的调用逻辑 static int decode_nal_units(H264Context *h, const uint8_t *buf, int buf_size) int ff_h264_queue_decode_...
pObj->h264Params.inputDataMode = 1; pObj->h264Params.sliceFormat = 1; pObj->h264Params.viddecParams = pObj->params; pObj->h264Params.viddecParams.size = sizeof(pObj->h264Params); /* Create video decoder instance */ pObj->hDecode = VIDDEC2_create(gALG_hEngine, pObj->algNam...
decPrm.tilerEnable = FALSE; decPrm.numBufPerPool[0] = 4;//NUM_DECODE_BUFFERS; System_linkCreate(decLinkId, &decPrm, sizeof(decPrm)); 我查了下h264 decoder的pdf文档:0x401的错误为: 0bit--Error code(IH264VDEC_ERR_NOSLICE) --Explanation(Not even a ...
[h264 @ 003FB810]decode_slice_header error [h264 @ 003FB810]no frame! [h264 @ 003FB810]non-existing PPS referenced [h264 @ 003FB810]decode_slice_header error [h264 @ 003FB810]no frame! [h264 @ 003FB810]non-existing PPS referenced ...
] for help [h264 @ 0x55a97aea60] Missing reference picture, default is 0 [h264 @ 0x55a97aea60] decode_slice_header error [h264 @ 0x55a97aba50] SEI type 1 size 1040 truncated at 832 [h264 @ 0x55a9761740] SEI type 1 size 1040 truncated at 832 (...skip) frame= 0 fps=0.0...
av_log(avctx, AV_LOG_WARNING,"Error resilience with slice threads is enabled. It is unsafe and unsupported and may crash.""Use it at your own risk\n"); }return0; } h264_decode_init主要是一些基本参数的初始化,还有熵编码器初始化和解析extradata。
.init = ff_h264_decode_init, .close = ff_h264_decode_end, .decode = decode_frame, .capabilities = /*CODEC_CAP_DRAW_HORIZ_BAND |*/ CODEC_CAP_DR1 | CODEC_CAP_DELAY | CODEC_CAP_SLICE_THREADS | CODEC_CAP_FRAME_THREADS, .flush= flush_dpb, ...
[h264 @ 0000021230232f00] decode_slice_header error [h264 @ 0000021230232f00] no frame![h264 @ 0000021230232f00] pps_id3199971767out of range [h264 @ 0000021230232f00] Invalid NAL unit0, skipping. Invalid UE golomb code [h264 @ 0000021230232f00] non-existing PPS5referenced ...
之后开始不断读取一段段NALU数据(可以是SPS/PPS/SE连续数据单元+SLICE/SLICE_IDR数据单元,也可以是一个SLICE数据单元,或者是一个SLICE_IDR数据单元)。 下面看h264格式文件读取的代码。这个函数返回读取一段NALU数据的长度,数据会拷贝到buf指针处,当header为1是是读取文件头信息,为0时时正常读取一段NALU数据。