mediamtx
mediamtx copied to clipboard
Add support for ulaw in HLS
Describe the feature
Hi, It is possible to add in a new release that HLS supports ulaw audio codec, such as G711?
In any case, I would like to know the reason why the latest releases do not include this audio codec.
Hello, the reason is simply that HLS uses MP4 and MP4 doesn't support the G711 codec.
G711 can be easily converted to PCM, but hls.js and Firefox don't support PCM inside MP4 yet.
It can also be converted into FLAC, which is not supported by RTSP.
If you need an immediate solution, you can convert the audio track from G711 to AAC with FFmpeg by following instructions in the README.