ソースを参照

feat(p2p): enable H.264 for P2P by default

On mobile we got the extra step of overriding the option and always set it to
true.
master
Saúl Ibarra Corretgé 8年前
コミット
8a3cec4a9d
2個のファイルの変更10行の追加11行の削除
  1. 1
    1
      config.js
  2. 9
    10
      react/features/base/conference/actions.js

+ 1
- 1
config.js ファイルの表示

@@ -102,7 +102,7 @@ var config = { // eslint-disable-line no-unused-vars
102 102
         ],
103 103
         // If set to true, it will prefer to use H.264 for P2P calls (if H.264
104 104
         // is supported).
105
-        preferH264: false
105
+        preferH264: true
106 106
         // How long we're going to wait, before going back to P2P after
107 107
         // the 3rd participant has left the conference (to filter out page reload)
108 108
         //backToP2PDelay: 5

+ 9
- 10
react/features/base/conference/actions.js ファイルの表示

@@ -1,3 +1,4 @@
1
+import _ from 'lodash';
1 2
 import { JitsiConferenceEvents } from '../lib-jitsi-meet';
2 3
 import { setVideoMuted } from '../media';
3 4
 import {
@@ -255,22 +256,20 @@ export function createConference() {
255 256
         dispatch(_conferenceWillJoin(room));
256 257
 
257 258
         const config = state['features/base/config'];
259
+        const configOverride = {
260
+            p2p: {
261
+                preferH264: true
262
+            }
263
+        };
258 264
         const conference
259 265
             = connection.initJitsiConference(
260 266
 
261 267
                 // XXX Lib-jitsi-meet does not accept uppercase letters.
262 268
                 room.toLowerCase(),
263
-                {
264
-                    ...config,
265
-
266
-                    openSctp: true
267 269
 
268
-                    // FIXME I tested H.264 from iPhone 6S during a morning
269
-                    // standup but, unfortunately, the other participants who
270
-                    // happened to be running the Web app saw only black.
271
-                    //
272
-                    // preferH264: true
273
-                });
270
+                // We use lodash's merge here because it will recursively merge
271
+                // objects allowing partial overrides.
272
+                _.merge({}, config, configOverride));
274 273
 
275 274
         _addConferenceListeners(conference, dispatch);
276 275
 

読み込み中…
キャンセル
保存