ossrs / srs

SRS is a simple, high-efficiency, real-time video server supporting RTMP, WebRTC, HLS, HTTP-FLV, SRT, MPEG-DASH, and GB28181.
https://ossrs.io
MIT License
24.74k stars 5.28k forks source link

How to replace the audio track within a live stream with random noise audio. #3965

Closed djkcyl closed 4 months ago

djkcyl commented 4 months ago

For instance, the usage of the following commands:

ffmpeg -i input_video_file_or_stream -f lavfi -i anoisesrc -c:v copy -c:a aac -map 0:v:0 -map 1:a:0 -shortest output_file_or_stream

TRANS_BY_GPT4

winlinvip commented 4 months ago

SRS is a media server that doesn't transcode or drop audio streams. However, you can use FFmpeg for this purpose. When you publish a stream to SRS, it can notify your system via an HTTP callback. Then, you can start FFmpeg to replace the audio stream with a silent one in your service.