From 762251329bca80422a8e65d0cdb36e86e84883cf Mon Sep 17 00:00:00 2001
From: zhangmeng <775834166@qq.com>
Date: 星期五, 27 九月 2019 11:11:45 +0800
Subject: [PATCH] bug fix

---
 csrc/ffmpeg/format/FormatOut.hpp |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/csrc/ffmpeg/format/FormatOut.hpp b/csrc/ffmpeg/format/FormatOut.hpp
index 238d22f..9aa9b15 100644
--- a/csrc/ffmpeg/format/FormatOut.hpp
+++ b/csrc/ffmpeg/format/FormatOut.hpp
@@ -4,7 +4,6 @@
 #include <stdlib.h>
 #include <memory>
 #include <string>
-#include <vector>
 
 struct AVFormatContext;
 struct AVStream;
@@ -35,11 +34,12 @@
 		int encode(AVPacket *pkt, AVFrame *frame);
 
 	public:
-		bool copyCodecFromIn(std::vector<AVStream*> in);
+		bool addStream(AVStream *s);
+		bool copyCodecFromIn(AVStream *v, AVStream *a);
 		bool openResource(const char *filename, const int flags);
 		bool closeResource();
 
-		bool JustWriter(std::vector<AVStream*> in, const char *filename);
+		bool JustWriter(AVStream *v, AVStream *a, const char *filename);
 		bool EncodeWriter(const char *filename);
 		bool writeFrame(AVPacket *pkt, const int64_t &frame_cnt, bool interleaved = true);
 		void adjustPTS(AVPacket *pkt, const int64_t &frame_cnt);
@@ -73,7 +73,8 @@
 		std::string 			format_name_;
 
 		// rec
-		std::vector<AVStream*>  in_streams_;
+		AVStream  				*in_v_stream_;
+		AVStream  				*in_a_stream_;
 	};
 }
 #endif
\ No newline at end of file

--
Gitblit v1.8.0