diff --git a/src/decoder/dvpp/DvppDataMemory.hpp b/src/decoder/dvpp/DvppDataMemory.hpp index 5542e71..2286532 100644 --- a/src/decoder/dvpp/DvppDataMemory.hpp +++ b/src/decoder/dvpp/DvppDataMemory.hpp @@ -30,8 +30,6 @@ public: pHwRgb = pHwData; } - - DvppDataMemory(DvppDataMemory* pSrc):DeviceMemory(-1, pSrc->getWidth(), pSrc->getWidthStride(), pSrc->getHeight(), pSrc->getHeightStride(), pSrc->getId(), pSrc->getDeviceId(), pSrc->isKeyFrame(), pSrc->getFrameNb(), false){ if(pSrc == nullptr) { LOG_ERROR("[{}]- pSrc is nullptr", pSrc->getId()); diff --git a/src/decoder/dvpp/FFRecoderTaskManager.cpp b/src/decoder/dvpp/FFRecoderTaskManager.cpp index 0b870bf..20b895a 100644 --- a/src/decoder/dvpp/FFRecoderTaskManager.cpp +++ b/src/decoder/dvpp/FFRecoderTaskManager.cpp @@ -25,7 +25,6 @@ static bool is_key_frame(AVPacket *pkt) { } FFRecoderTaskManager::FFRecoderTaskManager(){ - m_recoder_thread = nullptr; m_cache_thread = nullptr; m_bExit = false; @@ -127,7 +126,7 @@ void FFRecoderTaskManager::create_recode_task(RecoderInfo& recoderInfo) { void FFRecoderTaskManager::pkt_cache_thread() { LOG_INFO("pkt_cache_thread start..."); - m_recoder_thread = new std::thread( + thread* recoder_thread = new std::thread( [](void* arg) { FFRecoderTaskManager* _this=(FFRecoderTaskManager*)arg; if(_this != nullptr) { @@ -172,10 +171,10 @@ void FFRecoderTaskManager::pkt_cache_thread() { m_bExitRecoderThread = true; - if (m_recoder_thread) { - m_recoder_thread->join(); - delete m_recoder_thread; - m_recoder_thread = nullptr; + if (recoder_thread) { + recoder_thread->join(); + delete recoder_thread; + recoder_thread = nullptr; } // 清空数据 @@ -253,7 +252,7 @@ void FFRecoderTaskManager::recode_thread() { end_frame_nb = (*it_save)->frame_nb; } - ffrecoder.flush(); + // ffrecoder.flush(); ffrecoder.uninit(); // 发送mq消息 diff --git a/src/decoder/dvpp/FFRecoderTaskManager.h b/src/decoder/dvpp/FFRecoderTaskManager.h index dd731e0..b9a14ff 100644 --- a/src/decoder/dvpp/FFRecoderTaskManager.h +++ b/src/decoder/dvpp/FFRecoderTaskManager.h @@ -55,7 +55,6 @@ private: AVCodecContext* m_avctx; AVStream* m_inStream; - thread* m_recoder_thread{nullptr}; thread* m_cache_thread{nullptr}; mq_callback_t mq_publish_func;