mozilla / webrtc-sdp

Rust SDP parser for WebRTC
Mozilla Public License 2.0
155 stars 30 forks source link

Add Support for RTSP attributes (a=contorl, a=range) #173

Open mateuszkj opened 5 years ago

mateuszkj commented 5 years ago

https://tools.ietf.org/html/rfc7826#section-22.15

na-g commented 5 years ago

@mateuszkj thanks for the patch! Could you comment on your use case for this library to give us some context for the patch?

mateuszkj commented 5 years ago

@na-g I had to write RTSP proxy with audio permissions. User without audio permission would receive SDP without audio codec (so VLC will play only video without audio).

I parsing SDP and then formatting (with or without audio codec), but original webrtc-sdp would drop attributes a=control and a=range witch are required by RTSP.

In Summary, my patch prevents webrtc-sdp from dropping these attributes while paring/formatting and also I can access value of these attributes.

xuguangyuansh commented 2 years ago

Our library supports rtsp to fetch the stream, and then transfer it to webrtc for playback, right? Didn't see how to configure it? I use it for security/surveillance.