Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
6d6bd1ef
提交
6d6bd1ef
authored
6月 08, 2016
作者:
Anthony Minessale
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
FS-9242 convert to adapter.js
上级
0e6e53f1
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
17 个修改的文件
包含
4132 行增加
和
288 行删除
+4132
-288
Makefile
html5/verto/js/Makefile
+1
-1
jquery.FSRTC.js
html5/verto/js/src/jquery.FSRTC.js
+124
-239
adapter-latest.js
html5/verto/js/src/vendor/adapter-latest.js
+3842
-0
index.html
html5/verto/verto_communicator/src/index.html
+1
-0
preview.html
html5/verto/verto_communicator/src/partials/preview.html
+1
-1
splash_screen.js
...communicator/src/storageService/services/splash_screen.js
+1
-5
storage.js
...verto_communicator/src/storageService/services/storage.js
+1
-0
DialPadController.js
...tor/src/vertoControllers/controllers/DialPadController.js
+2
-2
PreviewController.js
...tor/src/vertoControllers/controllers/PreviewController.js
+19
-12
SettingsController.js
...or/src/vertoControllers/controllers/SettingsController.js
+9
-0
SplashScreenController.js
...rc/vertoControllers/controllers/SplashScreenController.js
+1
-1
videoTag.js
...o_communicator/src/vertoDirectives/directives/videoTag.js
+21
-3
vertoService.js
...to_communicator/src/vertoService/services/vertoService.js
+42
-3
verto-min.js
html5/verto/video_demo/js/verto-min.js
+0
-0
verto.js
html5/verto/video_demo/verto.js
+50
-10
switch_core_media.c
src/switch_core_media.c
+4
-1
switch_rtp.c
src/switch_rtp.c
+13
-10
没有找到文件。
html5/verto/js/Makefile
浏览文件 @
6d6bd1ef
JSFILES
=
src/jquery.FSRTC.js src/jquery.jsonrpcclient.js src/jquery.verto.js
JSFILES
=
src/jquery.FSRTC.js src/jquery.jsonrpcclient.js src/jquery.verto.js
src/vendor/adapter-latest.js
all
:
jsmin verto-min.js
...
...
html5/verto/js/src/jquery.FSRTC.js
浏览文件 @
6d6bd1ef
差异被折叠。
点击展开。
html5/verto/js/src/vendor/adapter-latest.js
0 → 100644
浏览文件 @
6d6bd1ef
This source diff could not be displayed because it is too large. You can
view the blob
instead.
html5/verto/verto_communicator/src/index.html
浏览文件 @
6d6bd1ef
...
...
@@ -108,6 +108,7 @@
<script
type=
"text/javascript"
src=
"../js/src/jquery.jsonrpcclient.js"
></script>
<script
type=
"text/javascript"
src=
"../js/src/jquery.FSRTC.js"
></script>
<script
type=
"text/javascript"
src=
"../js/src/jquery.verto.js"
></script>
<script
type=
"text/javascript"
src=
"../js/src/vendor/adapter-latest.js"
></script>
<script
type=
"text/javascript"
src=
"js/3rd-party/getScreenId.js"
></script>
<script
type=
"text/javascript"
src=
"js/3rd-party/md5.min.js"
></script>
...
...
html5/verto/verto_communicator/src/partials/preview.html
浏览文件 @
6d6bd1ef
...
...
@@ -7,7 +7,7 @@
<div
class=
"panel-body"
>
<div
class=
"preview-wrapper"
>
<video
id=
"videopreview"
muted
autoplay
style=
"width: 100%;"
></video>
<div
id=
"mic-meter"
>
<div
id=
"mic-meter"
ng-if=
"audioContext"
>
<div
class=
"volumes"
>
<div
class=
"volume-segment"
></div>
<div
class=
"volume-segment"
></div>
...
...
html5/verto/verto_communicator/src/storageService/services/splash_screen.js
浏览文件 @
6d6bd1ef
...
...
@@ -14,11 +14,7 @@
'status'
:
'success'
,
'message'
:
$translate
.
instant
(
'BROWSER_COMPATIBILITY'
)
};
navigator
.
getUserMedia
=
navigator
.
getUserMedia
||
navigator
.
webkitGetUserMedia
||
navigator
.
mozGetUserMedia
;
if
(
!
navigator
.
getUserMedia
)
{
if
(
!
navigator
.
mediaDevices
.
getUserMedia
)
{
result
[
'status'
]
=
'error'
;
result
[
'message'
]
=
$translate
.
instant
(
'BROWSER_WITHOUT_WEBRTC'
);
reject
(
result
);
...
...
html5/verto/verto_communicator/src/storageService/services/storage.js
浏览文件 @
6d6bd1ef
...
...
@@ -23,6 +23,7 @@
mutedMic
:
false
,
preview
:
true
,
selectedVideo
:
null
,
selectedVideoName
:
null
,
selectedAudio
:
null
,
selectedShare
:
null
,
selectedSpeaker
:
null
,
...
...
html5/verto/verto_communicator/src/vertoControllers/controllers/DialPadController.js
浏览文件 @
6d6bd1ef
...
...
@@ -4,8 +4,8 @@
angular
.
module
(
'vertoControllers'
)
.
controller
(
'DialPadController'
,
[
'$rootScope'
,
'$scope'
,
'$http'
,
'$location'
,
'toastr'
,
'verto'
,
'storage'
,
'CallHistory'
,
'eventQueue'
,
function
(
$rootScope
,
$scope
,
$http
,
$location
,
toastr
,
verto
,
storage
,
CallHistory
,
eventQueue
)
{
'$http'
,
'$location'
,
'toastr'
,
'verto'
,
'storage'
,
'CallHistory'
,
'eventQueue'
,
'$timeout'
,
function
(
$rootScope
,
$scope
,
$http
,
$location
,
toastr
,
verto
,
storage
,
CallHistory
,
eventQueue
,
$timeout
)
{
console
.
debug
(
'Executing DialPadController.'
);
eventQueue
.
process
();
...
...
html5/verto/verto_communicator/src/vertoControllers/controllers/PreviewController.js
浏览文件 @
6d6bd1ef
...
...
@@ -11,7 +11,10 @@
$scope
.
storage
=
storage
;
console
.
debug
(
'Executing PreviewController.'
);
var
localVideo
=
document
.
getElementById
(
'videopreview'
);
var
volumes
=
document
.
querySelector
(
'#mic-meter .volumes'
).
children
;
var
volumes
=
document
.
querySelector
(
'#mic-meter .volumes'
);
if
(
volumes
)
{
volumes
=
volumes
.
children
;
}
$scope
.
localVideo
=
function
()
{
var
constraints
=
{
...
...
@@ -31,10 +34,13 @@
});
};
var
audioContext
=
null
;
if
(
typeof
AudioContext
!==
"undefined"
)
{
audioContext
=
new
AudioContext
();
}
var
audioContext
=
new
AudioContext
();
var
mediaStreamSource
=
null
;
var
meter
;
var
meter
=
null
;
var
streamObj
=
{};
function
stopMedia
(
stream
)
{
...
...
@@ -55,13 +61,12 @@
}
streamObj
=
stream
;
localVideo
.
src
=
window
.
URL
.
createObjectURL
(
stream
);
mediaStreamSource
=
audioContext
.
createMediaStreamSource
(
stream
);
meter
=
createAudioMeter
(
audioContext
);
mediaStreamSource
.
connect
(
meter
);
renderMic
();
FSRTCattachMediaStream
(
localVideo
,
stream
);
if
(
audioContext
)
{
mediaStreamSource
=
audioContext
.
createMediaStreamSource
(
stream
);
meter
=
createAudioMeter
(
audioContext
);
mediaStreamSource
.
connect
(
meter
);
};
}
function
renderMic
()
{
...
...
@@ -109,8 +114,10 @@
$scope
.
endPreview
=
function
()
{
localVideo
.
src
=
null
;
meter
.
shutdown
();
meter
.
onaudioprocess
=
null
;
if
(
audioContext
)
{
meter
.
shutdown
();
meter
.
onaudioprocess
=
null
;
};
stopMedia
(
streamObj
);
$location
.
path
(
'/dialpad'
);
storage
.
data
.
preview
=
false
;
...
...
html5/verto/verto_communicator/src/vertoControllers/controllers/SettingsController.js
浏览文件 @
6d6bd1ef
...
...
@@ -33,6 +33,15 @@
});
$scope
.
ok
=
function
()
{
console
.
log
(
'Camera Selected is'
,
$scope
.
mydata
.
selectedVideo
,
$scope
.
verto
.
data
.
videoDevices
);
angular
.
forEach
(
verto
.
data
.
videoDevices
,
function
(
video
)
{
console
.
log
(
'checking video '
,
video
);
if
(
video
.
id
==
$scope
.
mydata
.
selectedVideo
)
{
$scope
.
mydata
.
selectedVideoName
=
video
.
label
;
console
.
log
(
'Setting selectedVideoName to '
,
video
.
label
);
}
})
if
(
$scope
.
mydata
.
selectedSpeaker
!=
storage
.
data
.
selectedSpeaker
)
{
$rootScope
.
$emit
(
'changedSpeaker'
,
$scope
.
mydata
.
selectedSpeaker
);
}
...
...
html5/verto/verto_communicator/src/vertoControllers/controllers/SplashScreenController.js
浏览文件 @
6d6bd1ef
...
...
@@ -74,7 +74,7 @@
$rootScope
.
$on
(
'progress.complete'
,
function
(
ev
,
current_progress
)
{
$scope
.
message
=
'Complete'
;
if
(
verto
.
data
.
connected
)
{
if
(
storage
.
data
.
preview
)
{
if
(
0
&&
storage
.
data
.
preview
)
{
$location
.
path
(
'/preview'
);
}
else
{
...
...
html5/verto/verto_communicator/src/vertoDirectives/directives/videoTag.js
浏览文件 @
6d6bd1ef
...
...
@@ -13,17 +13,35 @@
.
module
(
'vertoDirectives'
)
.
directive
(
'videoTag'
,
function
()
{
function
link
(
scope
,
element
,
attrs
)
{
// Moving the video tag to the new place inside the incall page.
console
.
log
(
'Moving the video to element.'
);
jQuery
(
'video'
).
removeClass
(
'hide'
).
appendTo
(
element
);
jQuery
(
'video'
).
css
(
'display'
,
'block'
);
var
videoElem
=
jQuery
(
'#webcam'
);
var
newParent
=
document
.
getElementsByClassName
(
'video-tag-wrapper'
);
newParent
[
0
].
appendChild
(
document
.
getElementById
(
'webcam'
));
$
(
"#webcam"
).
resize
(
function
()
{
updateVideoSize
();
});
$
(
window
).
resize
(
function
()
{
updateVideoSize
();
});
updateVideoSize
();
videoElem
.
removeClass
(
'hide'
);
videoElem
.
css
(
'display'
,
'block'
);
scope
.
callActive
(
""
,
{
useVideo
:
true
});
element
.
on
(
'$destroy'
,
function
()
{
// Move the video back to the body.
console
.
log
(
'Moving the video back to body.'
);
jQuery
(
'video'
).
addClass
(
'hide'
).
appendTo
(
jQuery
(
'body'
));
videoElem
.
addClass
(
'hide'
).
appendTo
(
jQuery
(
'body'
));
$
(
window
).
unbind
(
'resize'
);
});
}
...
...
html5/verto/verto_communicator/src/vertoService/services/vertoService.js
浏览文件 @
6d6bd1ef
...
...
@@ -113,6 +113,35 @@ var framerate = [{
label
:
'30 FPS'
},
];
var
updateReq
;
var
updateVideoSize
=
function
(
ms
)
{
if
(
!
ms
)
ms
=
500
;
clearTimeout
(
updateReq
);
updateReq
=
setTimeout
(
function
()
{
var
videoElem
=
jQuery
(
'#webcam'
);
videoElem
.
width
(
""
);
videoElem
.
height
(
""
);
var
w
=
videoElem
.
width
();
var
h
=
videoElem
.
height
();
var
new_w
,
new_h
;
var
aspect
=
1920
/
1080
;
var
videoContainer
=
jQuery
(
'div.video-wrapper'
);
if
(
w
>
h
)
{
new_w
=
videoContainer
.
width
();
new_h
=
Math
.
round
(
videoContainer
.
width
()
/
aspect
);
}
else
{
new_h
=
videoContainer
.
height
();
new_w
=
Math
.
round
(
videoContainer
.
height
()
/
aspect
);
}
videoElem
.
width
(
new_w
);
videoElem
.
height
(
new_h
);
console
.
log
(
'Setting video size to '
+
new_w
+
'/'
+
new_h
);
},
ms
);
}
var
vertoService
=
angular
.
module
(
'vertoService'
,
[
'ngCookies'
]);
vertoService
.
service
(
'verto'
,
[
'$rootScope'
,
'$cookieStore'
,
'$location'
,
'storage'
,
...
...
@@ -317,7 +346,13 @@ vertoService.service('verto', ['$rootScope', '$cookieStore', '$location', 'stora
// Verify if selected devices are valid
var
videoFlag
=
data
.
videoDevices
.
some
(
function
(
device
)
{
return
device
.
id
==
storage
.
data
.
selectedVideo
;
console
.
log
(
'Evaluating device '
,
device
);
if
(
device
.
label
==
storage
.
data
.
selectedVideoName
)
{
console
.
log
(
'Matched video selection by name: '
,
device
.
label
);
storage
.
data
.
selectedVideo
=
device
.
id
;
return
true
;
}
return
device
.
id
==
storage
.
data
.
selectedVideo
&&
storage
.
data
.
selectedVideo
!==
"none"
;
});
var
shareFlag
=
data
.
shareDevices
.
some
(
function
(
device
)
{
...
...
@@ -332,7 +367,10 @@ vertoService.service('verto', ['$rootScope', '$cookieStore', '$location', 'stora
return
device
.
id
==
storage
.
data
.
selectedSpeaker
;
});
if
(
!
videoFlag
)
storage
.
data
.
selectedVideo
=
data
.
videoDevices
[
0
].
id
;
console
.
log
(
'Storage Video: '
,
storage
.
data
.
selectedVideo
);
console
.
log
(
'Video Flag: '
,
videoFlag
)
if
(
!
videoFlag
)
storage
.
data
.
selectedVideo
=
data
.
videoDevices
[
data
.
videoDevices
.
length
-
1
].
id
;
if
(
!
shareFlag
)
storage
.
data
.
selectedShare
=
data
.
shareDevices
[
0
].
id
;
if
(
!
audioFlag
)
storage
.
data
.
selectedAudio
=
data
.
audioDevices
[
0
].
id
;
if
(
!
speakerFlag
&&
data
.
speakerDevices
.
length
>
0
)
storage
.
data
.
selectedSpeaker
=
data
.
speakerDevices
[
0
].
id
;
...
...
@@ -484,7 +522,6 @@ vertoService.service('verto', ['$rootScope', '$cookieStore', '$location', 'stora
data
.
liveArray
.
onChange
=
function
(
obj
,
args
)
{
// console.log('liveArray.onChange', obj, args);
switch
(
args
.
action
)
{
case
'bootObj'
:
$rootScope
.
$emit
(
'members.boot'
,
args
.
data
);
...
...
@@ -560,6 +597,7 @@ vertoService.service('verto', ['$rootScope', '$cookieStore', '$location', 'stora
console
.
log
(
"conference-liveArray-join"
);
stopConference
();
startConference
(
v
,
dialog
,
params
.
pvtData
);
updateVideoSize
();
}
break
;
case
"conference-liveArray-part"
:
...
...
@@ -616,6 +654,7 @@ vertoService.service('verto', ['$rootScope', '$cookieStore', '$location', 'stora
console
.
debug
(
'Talking to:'
,
d
.
cidString
());
data
.
callState
=
'active'
;
callActive
(
d
.
lastState
.
name
,
d
.
params
);
updateVideoSize
();
break
;
case
"hangup"
:
console
.
debug
(
'Call ended with cause: '
+
d
.
cause
);
...
...
html5/verto/video_demo/js/verto-min.js
浏览文件 @
6d6bd1ef
This diff was suppressed by a .gitattributes entry.
html5/verto/video_demo/verto.js
浏览文件 @
6d6bd1ef
...
...
@@ -101,14 +101,14 @@ function full_screen(name) {
}
$
(
"#"
+
video_screen
).
resize
(
function
(
e
)
{
console
.
log
(
"video size changed to "
+
$
(
"#"
+
video_screen
).
width
()
+
"x"
+
$
(
"#"
+
video_screen
).
height
());
//
console.log("video size changed to " + $("#" + video_screen).width() + "x" + $("#" + video_screen).height());
if
(
$
(
"#"
+
video_screen
).
width
()
>
$
(
window
).
width
())
{
//
if ($("#" + video_screen).width() > $(window).width()) {
//resize(false);
$
(
"#"
+
video_screen
).
width
(
"100%"
);
$
(
"#"
+
video_screen
).
height
(
"100%"
);
}
//
$("#" + video_screen).width("100%");
//
$("#" + video_screen).height("100%");
//
}
real_size
();
});
...
...
@@ -128,13 +128,41 @@ function resize(up) {
}
$
(
window
).
resize
(
function
()
{
real_size
();
});
function
real_size
()
{
/* temasys hack */
setTimeout
(
function
()
{
$
(
"#"
+
video_screen
).
width
(
""
);
$
(
"#"
+
video_screen
).
height
(
""
);
$
(
"#"
+
video_screen
).
width
(
""
);
$
(
"#"
+
video_screen
).
height
(
""
);
var
w
=
$
(
"#"
+
video_screen
).
width
();
var
h
=
$
(
"#"
+
video_screen
).
height
();
var
new_w
;
var
new_h
;
var
aspect
=
1920
/
1080
;
/*temasys doesn't provide video width hack aspect to wide screen*/
if
(
w
>
h
)
{
new_w
=
window
.
innerWidth
;
new_h
=
Math
.
round
(
window
.
innerWidth
/
aspect
);
}
else
{
new_h
=
window
.
innerHeight
;
new_w
=
Math
.
round
(
window
.
innerHeight
/
aspect
);
}
$
(
"#"
+
video_screen
).
width
(
new_w
);
$
(
"#"
+
video_screen
).
height
(
new_h
);
},
500
);
console
.
log
(
"video size changed to fit screen"
);
console
.
log
(
"video size changed to natural default"
);
}
...
...
@@ -202,8 +230,19 @@ function check_vid() {
return
use_vid
;
}
var
DISABLE_SPEED_TEST
=
true
;
function
do_speed_test
(
fn
)
{
if
(
DISABLE_SPEED_TEST
)
{
if
(
fn
)
{
fn
();
}
return
;
}
goto_page
(
"bwtest"
);
vertoHandle
.
rpcClient
.
speedTest
(
1024
*
256
,
function
(
e
,
obj
)
{
...
...
@@ -486,6 +525,7 @@ var callbacks = {
check_vid_res
();
$
(
"#ansbtn"
).
click
(
function
()
{
console
.
error
(
"WTF"
,
cur_call
,
d
);
cur_call
.
answer
({
useStereo
:
$
(
"#use_stereo"
).
is
(
':checked'
),
callee_id_name
:
$
(
"#cidname"
).
val
(),
...
...
@@ -548,7 +588,7 @@ var callbacks = {
}
goto_page
(
"incall"
);
real_size
();
break
;
case
$
.
verto
.
enum
.
state
.
hangup
:
$
(
"#main_info"
).
html
(
"Call ended with cause: "
+
d
.
cause
);
...
...
src/switch_core_media.c
浏览文件 @
6d6bd1ef
...
...
@@ -8074,7 +8074,7 @@ SWITCH_DECLARE(void) switch_core_media_gen_local_sdp(switch_core_session_t *sess
if
(
switch_channel_test_flag
(
smh
->
session
->
channel
,
CF_ICE
))
{
gen_ice
(
session
,
SWITCH_MEDIA_TYPE_AUDIO
,
ip
,
port
);
switch_snprintf
(
buf
+
strlen
(
buf
),
SDPBUFLEN
-
strlen
(
buf
),
"a=msid-semantic: WMS %s
\r\n
a=end-of-candidates
\r\n
"
,
smh
->
msid
);
switch_snprintf
(
buf
+
strlen
(
buf
),
SDPBUFLEN
-
strlen
(
buf
),
"a=msid-semantic: WMS %s
\r\n
"
,
smh
->
msid
);
}
if
(
a_engine
->
codec_negotiated
)
{
...
...
@@ -8267,6 +8267,7 @@ SWITCH_DECLARE(void) switch_core_media_gen_local_sdp(switch_core_session_t *sess
}
}
switch_snprintf
(
buf
+
strlen
(
buf
),
SDPBUFLEN
-
strlen
(
buf
),
"a=end-of-candidates
\r\n
"
);
switch_snprintf
(
buf
+
strlen
(
buf
),
SDPBUFLEN
-
strlen
(
buf
),
"a=ssrc:%u cname:%s
\r\n
"
,
a_engine
->
ssrc
,
smh
->
cname
);
switch_snprintf
(
buf
+
strlen
(
buf
),
SDPBUFLEN
-
strlen
(
buf
),
"a=ssrc:%u msid:%s a0
\r\n
"
,
a_engine
->
ssrc
,
smh
->
msid
);
...
...
@@ -8804,6 +8805,8 @@ SWITCH_DECLARE(void) switch_core_media_gen_local_sdp(switch_core_session_t *sess
#ifdef GOOGLE_ICE
switch_snprintf
(
buf
+
strlen
(
buf
),
SDPBUFLEN
-
strlen
(
buf
),
"a=ice-options:google-ice
\r\n
"
);
#endif
switch_snprintf
(
buf
+
strlen
(
buf
),
SDPBUFLEN
-
strlen
(
buf
),
"a=end-of-candidates
\r\n
"
);
}
...
...
src/switch_rtp.c
浏览文件 @
6d6bd1ef
...
...
@@ -3192,7 +3192,7 @@ static int do_dtls(switch_rtp_t *rtp_session, switch_dtls_t *dtls)
ret
=
SSL_get_error
(
dtls
->
ssl
,
ret
);
switch_log_printf
(
SWITCH_CHANNEL_SESSION_LOG
(
rtp_session
->
session
),
SWITCH_LOG_ERROR
,
"%s DTLS packet read err %d
\n
"
,
rtp_type
(
rtp_session
),
ret
);
}
if
(
dtls_states
[
dtls
->
state
])
{
r
=
dtls_states
[
dtls
->
state
](
rtp_session
,
dtls
);
}
...
...
@@ -3396,8 +3396,11 @@ SWITCH_DECLARE(switch_status_t) switch_rtp_add_dtls(switch_rtp_t *rtp_session, d
//SSL_CTX_set_verify(dtls->ssl_ctx, SSL_VERIFY_PEER | SSL_VERIFY_FAIL_IF_NO_PEER_CERT, NULL);
SSL_CTX_set_verify
(
dtls
->
ssl_ctx
,
SSL_VERIFY_NONE
,
NULL
);
SSL_CTX_set_cipher_list
(
dtls
->
ssl_ctx
,
"ALL"
);
SSL_CTX_set_cipher_list
(
dtls
->
ssl_ctx
,
"ECDH:!RC4:!SSLv3:RSA_WITH_AES_128_CBC_SHA"
);
//SSL_CTX_set_cipher_list(dtls->ssl_ctx, "ECDHE-RSA-AES256-GCM-SHA384");
//SSL_CTX_set_cipher_list(dtls->ssl_ctx, "ALL:!ADH:!LOW:!EXP:!MD5:@STRENGTH");
//SSL_CTX_set_cipher_list(dtls->ssl_ctx, "SUITEB128");
SSL_CTX_set_read_ahead
(
dtls
->
ssl_ctx
,
1
);
#ifdef HAVE_OPENSSL_DTLS_SRTP
//SSL_CTX_set_tlsext_use_srtp(dtls->ssl_ctx, "SRTP_AES128_CM_SHA1_80:SRTP_AES128_CM_SHA1_32");
SSL_CTX_set_tlsext_use_srtp
(
dtls
->
ssl_ctx
,
"SRTP_AES128_CM_SHA1_80"
);
...
...
@@ -3456,11 +3459,11 @@ SWITCH_DECLARE(switch_status_t) switch_rtp_add_dtls(switch_rtp_t *rtp_session, d
SSL_set_verify
(
dtls
->
ssl
,
SSL_VERIFY_NONE
,
NULL
);
SSL_set_app_data
(
dtls
->
ssl
,
dtls
);
BIO_ctrl
(
dtls
->
read_bio
,
BIO_CTRL_DGRAM_SET_MTU
,
1400
,
NULL
);
BIO_ctrl
(
dtls
->
write_bio
,
BIO_CTRL_DGRAM_SET_MTU
,
1400
,
NULL
);
SSL_set_mtu
(
dtls
->
ssl
,
1400
);
BIO_ctrl
(
dtls
->
write_bio
,
BIO_C_SET_BUFF_SIZE
,
1400
,
NULL
);
BIO_ctrl
(
dtls
->
read_bio
,
BIO_C_SET_BUFF_SIZE
,
1400
,
NULL
);
//
BIO_ctrl(dtls->read_bio, BIO_CTRL_DGRAM_SET_MTU, 1400, NULL);
//
BIO_ctrl(dtls->write_bio, BIO_CTRL_DGRAM_SET_MTU, 1400, NULL);
//
SSL_set_mtu(dtls->ssl, 1400);
//
BIO_ctrl(dtls->write_bio, BIO_C_SET_BUFF_SIZE, 1400, NULL);
//
BIO_ctrl(dtls->read_bio, BIO_C_SET_BUFF_SIZE, 1400, NULL);
...
...
@@ -4145,7 +4148,7 @@ SWITCH_DECLARE(switch_status_t) switch_rtp_set_video_buffer_size(switch_rtp_t *r
}
if
(
!
max_frames
||
frames
>=
max_frames
)
{
max_frames
=
frames
+
8
;
max_frames
=
frames
*
10
;
}
rtp_session
->
last_max_vb_frames
=
max_frames
;
...
...
@@ -4202,7 +4205,7 @@ SWITCH_DECLARE(switch_status_t) switch_rtp_activate_jitter_buffer(switch_rtp_t *
}
if
(
max_queue_frames
<
queue_frames
)
{
max_queue_frames
=
queue_frames
*
6
;
max_queue_frames
=
queue_frames
*
3
;
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论