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

For #1659, #307, add switch to disable rtc

This commit is contained in:
winlin 2020-03-22 18:17:05 +08:00
parent 37c84eccc0
commit 602a478e1b
12 changed files with 133 additions and 28 deletions

View file

@ -325,6 +325,7 @@ public:
virtual SrsSharedPtrMessage* pop();
};
#ifdef SRS_AUTO_RTC
// To find the RTP packet for RTX or restore.
class SrsRtpPacketQueue
{
@ -347,6 +348,7 @@ public:
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,
@ -360,8 +362,10 @@ private:
private:
// The format, codec information.
SrsRtmpFormat* format;
#ifdef SRS_AUTO_RTC
// rtc handler
SrsRtc* rtc;
#endif
// hls handler.
SrsHls* hls;
// The DASH encoder.
@ -534,8 +538,10 @@ private:
bool mix_correct;
// The mix queue to implements the mix correct algorithm.
SrsMixQueue* mix_queue;
#ifdef SRS_AUTO_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,
@ -625,8 +631,10 @@ public:
public:
virtual std::string get_curr_origin();
public:
#ifdef SRS_AUTO_RTC
// Find rtp packet by sequence
SrsRtpSharedPacket* find_rtp_packet(const uint16_t& seq);
#endif
};
#endif