时间戳统一使用毫秒

This commit is contained in:
xiongziliang
2018-10-26 14:12:16 +08:00
parent e816c56f2e
commit 8f8eda9337
24 changed files with 188 additions and 100 deletions

View File

@@ -84,7 +84,7 @@ public:
}
return track->_seq;
}
virtual uint32_t getTimestamp(TrackType trackType) {
virtual uint32_t getTimeStamp(TrackType trackType) {
auto track = _sdpAttr.getTrack(trackType);
if(!track){
return 0;
@@ -92,6 +92,13 @@ public:
return track->_time_stamp;
}
void updateTimeStamp(uint32_t uiStamp) {
auto tracks = _sdpAttr.getAvailableTrack();
for (auto &track : tracks) {
track->_time_stamp = uiStamp;
}
}
virtual void onGetSDP(const string& sdp) {
//派生类设置该媒体源媒体描述信息
_strSdp = sdp;