Skip to content

Commit

Permalink
encode again 🧙🏼
Browse files Browse the repository at this point in the history
  • Loading branch information
ghophp committed Nov 20, 2023
1 parent bc1ab6b commit 8608522
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions internal/stream/ffmpeg/ffmpeg.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,18 @@ func (s *Stream) StartStream() error {
"-f", "concat",
"-safe", "0",
"-i", s.playlistPath,
"-vf", "scale=1280:720",
"-pix_fmt", "yuv420p",
"-bufsize", "2000k",
"-c:v", "copy", // Directly copy the video stream
"-c:a", "copy", // Directly copy the audio stream
"-b:v", "2000k",
"-b:a", "128k",
"-ar", "44100",
"-vcodec", "libx264",
"-c:a", "copy",
"-preset", "ultrafast",
"-tune", "zerolatency",
"-r", "24",
"-g", "48",
"-f", "flv",
"rtmp://live.twitch.tv/app/"+s.twitchStreamKey)

Expand Down

0 comments on commit 8608522

Please sign in to comment.