mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2024-11-22 19:00:01 +08:00
添加mk_rtp_server_start接口
This commit is contained in:
parent
be5d98b968
commit
4e1876fab8
@ -140,10 +140,12 @@ API_EXPORT uint16_t API_CALL mk_rtp_server_start(uint16_t port){
|
|||||||
#ifdef ENABLE_RTPPROXY
|
#ifdef ENABLE_RTPPROXY
|
||||||
try {
|
try {
|
||||||
//创建rtp tcp服务器
|
//创建rtp tcp服务器
|
||||||
|
tcpRtpServer = std::make_shared<TcpServer>();
|
||||||
tcpRtpServer->start<RtpSession>(port);
|
tcpRtpServer->start<RtpSession>(port);
|
||||||
|
|
||||||
|
//创建rtp udp服务器
|
||||||
auto ret = tcpRtpServer->getPort();
|
auto ret = tcpRtpServer->getPort();
|
||||||
udpRtpServer = std::make_shared<UdpRecver>();
|
udpRtpServer = std::make_shared<UdpRecver>();
|
||||||
//创建rtp udp服务器
|
|
||||||
udpRtpServer->initSock(port);
|
udpRtpServer->initSock(port);
|
||||||
return ret;
|
return ret;
|
||||||
} catch (std::exception &ex) {
|
} catch (std::exception &ex) {
|
||||||
|
Loading…
Reference in New Issue
Block a user