video analysis2.0拆分,ffmpeg封装go接口库
zhangmeng
2020-10-22 65eb475b323b3b9c28761b4e3009ab3d269963e1
csrc/ffmpeg/format/FormatIn.hpp
@@ -3,7 +3,6 @@
#include <stdint.h>
#include <memory>
#include <vector>
#include "PsToEs.hpp"
struct AVFormatContext;
@@ -25,6 +24,7 @@
   {
   public:
      explicit FormatIn(bool hw=true);
      explicit FormatIn(const VideoProp &prop, bool hw=true);
      ~FormatIn();
      
   public:
@@ -47,16 +47,19 @@
      bool allocCodec(AVCodec *dec, AVStream *s, AVDictionary **options);
   public:
      AVStream *getStream(int type = -1);
      std::vector<AVStream*> allStreams();
      AVCodecContext *getCodecContext(int type = 0);
      AVFormatContext *getFromatContext(){return ctx_;}
      const double getFPS()const{return fps_;}
      const bool IsHEVC()const;
      const bool IsAVC1()const;
   private:
       AVFormatContext    *ctx_;
       AVCodecContext       *dec_ctx_;
       int             vs_idx_;
      int             as_idx_;
      VideoProp          *prop_;
       bool             hw_accl_;
      double             fps_;
   private: