兼容rtmps rtsps的推流地址

This commit is contained in:
xiongziliang 2021-03-07 10:04:58 +08:00
parent 43828d4390
commit bd9769d215

View File

@ -102,7 +102,7 @@ int domain(const string & filePath,const string & pushUrl){
Logger::Instance().setWriter(std::make_shared<AsyncLogWriter>()); Logger::Instance().setWriter(std::make_shared<AsyncLogWriter>());
auto poller = EventPollerPool::Instance().getPoller(); auto poller = EventPollerPool::Instance().getPoller();
//vhost/app/stream可以随便自己填现在不限制app应用名了 //vhost/app/stream可以随便自己填现在不限制app应用名了
createPusher(poller,FindField(pushUrl.data(), nullptr,"://"),DEFAULT_VHOST,"live","stream",filePath,pushUrl); createPusher(poller,FindField(pushUrl.data(), nullptr,"://").substr(0,4),DEFAULT_VHOST,"live","stream",filePath,pushUrl);
//设置退出信号处理函数 //设置退出信号处理函数
static semaphore sem; static semaphore sem;