Browse Source

Updates app.bundle.js with latest sdp-interop module.

j8
George Politis 10 years ago
parent
commit
e34a8e6b60
2 changed files with 18 additions and 8 deletions
  1. 1
    1
      index.html
  2. 17
    7
      libs/app.bundle.js

+ 1
- 1
index.html View File

19
     <script src="libs/popover.js?v=1"></script><!-- bootstrap tooltip lib -->
19
     <script src="libs/popover.js?v=1"></script><!-- bootstrap tooltip lib -->
20
     <script src="libs/toastr.js?v=1"></script><!-- notifications lib -->
20
     <script src="libs/toastr.js?v=1"></script><!-- notifications lib -->
21
     <script src="interface_config.js?v=5"></script>
21
     <script src="interface_config.js?v=5"></script>
22
-    <script src="libs/app.bundle.js?v=29"></script>
22
+    <script src="libs/app.bundle.js?v=30"></script>
23
     <script src="analytics.js?v=1"></script><!-- google analytics plugin -->
23
     <script src="analytics.js?v=1"></script><!-- google analytics plugin -->
24
     <link rel="stylesheet" href="css/font.css?v=6"/>
24
     <link rel="stylesheet" href="css/font.css?v=6"/>
25
     <link rel="stylesheet" href="css/toastr.css?v=1">
25
     <link rel="stylesheet" href="css/toastr.css?v=1">

+ 17
- 7
libs/app.bundle.js View File

25638
 exports.Interop = require('./interop');
25638
 exports.Interop = require('./interop');
25639
 
25639
 
25640
 },{"./interop":81}],81:[function(require,module,exports){
25640
 },{"./interop":81}],81:[function(require,module,exports){
25641
-var transform = require('./sdp-transform');
25641
+var transform = require('./transform');
25642
 var arrayEquals = require('./array-equals');
25642
 var arrayEquals = require('./array-equals');
25643
 
25643
 
25644
 function Interop() { }
25644
 function Interop() { }
26029
         });
26029
         });
26030
     } else {
26030
     } else {
26031
 
26031
 
26032
-        // Add all the m-lines that are in both the cached and the transformed
26033
-        // SDP in the order of the cached SDP. We take the intersection because
26034
-        // don't want to add m-lines from the cached SDP that have been removed
26035
-        // from the transformed SDP.
26032
+        // SDP offer/answer (and the JSEP spec) forbids removing an m-section
26033
+        // under any circumstances. If we are no longer interested in sending a
26034
+        // track, we just remove the msid and ssrc attributes and set it to
26035
+        // either a=recvonly (as the reofferer, we must use recvonly if the
26036
+        // other side was previously sending on the m-section, but we can also
26037
+        // leave the possibility open if it wasn't previously in use), or
26038
+        // a=inacive.
26039
+
26036
         if (typeof cached !== 'undefined' &&
26040
         if (typeof cached !== 'undefined' &&
26037
             typeof cached.media !== 'undefined' &&
26041
             typeof cached.media !== 'undefined' &&
26038
             Array.isArray(cached.media)) {
26042
             Array.isArray(cached.media)) {
26039
             cached.media.forEach(function(pm) {
26043
             cached.media.forEach(function(pm) {
26044
+                mids.push(pm.mid);
26040
                 if (typeof media[pm.mid] !== 'undefined') {
26045
                 if (typeof media[pm.mid] !== 'undefined') {
26041
-                    mids.push(pm.mid);
26042
                     session.media.push(media[pm.mid]);
26046
                     session.media.push(media[pm.mid]);
26047
+                } else {
26048
+                    delete pm.msid;
26049
+                    delete pm.sources;
26050
+                    // TODO(gp) delete ssrc-groups
26051
+                    pm.direction = 'recvonly';
26052
+                    session.media.push(pm);
26043
                 }
26053
                 }
26044
             });
26054
             });
26045
         }
26055
         }
26082
     //#endregion
26092
     //#endregion
26083
 };
26093
 };
26084
 
26094
 
26085
-},{"./array-equals":79,"./sdp-transform":82}],82:[function(require,module,exports){
26095
+},{"./array-equals":79,"./transform":82}],82:[function(require,module,exports){
26086
 var transform = require('sdp-transform');
26096
 var transform = require('sdp-transform');
26087
 
26097
 
26088
 exports.write = function(session, opts) {
26098
 exports.write = function(session, opts) {

Loading…
Cancel
Save