Commit 7442c1d45aca53de7582aff6b1e59787769aa463
1 parent
56fcdd82
视频流关键帧标记保存
Showing
1 changed file
with
7 additions
and
1 deletions
src/decoder/dvpp/DvppStreamDecoder.cpp
... | ... | @@ -454,6 +454,12 @@ int DvppStreamDecoder::SendData(int videoType, char* data, int len, int isKey, u |
454 | 454 | pkt->size = len; |
455 | 455 | pkt->data = (uint8_t*)data; |
456 | 456 | |
457 | + if (isKey) { | |
458 | + pkt->flags = 1; | |
459 | + } else { | |
460 | + pkt->flags = 0; | |
461 | + } | |
462 | + | |
457 | 463 | do |
458 | 464 | { |
459 | 465 | int vdec_out_size = parse_stream_info(videoType, pkt); |
... | ... | @@ -596,7 +602,7 @@ int DvppStreamDecoder::parse_stream_info(int videoType, AVPacket* pkt) { |
596 | 602 | } while (0); |
597 | 603 | |
598 | 604 | #ifdef USE_VILLAGE |
599 | - bool bRet = m_recoderManager.init2(frame->width, frame->height, m_fps, avctx->bit_rate); | |
605 | + bool bRet = m_recoderManager.init(frame->width, frame->height, m_fps, avctx->bit_rate); | |
600 | 606 | if (!bRet){ |
601 | 607 | LOG_ERROR("[{}]- m_recoderManager 初始化失败!", m_dec_name); |
602 | 608 | } | ... | ... |