mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-06-22 00:42:22 +08:00
完善PlayerProxy关闭机制,重试次数超限后自动关闭
This commit is contained in:
@@ -34,15 +34,15 @@ public:
|
||||
|
||||
/**
|
||||
* 设置play结果回调,只触发一次;在play执行之前有效
|
||||
* @param cb
|
||||
* @param cb 回调对象
|
||||
*/
|
||||
void setPlayCallbackOnce(const function<void(const SockException &ex)> &cb);
|
||||
|
||||
/**
|
||||
* 设置主动关闭回调
|
||||
* @param cb
|
||||
* @param cb 回调对象
|
||||
*/
|
||||
void setOnClose(const function<void()> &cb);
|
||||
void setOnClose(const function<void(const SockException &ex)> &cb);
|
||||
|
||||
/**
|
||||
* 开始拉流播放
|
||||
@@ -76,7 +76,7 @@ private:
|
||||
string _stream_id;
|
||||
string _pull_url;
|
||||
Timer::Ptr _timer;
|
||||
function<void()> _on_close;
|
||||
function<void(const SockException &ex)> _on_close;
|
||||
function<void(const SockException &ex)> _on_play;
|
||||
MultiMediaSourceMuxer::Ptr _muxer;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user