mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
GB28181: Refine SRS listeners without wrapper.
This commit is contained in:
parent
b452144fb7
commit
173c683566
13 changed files with 601 additions and 762 deletions
|
@ -26,11 +26,27 @@ class SrsRawAacStream;
|
|||
struct SrsRawAacStreamCodec;
|
||||
class SrsPithyPrint;
|
||||
class SrsSimpleRtmpClient;
|
||||
class SrsMpegtsOverUdp;
|
||||
|
||||
#include <srs_app_st.hpp>
|
||||
#include <srs_kernel_ts.hpp>
|
||||
#include <srs_app_listener.hpp>
|
||||
|
||||
// A UDP listener, for udp stream caster server.
|
||||
class SrsUdpCasterListener : public ISrsListener
|
||||
{
|
||||
private:
|
||||
SrsUdpListener* listener_;
|
||||
SrsMpegtsOverUdp* caster_;
|
||||
public:
|
||||
SrsUdpCasterListener();
|
||||
virtual ~SrsUdpCasterListener();
|
||||
public:
|
||||
srs_error_t initialize(SrsConfDirective* conf);
|
||||
srs_error_t listen();
|
||||
void close();
|
||||
};
|
||||
|
||||
// The queue for mpegts over udp to send packets.
|
||||
// For the aac in mpegts contains many flv packets in a pes packet,
|
||||
// we must recalc the timestamp.
|
||||
|
@ -72,8 +88,10 @@ private:
|
|||
SrsMpegtsQueue* queue;
|
||||
SrsPithyPrint* pprint;
|
||||
public:
|
||||
SrsMpegtsOverUdp(SrsConfDirective* c);
|
||||
SrsMpegtsOverUdp();
|
||||
virtual ~SrsMpegtsOverUdp();
|
||||
public:
|
||||
srs_error_t initialize(SrsConfDirective* c);
|
||||
// Interface ISrsUdpHandler
|
||||
public:
|
||||
virtual srs_error_t on_udp_packet(const sockaddr* from, const int fromlen, char* buf, int nb_buf);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue