重新mp4录制

This commit is contained in:
xiongziliang
2019-08-01 18:49:04 +08:00
parent 12e1068a39
commit 383a14a76d
14 changed files with 470 additions and 417 deletions

View File

@@ -117,6 +117,12 @@ public:
*/
virtual bool keyFrame() const = 0;
/**
* 是否为配置帧譬如sps pps vps
* @return
*/
virtual bool configFrame() const = 0;
/**
* 是否可以缓存
*/
@@ -371,6 +377,7 @@ public:
_trackType = frame->getTrackType();
_codec = frame->getCodecId();
_key = frame->keyFrame();
_config = frame->configFrame();
}
virtual ~FrameCacheAble() = default;
@@ -394,12 +401,17 @@ public:
bool keyFrame() const override{
return _key;
}
bool configFrame() const override{
return _config;
}
private:
Frame::Ptr _frame;
BufferRaw::Ptr _buffer;
TrackType _trackType;
CodecId _codec;
bool _key;
bool _config;
};