From cd3fe8cc1ae9028acb4f630ed16c12f4fb327f3c Mon Sep 17 00:00:00 2001 From: zhangmeng <775834166@qq.com> Date: 星期四, 10 十月 2019 17:35:12 +0800 Subject: [PATCH] add interface out --- csrc/worker/rec.hpp | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-) diff --git a/csrc/worker/rec.hpp b/csrc/worker/rec.hpp index c489676..a19ea29 100644 --- a/csrc/worker/rec.hpp +++ b/csrc/worker/rec.hpp @@ -2,12 +2,13 @@ #define _cffmpeg_rec_hpp_ #include <string> -#include <memory> #include <unordered_map> #include <list> #include <mutex> #include "../buz/recorder.hpp" + +struct AVPacket; namespace ffwrapper { @@ -41,7 +42,7 @@ std::mutex mtx_recInfo_; // 缂撳瓨鐨勮棰戝抚,绛夊緟firerecsignal瑙﹀彂寮�濮嬪綍鍍� - std::list<buz::CPacket> list_pkt_; + std::list<CPacket> list_pkt_; // 澶氱嚎绋�,鐢熶骇鑰呯嚎绋媟eader push pkt,娑堣垂鑰�,褰曞儚绾跨▼pop std::mutex mtx_pkt_; @@ -53,11 +54,11 @@ // 涓㈠純缂撳瓨 int shrinkCache(); // 鍒涘缓褰曞儚瀹炰緥寮�濮嬪綍鍍� - std::unique_ptr<buz::Recorder> startRec(std::string id, std::string dir, const int mind, const int maxd); + std::unique_ptr<buz::Recorder> startRec(std::string id, std::string dir, 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); + void NewRec(const char* id, const char *output, const int mindur, const int maxdur, const bool audio); // 鍑嗗濂藉綍鍍� void Load(ffwrapper::FormatIn *in); -- Gitblit v1.8.0