@@ -52,14 +52,14 @@ rtpSendStream.onpacketizedrtp = () => {
5252### Example 2: Send custom RTP header extension
5353
5454``` javascript
55- // TODO: Negotiate headerExtensionCalculator.uri in SDP
55+ // TODO: Negotiate headerExtensionCalculator.id in SDP
5656const [pc , rtpSender ] = await customPeerConnectionWithRtpSender ();
5757const headerExtensionGenerator = new CustomHeaderExtensionGenerator ();
5858const rtpSendStream = await rtpSender .replaceSendStreams ()[0 ];
5959rtpSendStream .onpacketizedrtp = () => {
6060 for (const rtpPacket of rtpSendStream .readPacketizedRtp ()) {
6161 rtpPacket .setHeaderExtension ({
62- uri : headerExtensionGenerator .uri ,
62+ id : headerExtensionGenerator .id ,
6363 value: headerExtensionGenerator .generate (rtpPacket),
6464 });
6565 rtpSendStream .sendRtp (rtpPacket)
@@ -70,14 +70,14 @@ rtpSendStream.onpacketizedrtp = () => {
7070### Example 3: Receive custom RTP header extension
7171
7272``` javascript
73- // TODO: Negotiate headerExtensionProcessor.uri in SDP
73+ // TODO: Negotiate headerExtensionProcessor.id in SDP
7474const [pc , rtpReceiver ] = await customPeerConnectionWithRtpReceiver ();
7575const headerExtensionProcessor = new CustomHeaderExtensionProcessor ();
7676const rtpReceiveStream = await videoRtpReceiver .replaceReceiveStreams ()[0 ];
7777rtpReceiveStream .onreceivedrtp = () => {
7878 for (const rtpPacket of rtpReceiveStream .readReceivedRtp ()) {
7979 for (const headerExtension of rtpPacket .headerExtensions ) {
80- if (headerExtension .uri == headerExtensionProcessor .uri ) {
80+ if (headerExtension .id == headerExtensionProcessor .id ) {
8181 headerExtensionProcessor .process (headerExtension .value );
8282 }
8383 }
@@ -216,7 +216,7 @@ rtpReceiveStream.onrtpreceived = () => {
216216### Example 10: Send custom FEC
217217
218218``` javascript
219- // TODO: Negotiate headerExtensionCalculator.uri in SDP
219+ // TODO: Negotiate headerExtensionCalculator.id in SDP
220220const [pc , rtpSender ] = await customPeerConnectionWithRtpSender ();
221221const fecGenerator = new CustomFecGenerator ();
222222const rtpSendStream = await rtpSender .replaceSendStreams ()[0 ];
@@ -233,7 +233,7 @@ rtpSendStream.onpacketizedrtp = () => {
233233### Example 11: Receive custom FEC
234234
235235``` javascript
236- // TODO: Negotiate headerExtensionProcessor.uri in SDP
236+ // TODO: Negotiate headerExtensionProcessor.id in SDP
237237const [pc , rtpReceiver ] = await customPeerConnectionWithRtpReceiver ();
238238const fecProcessor = new CustomFecProcessor ();
239239const rtpReceiveStream = await videoRtpReceiver .replaceReceiveStreams ()[0 ];
0 commit comments