1、根据PS获取时间戳

2、修复rtp代理可能花屏的问题
This commit is contained in:
xiongziliang
2019-12-16 11:00:40 +08:00
parent bfa9a3b678
commit c353c626c1
5 changed files with 53 additions and 17 deletions

View File

@@ -39,13 +39,13 @@ using namespace mediakit;
namespace mediakit{
string printSSRC(uint32_t ui32Ssrc);
class FrameMerger;
class RtpProcess : public RtpReceiver , public RtpDecoder , public PSDecoder {
public:
typedef std::shared_ptr<RtpProcess> Ptr;
RtpProcess(uint32_t ssrc);
~RtpProcess();
bool inputRtp(const char *data,int data_len, const struct sockaddr *addr);
bool inputRtp(const char *data,int data_len, const struct sockaddr *addr , uint32_t *dts_out = nullptr);
bool alive();
string get_peer_ip();
uint16_t get_peer_port();
@@ -70,8 +70,10 @@ private:
int _codecid_video = 0;
int _codecid_audio = 0;
MultiMediaSourceMuxer::Ptr _muxer;
std::shared_ptr<FrameMerger> _merger;
Ticker _last_rtp_time;
map<int,Stamp> _stamps;
uint32_t _dts = 0;
};
}//namespace mediakit