修复编译问题

This commit is contained in:
xiongziliang 2019-03-27 18:58:43 +08:00
parent e44c2d5508
commit 5e7260c723
3 changed files with 3 additions and 3 deletions

View File

@ -70,7 +70,7 @@ int main(int argc, char *argv[]) {
player->setOnShutdown([&](const SockException &ex) { player->setOnShutdown([&](const SockException &ex) {
--alivePlayerCnt; --alivePlayerCnt;
}); });
(*player)[RtspPlayer::kRtpType] = atoi(argv[4]); (*player)[kRtpType] = atoi(argv[4]);
player->play(argv[3]); player->play(argv[3]);
playerList.push_back(player); playerList.push_back(player);
return playerCnt--; return playerCnt--;

View File

@ -90,7 +90,7 @@ int main(int argc, char *argv[]) {
player->setOnShutdown([](const SockException &ex) { player->setOnShutdown([](const SockException &ex) {
ErrorL << "OnShutdown:" << ex.what(); ErrorL << "OnShutdown:" << ex.what();
}); });
(*player)[RtspPlayer::kRtpType] = atoi(argv[2]); (*player)[kRtpType] = atoi(argv[2]);
player->play(argv[1]); player->play(argv[1]);
SDLDisplayerHelper::Instance().runLoop(); SDLDisplayerHelper::Instance().runLoop();

View File

@ -259,7 +259,7 @@ int main(int argc,char *argv[]) {
PlayerProxy::Ptr player(new PlayerProxy(DEFAULT_VHOST, "live", to_string(i).data())); PlayerProxy::Ptr player(new PlayerProxy(DEFAULT_VHOST, "live", to_string(i).data()));
//指定RTP over TCP(播放rtsp时有效) //指定RTP over TCP(播放rtsp时有效)
(*player)[RtspPlayer::kRtpType] = Rtsp::RTP_TCP; (*player)[kRtpType] = Rtsp::RTP_TCP;
//开始播放,如果播放失败或者播放中止,将会自动重试若干次,重试次数在配置文件中配置,默认一直重试 //开始播放,如果播放失败或者播放中止,将会自动重试若干次,重试次数在配置文件中配置,默认一直重试
player->play(url); player->play(url);
//需要保存PlayerProxy否则作用域结束就会销毁该对象 //需要保存PlayerProxy否则作用域结束就会销毁该对象