1
0
mirror of https://gitlab.crans.org/nounous/ghostream.git synced 2024-12-22 09:12:19 +00:00

Encode audio with opus codec

This commit is contained in:
Yohann D'ANELLO 2020-11-09 15:48:30 +01:00
parent c9a2d5b359
commit 11d89c6950

View File

@ -74,8 +74,8 @@ func forward(streamName string, q *messaging.Quality, fwdCfg []string) {
formattedURL = strings.ReplaceAll(formattedURL, "%S", fmt.Sprintf("%02d", now.Second())) formattedURL = strings.ReplaceAll(formattedURL, "%S", fmt.Sprintf("%02d", now.Second()))
formattedURL = strings.ReplaceAll(formattedURL, "%name", streamName) formattedURL = strings.ReplaceAll(formattedURL, "%name", streamName)
params = append(params, "-f", "flv", "-preset", "ultrafast", "-tune", "zerolatency", params = append(params, "-f", "flv",
"-c", "copy", formattedURL) "-c:v", "copy", "-c:a", "libopus", formattedURL)
} }
ffmpeg := exec.Command("ffmpeg", params...) ffmpeg := exec.Command("ffmpeg", params...)