From e509d079a216fe92bd51846d839b492fb7f72d10 Mon Sep 17 00:00:00 2001 From: Winlin Date: Sun, 9 Nov 2025 12:11:50 -0500 Subject: [PATCH] Add codecs supprted in README --- README.md | 3 ++- trunk/3rdparty/srs-docs/doc/webrtc.md | 21 +++++++++++++++++++++ 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 46198b355..422a72cb3 100755 --- a/README.md +++ b/README.md @@ -11,7 +11,8 @@ [![](https://codecov.io/gh/ossrs/srs/graph/badge.svg?token=Zx2LhdtA39)](https://codecov.io/gh/ossrs/srs) SRS/7.0 ([Kai](https://ossrs.io/lts/en-us/product#release-70)) is a simple, high-efficiency, and real-time video server, -supporting RTMP/WebRTC/HLS/HTTP-FLV/SRT/MPEG-DASH/GB28181, Linux/macOS, X86_64/ARMv7/AARCH64/M1/RISCV/LOONGARCH/MIPS, +supporting RTMP/WebRTC/HLS/HTTP-FLV/SRT/MPEG-DASH/GB28181, Linux/macOS, X86_64/ARMv7/AARCH64/M1/RISCV/LOONGARCH/MIPS, +with codec support for H.264, H.265, AV1, VP9, AAC, Opus, and G.711, and essential [features](trunk/doc/Features.md#features). [![SRS Overview](https://ossrs.net/wiki/images/SRS-SingleNode-4.0-sd.png?v=114)](https://ossrs.net/wiki/images/SRS-SingleNode-4.0-hd.png) diff --git a/trunk/3rdparty/srs-docs/doc/webrtc.md b/trunk/3rdparty/srs-docs/doc/webrtc.md index c72f40bd1..8f17c33c8 100644 --- a/trunk/3rdparty/srs-docs/doc/webrtc.md +++ b/trunk/3rdparty/srs-docs/doc/webrtc.md @@ -470,6 +470,27 @@ To use VP9, add the `codec=vp9` query parameter to WHIP/WHEP URLs: Browser support: Chrome/Edge M29+, Firefox M28+, Opera M16+. Safari does not support VP9. Use H.264 if you need RTMP/HLS conversion, DVR recording, or Safari compatibility. +## G.711 Codec Support + +SRS supports G.711 (PCMU/PCMA) audio codec for WebRTC since v7.0.124 ([#4075](https://github.com/ossrs/srs/issues/4075)). +G.711 is a widely-used, royalty-free audio codec with excellent compatibility across VoIP systems, IP cameras, and legacy telephony equipment. +SRS implements G.711 as relay-only (SFU mode), accepting G.711 audio streams via WHIP and forwarding to WHEP players without transcoding. +G.711 streams cannot be converted to RTMP/HLS or recorded to DVR. + +To use G.711, add the `acodec=pcmu` or `acodec=pcma` query parameter to WHIP/WHEP URLs: + +* Publish with PCMU: `http://localhost:1985/rtc/v1/whip/?app=live&stream=livestream&acodec=pcmu` +* Play with PCMU: `http://localhost:1985/rtc/v1/whep/?app=live&stream=livestream&acodec=pcmu` +* Publish with PCMA: `http://localhost:1985/rtc/v1/whip/?app=live&stream=livestream&acodec=pcma` + +You can also combine video and audio codec parameters: + +* VP9 + PCMU: `http://localhost:1985/rtc/v1/whip/?app=live&stream=livestream&vcodec=vp9&acodec=pcmu` +* H.264 + PCMA: `http://localhost:1985/rtc/v1/whip/?app=live&stream=livestream&vcodec=h264&acodec=pcma` + +Browser support: All major browsers support G.711 (PCMU/PCMA). PCMU (μ-law) is prioritized over PCMA (A-law) when both are available. +Use Opus if you need RTMP/HLS conversion or DVR recording. + ## SFU: One to One Please use `conf/rtc.conf` as config.