video analysis2.0拆分,ffmpeg封装go接口库
zhangmeng
2019-07-30 a6f5c0ca80b2fdd53351d5957a659a939f530fc2
csrc/buz/recorder.cpp
@@ -82,6 +82,9 @@
        void Recorder::end_writer(){
            if(cur_frame == -1) return;
            out_->endWriter();
            logIt("INDEX %d, FILE %s, CURFrame %d, ENDFrame %d\n",
                 file_frame_index_, file_path_.c_str(), cur_frame, end_frame);
            //reinit cur_frame clear list pkt
            {
                std::lock_guard<std::mutex> locker(mutex_pkt_);
@@ -92,7 +95,6 @@
            //callback to frame index and path
            if(func_rec_info_){
                func_rec_info_(id_,file_frame_index_, file_path_);
                // logIt("recoder index %d, file name %s\n", file_frame_index_, file_path_.c_str());
            }else{
                // logIt("recorder has no func_rec_info");
            }
@@ -187,6 +189,7 @@
                    end_frame = maxduration;
                }
            }
            logIt("FIRE REC FRAME ID: %lld", id);
            return 0;
        }
@@ -216,6 +219,7 @@
                cv_.notify_one();
            }
            logIt("CACHE PACKET FRAME ID %lld", pkt.id);
            return 0;
        }