Commit 03f3983 1 parent 4439250 commit 03f3983 Copy full SHA for 03f3983
File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -12,12 +12,12 @@ import { WHIPClient } from "whip.js"
12
12
const stream = await navigator.mediaDevices.getUserMedia({audio:true, video:true});
13
13
14
14
//Create peerconnection
15
- const pc = new RTCPeerConnection();
15
+ const pc = new RTCPeerConnection({ bundlePolicy: "max-bundle" } );
16
16
17
17
//Send all tracks
18
18
for (const track of stream.getTracks()) {
19
19
//You could add simulcast too here
20
- pc.addTrack(track);
20
+ pc.addTrack(track, { 'direction': 'sendonly' } );
21
21
}
22
22
23
23
//Create whip client
@@ -40,7 +40,7 @@ WHEP client javascript module
40
40
import { WHEPClient } from "whep.js"
41
41
42
42
//Create peerconnection
43
- const pc = window.pc = new RTCPeerConnection();
43
+ const pc = window.pc = new RTCPeerConnection({ bundlePolicy: "max-bundle" } );
44
44
45
45
//Add recv only transceivers
46
46
pc.addTransceiver("audio");
You can’t perform that action at this time.
0 commit comments