0
我在使用jssip/sipjs庫進行調用時出現退出。沒有音頻了。以下內容顯示在JavaScript控制檯中。JSSIP/SIP-JS調用退出
====
Fri Apr 04 2014 10:14:30 GMT+0530 (IST) | sip.sanitycheck | Via sent-by in the response does not match UA Via host value. Dropping the response sip-0.5.0.js:170
Fri Apr 04 2014 10:14:34 GMT+0530 (IST) | sip.sanitycheck | Via sent-by in the response does not match UA Via host value. Dropping the response sip-0.5.0.js:170
Fri Apr 04 2014 10:14:38 GMT+0530 (IST) | sip.sanitycheck | Via sent-by in the response does not match UA Via host value. Dropping the response sip-0.5.0.js:170
Fri Apr 04 2014 10:14:42 GMT+0530 (IST) | sip.sanitycheck | Via sent-by in the response does not match UA Via host value. Dropping the response sip-0.5.0.js:170
設置涉及星號服務器和webrtc服務。
下面給出的是我用來測試的示例html頁面。
<!DOCTYPE html>
<html>
<head>
<!-- <script type="text/javascript" src="SIPml-api.js"></script> -->
</head>
<body>
Hello woirld
<video id="remoteVideo"></video>
<video id="localVideo" muted="muted"></video>
<button type="button" id="endButton">End</button>
<button type="button" id="callButton">Call</button>
</body>
<script type="text/javascript" src="sip-0.5.0.js"></script>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
<script type="text/javascript">
(function() {
var session;
function onAccepted() {
alert("You made a call!");
}
var userAgent = new SIP.UA({
uri: 'sip:[email protected]',
// wsServers: ['ws://mywebrtc.com:10060'],
wsServers: ['wss://mywebrtc.com:10062'],
authorizationUser: '100',
password: '1234'
});
$(document).ready(function() {
var endButton = document.getElementById('endButton');
endButton.addEventListener("click", function() {
session.bye();
alert("Call Ended");
}, false);
});
//here you determine whether the call has video and audio
var options = {
mediaConstraints: {
audio: true,
video: true
}
};
//makes the call
session = userAgent.invite('111', options);
session.on('accepted', onAccepted);
})();
</script>
</html>
=====
有人可以幫我在這?從您的代碼