Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Encoding not working because of volume argument on FFmpeg command #28

Open
matthew-balzan opened this issue Sep 2, 2023 · 1 comment

Comments

@matthew-balzan
Copy link

matthew-balzan commented Sep 2, 2023

I was always getting an empty session when encoding, without getting any errors.

I manually tried the command used to encode and got this:

Unrecognized option 'vol'.
Error splitting the argument list: Option not found

So i checked the arguments the package is sending (encode.go):

// Launch ffmpeg with a variety of different fruits and goodies mixed togheter
	args := []string{
		"-stats",
		"-i", inFile,
		"-reconnect", "1",
		"-reconnect_at_eof", "1",
		"-reconnect_streamed", "1",
		"-reconnect_delay_max", "2",
		"-map", "0:a",
		"-acodec", "libopus",
		"-f", "ogg",
		"-vbr", vbrStr,
		"-compression_level", strconv.Itoa(e.options.CompressionLevel),
		"-vol", strconv.Itoa(e.options.Volume),
		"-ar", strconv.Itoa(e.options.FrameRate),
		"-ac", strconv.Itoa(e.options.Channels),
		"-b:a", strconv.Itoa(e.options.Bitrate * 1000),
		"-application", string(e.options.Application),
		"-frame_duration", strconv.Itoa(e.options.FrameDuration),
		"-packet_loss", strconv.Itoa(e.options.PacketLoss),
		"-threads", strconv.Itoa(e.options.Threads),
		"-ss", strconv.Itoa(e.options.StartTime),
	}

I dont know if this was working for an older version of FFmpeg, or it's just a Windows problem, but vol does not exists as an argument.

Removing it correctly encodes the file.

@JadeMin
Copy link

JadeMin commented Oct 18, 2023

which ffmpeg versions are compatible?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants