Taking advantage of playout-delay extension

631 views
Skip to first unread message

Spencer Dixon

unread,
Jan 13, 2020, 3:16:49 PM1/13/20
to discuss-webrtc
Hello All,

I'm interested in taking advantage of the playout-delay extension (https://webrtc.org/experiments/rtp-hdrext/playout-delay/) but unable to understand the correct way to enable this after reading the documentation. For context, our application is native and using WebRTC C++ API's. 

What we've tried so far is passing values in by munging the SDP but it's very likely we're munging it incorrectly. After reading this section on SDP's https://tools.ietf.org/html/rfc8285#section-5 we changed:



Note the 0 0 for min playout and max playout. 

Are there higher-level API's we should be using instead of munging? Are we just munging incorrectly? Any help or links to documentation that would be useful would be much appreciated.

Cheers,
Spencer


Florian Grill

unread,
Jan 11, 2023, 5:50:57 PM1/11/23
to discuss-webrtc
Hi, did you ever found a solution to this. Currently have the same problem

[MSFT] Diego Perez Botero

unread,
Jan 18, 2023, 6:26:56 AM1/18/23
to discuss-webrtc
Playout delay is a per-video-frame setting. You'll need to set the playout_delay_ property on the webrtc::EncodedImage emitted by the webrtc::VideoEncoder.

[MSFT] Diego Perez Botero

unread,
Jan 18, 2023, 6:30:51 AM1/18/23
to discuss-webrtc
To validate that things are working as expected, grab a packet capture and look at the RTP Header Extension values being configured on the SRTP packets.  When the server is configured with a max playout delay value of 13370 ms (1337 at 10 ms granularity = 0x539), see attached packet.
example_packet.png

Florian Grill

unread,
Jan 18, 2023, 7:02:05 AM1/18/23
to discuss-webrtc
Okay thanks, will check it. But like the author of this post wrote what's the correct way of declaring this extension in the header?

Is this min max integer required in the sdp, e.g.
Or just without

[MSFT] Diego Perez Botero

unread,
Jan 18, 2023, 7:14:36 AM1/18/23
to discuss-webrtc
The SDP would only contain the intent to use that header extension, without the min/max values (since those are in the RTP header for each RTP packet).

Florian Grill

unread,
Jan 18, 2023, 7:18:02 AM1/18/23
to discuss-webrtc
Yeah true, as i expected. I checked the header values in the rtp and it seems to work. 
Thanks for pointing me in the right direction!
Reply all
Reply to author
Forward
0 new messages