mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2024-11-26 04:31:37 +08:00
合并pr(rtp最大大小可配置):#1028
This commit is contained in:
parent
7ed7e5386c
commit
094f7553c9
@ -201,7 +201,7 @@ sslport=19350
|
|||||||
audioMtuSize=600
|
audioMtuSize=600
|
||||||
#视频mtu大小,该参数限制rtp最大字节数,推荐不要超过1400
|
#视频mtu大小,该参数限制rtp最大字节数,推荐不要超过1400
|
||||||
videoMtuSize=1400
|
videoMtuSize=1400
|
||||||
#rtp包最大长度限制,可以降低内存分配,单位k
|
#rtp包最大长度限制,单位KB,主要用于识别TCP上下文破坏时,获取到错误的rtp
|
||||||
rtpMaxSize=10
|
rtpMaxSize=10
|
||||||
|
|
||||||
[rtp_proxy]
|
[rtp_proxy]
|
||||||
|
@ -192,7 +192,7 @@ namespace Rtp {
|
|||||||
//RTP打包最大MTU,公网情况下更小
|
//RTP打包最大MTU,公网情况下更小
|
||||||
const string kVideoMtuSize = RTP_FIELD"videoMtuSize";
|
const string kVideoMtuSize = RTP_FIELD"videoMtuSize";
|
||||||
const string kAudioMtuSize = RTP_FIELD"audioMtuSize";
|
const string kAudioMtuSize = RTP_FIELD"audioMtuSize";
|
||||||
//rtp包最大长度限制,单位是k
|
//rtp包最大长度限制,单位是KB
|
||||||
const string kRtpMaxSize = RTP_FIELD"rtpMaxSize";
|
const string kRtpMaxSize = RTP_FIELD"rtpMaxSize";
|
||||||
|
|
||||||
onceToken token([](){
|
onceToken token([](){
|
||||||
|
@ -228,7 +228,7 @@ namespace Rtp {
|
|||||||
extern const string kVideoMtuSize;
|
extern const string kVideoMtuSize;
|
||||||
//RTP打包最大MTU,公网情况下更小
|
//RTP打包最大MTU,公网情况下更小
|
||||||
extern const string kAudioMtuSize;
|
extern const string kAudioMtuSize;
|
||||||
//rtp包最大长度限制, 单位k
|
//rtp包最大长度限制, 单位KB
|
||||||
extern const string kRtpMaxSize;
|
extern const string kRtpMaxSize;
|
||||||
} //namespace Rtsp
|
} //namespace Rtsp
|
||||||
|
|
||||||
|
@ -36,7 +36,7 @@ static bool loadFile(const char *path){
|
|||||||
|
|
||||||
uint32_t timeStamp_last = 0;
|
uint32_t timeStamp_last = 0;
|
||||||
uint16_t len;
|
uint16_t len;
|
||||||
char rtp[50 * 1024];
|
char rtp[0xFFFF];
|
||||||
struct sockaddr addr = {0};
|
struct sockaddr addr = {0};
|
||||||
auto sock = Socket::createSocket();
|
auto sock = Socket::createSocket();
|
||||||
size_t total_size = 0;
|
size_t total_size = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user