From 55337c3876fa54863463ab7c30a7ed0fcb3c88e5 Mon Sep 17 00:00:00 2001 From: chenshijun <chenshijun@aiotlink.com> Date: 星期四, 21 三月 2019 14:43:15 +0800 Subject: [PATCH] facesearchserver出现段错误,map的operater[],疑似该处,加些调试信息。 --- QiaoJiaSystem/GB28181DecoderModel/FFmpegDecoderJPG.h | 18 +++++++++++++++--- 1 files changed, 15 insertions(+), 3 deletions(-) diff --git a/QiaoJiaSystem/GB28181DecoderModel/FFmpegDecoderJPG.h b/QiaoJiaSystem/GB28181DecoderModel/FFmpegDecoderJPG.h index 1f495fc..dcfa1d2 100644 --- a/QiaoJiaSystem/GB28181DecoderModel/FFmpegDecoderJPG.h +++ b/QiaoJiaSystem/GB28181DecoderModel/FFmpegDecoderJPG.h @@ -13,13 +13,12 @@ #include <iostream> #include <unistd.h> #include <MyQueue.h> -#include <Debug.h> #include <atomic> -#include "GlobalSignalWaitLock.hpp" #include "opencv2/core.hpp" #include "opencv2/highgui.hpp" #include <list> +#include "GlobalSignalWaitLock.hpp" #include "basic_struct_for_video_image.h" extern "C" @@ -167,7 +166,18 @@ //瀵规敹鍒扮殑甯ц繘琛岃鏁� int64_t m_frameIndex = 0; +//******************************************* + AVFormatContext *ic; + unsigned char *iobuffer; + AVIOContext *avio; + AVStream *stream; + AVCodecContext *ctx; + AVCodec *codec; + AVCodec *codec_cuvid; + AVPacket pkt; + AVFrame *frame; + //******************************************* //灏嗗抚淇濆瓨鍒板抚鏁扮粍 void SaveToPacketVector(AVPacket &packet); @@ -189,7 +199,8 @@ int stopWrite(); //瀵筽acket鍋氳浆鎹� - void conversion(void *packet, const long int &firstKeyPts, const long int &firstKeyDts, void *inVideoStream); + void conversion(void *packet, const long int &firstKeyPts, const long int &firstKeyDts, void *inVideoStream, + unsigned long int frame_index = 0); bool m_bstartWrite = {false}; bool m_bFirstKeyFrame = {false}; @@ -216,6 +227,7 @@ int m_gpuIdx; int m_fps; bool m_PackageState; + bool m_SnapshotNotSaveRet{true}; std::string m_camIdx; MyQueue<frameBuffInfo *> m_rtpQueue; -- Gitblit v1.8.0