From c60d61c48c7a1e7b693d4c3f6427e3b616d1f471 Mon Sep 17 00:00:00 2001
From: zhangmeng <775834166@qq.com>
Date: 星期一, 21 十月 2019 12:29:33 +0800
Subject: [PATCH] update ffmpeg

---
 csrc/worker/rec.hpp |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/csrc/worker/rec.hpp b/csrc/worker/rec.hpp
index a19ea29..e79e332 100644
--- a/csrc/worker/rec.hpp
+++ b/csrc/worker/rec.hpp
@@ -23,9 +23,7 @@
     {
     private:
         ffwrapper::FormatIn *recRef_;
-        int     maxduration_;
-        int     minduration_;
-
+        int min_cache_len_;
         // 褰曞儚鐨勫疄渚�,瀵瑰簲浠诲姟
         std::unordered_map<std::string, std::unique_ptr<buz::Recorder> > map_rec_;
         // 澶氱嚎绋嬫坊鍔犱换鍔″疄渚�,鍦ㄨ娴佺嚎绋嬩娇鐢ㄥ綍鍍�,浣嗘槸娣诲姞鍦ㄥ彟涓�涓嚎绋�
@@ -54,11 +52,11 @@
         // 涓㈠純缂撳瓨
         int shrinkCache();
         // 鍒涘缓褰曞儚瀹炰緥寮�濮嬪綍鍍�
-        std::unique_ptr<buz::Recorder> startRec(std::string id, std::string dir, const int mind, const int maxd, const bool audio);
+        std::unique_ptr<buz::Recorder> startRec(std::string id, std::string dir, const int64_t &frameID, const int mind, const int maxd, const bool audio);
         // 娓呴櫎缂撳瓨,鏂嚎閲嶈繛鏃堕渶瑕�
         void clear();
     public:
-        void NewRec(const char* id, const char *output, const int mindur, const int maxdur, const bool audio);
+        void NewRec(const char* id, const char *output, const int64_t &frameID, const int mindur, const int maxdur, const bool audio);
 
         // 鍑嗗濂藉綍鍍�
         void Load(ffwrapper::FormatIn *in);
@@ -71,6 +69,8 @@
         // 鑾峰彇褰曞儚鏂囦欢璺緞鍜屽抚id
         void GetRecInfo(std::string &recID, int &index, std::string &path);
         
+        // 璁剧疆褰曞埗鏃堕暱浣滀负缂撳瓨
+        void SetRecMinCacheTime(const int min);
     public:
         rec();
         ~rec();

--
Gitblit v1.8.0