Skip to content

Commit 3dd5755

Browse files
authored
add support for the telephone-event codec (#322)
1 parent e5baba1 commit 3dd5755

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

webrtc/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
* Add IP filter to WebRTC `SettingEngine` [#306](https://github.com/webrtc-rs/webrtc/pull/306)
88
* Stop sequence numbers from increasing in `TrackLocalStaticSample` while the bound `RTCRtpSender` have
99
directions that should not send. [#316](https://github.com/webrtc-rs/webrtc/pull/316)
10+
* Add support for a mime type "audio/telephone-event" (rfc4733) [#322](https://github.com/webrtc-rs/webrtc/pull/322)
1011

1112
#### Breaking changes
1213

webrtc/src/api/media_engine/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,9 @@ pub const MIME_TYPE_PCMU: &str = "audio/PCMU";
4848
/// MIME_TYPE_PCMA PCMA MIME type
4949
/// Note: Matching should be case insensitive.
5050
pub const MIME_TYPE_PCMA: &str = "audio/PCMA";
51+
/// MIME_TYPE_TELEPHONE_EVENT telephone-event MIME type
52+
/// Note: Matching should be case insensitive.
53+
pub const MIME_TYPE_TELEPHONE_EVENT: &str = "audio/telephone-event";
5154

5255
const VALID_EXT_IDS: Range<isize> = 1..15;
5356

webrtc/src/rtp_transceiver/rtp_codec.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ impl RTCRtpCodecCapability {
8383
} else if mime_type == MIME_TYPE_G722.to_lowercase()
8484
|| mime_type == MIME_TYPE_PCMU.to_lowercase()
8585
|| mime_type == MIME_TYPE_PCMA.to_lowercase()
86+
|| mime_type == MIME_TYPE_TELEPHONE_EVENT.to_lowercase()
8687
{
8788
Ok(Box::new(rtp::codecs::g7xx::G7xxPayloader::default()))
8889
} else {

0 commit comments

Comments
 (0)