1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

Remove usused RTP shared packet.

This commit is contained in:
winlin 2020-05-02 10:24:31 +08:00
parent 42ee52fa29
commit 5c43037190
9 changed files with 16 additions and 534 deletions

View file

@ -62,7 +62,6 @@ class SrsBuffer;
#ifdef SRS_HDS
class SrsHds;
#endif
class SrsRtpSharedPacket;
#ifdef SRS_RTC
class SrsRtcPublisher;
#endif
@ -336,32 +335,6 @@ public:
virtual SrsSharedPtrMessage* pop();
};
#ifdef SRS_RTC
// To find the RTP packet for RTX or restore.
// TODO: FIXME: Should queue RTP packets in connection level.
class SrsRtpPacketQueue
{
private:
struct SeqComp
{
bool operator()(const uint16_t& l, const uint16_t& r) const
{
return ((int16_t)(r - l)) > 0;
}
};
private:
std::map<uint16_t, SrsRtpSharedPacket*, SeqComp> pkt_queue;
public:
SrsRtpPacketQueue();
virtual ~SrsRtpPacketQueue();
public:
void clear();
void push(std::vector<SrsRtpSharedPacket*>& pkts);
void insert(const uint16_t& sequence, SrsRtpSharedPacket* pkt);
SrsRtpSharedPacket* find(const uint16_t& sequence);
};
#endif
// The hub for origin is a collection of utilities for origin only,
// For example, DVR, HLS, Forward and Transcode are only available for origin,
// they are meanless for edge server.
@ -550,10 +523,6 @@ private:
bool mix_correct;
// The mix queue to implements the mix correct algorithm.
SrsMixQueue* mix_queue;
#ifdef SRS_RTC
// rtp packet queue
SrsRtpPacketQueue* rtp_queue;
#endif
// For play, whether enabled atc.
// The atc(use absolute time and donot adjust time),
// directly use msg time and donot adjust if atc is true,
@ -650,8 +619,6 @@ public:
virtual std::string get_curr_origin();
#ifdef SRS_RTC
public:
// Find rtp packet by sequence
SrsRtpSharedPacket* find_rtp_packet(const uint16_t& seq);
// Get the cached meta, as such the sps/pps.
SrsMetaCache* cached_meta();
// Request keyframe for new client.