mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
refine code for consumer to refer the rtmp connection.
This commit is contained in:
parent
d3139c52cc
commit
eca46c03d2
5 changed files with 14 additions and 10 deletions
|
@ -51,6 +51,7 @@ class SrsStSocket;
|
|||
class SrsRtmpServer;
|
||||
class SrsEdgeProxyContext;
|
||||
class SrsMessageArray;
|
||||
class SrsConnection;
|
||||
#ifdef SRS_AUTO_HLS
|
||||
class SrsHls;
|
||||
#endif
|
||||
|
@ -224,6 +225,8 @@ private:
|
|||
SrsRtmpJitter* jitter;
|
||||
SrsSource* source;
|
||||
SrsMessageQueue* queue;
|
||||
// the owner connection for debug, maybe NULL.
|
||||
SrsConnection* conn;
|
||||
bool paused;
|
||||
// when source id changed, notice all consumers
|
||||
bool should_update_source_id;
|
||||
|
@ -236,7 +239,7 @@ private:
|
|||
int mw_duration;
|
||||
#endif
|
||||
public:
|
||||
SrsConsumer(SrsSource* _source);
|
||||
SrsConsumer(SrsSource* s, SrsConnection* c);
|
||||
virtual ~SrsConsumer();
|
||||
public:
|
||||
/**
|
||||
|
@ -571,7 +574,7 @@ public:
|
|||
* @param dg, whether dumps the gop cache.
|
||||
*/
|
||||
virtual int create_consumer(
|
||||
SrsConsumer*& consumer,
|
||||
SrsConnection* conn, SrsConsumer*& consumer,
|
||||
bool ds = true, bool dm = true, bool dg = true
|
||||
);
|
||||
virtual void on_consumer_destroy(SrsConsumer* consumer);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue