This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function (exports) { | |
function Dictionary(size, default_val) { | |
this.myDict = {}; //<keys : <val,index>> | |
this.keys = []; | |
if (size) { | |
if (!default_val) { | |
default_val = 1; | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function PeerConnectionImpl(originId,targetId,initiator,reliability){ | |
this.reliable = reliability; | |
this.originId = originId; | |
this.targetId = targetId; | |
//you can use adapter.js instead | |
if (window.webkitRTCPeerConnection) { | |
this.RTCPeerConnection = webkitRTCPeerConnection; | |
this.RTCSessionDescription = RTCSessionDescription; | |
} else if (window.mozRTCPeerConnection) { | |
//delete turn servers due to incompatablitiy now |