Hi,
I have seen people on Hydrogen Audio talking about using the command line flac tool set as found here..
https://ftp.osuosl.org/pub/xiph/releases/flac/
I have downloaded the 64bit tools for Windows (machine is 64bit W10) and unpacked them.
I have run the flac.exe and metflac.exe files. Windows moans about security but lets me run them.
Now I hit my problem - nothing happens. No icon, no window, nothing.
Ok, it's command line so I go to command prompt and try flac commands as documented. Every command fails "flac is not recognized as an internal or external ..." you get the idea.
I searched for install instructions but can find none.
Obviously there is something crucial I don't know.
After trying to sort this for some hours and thinking I must be really thick, I would be very grateful for a clue.
Thanks.
Bob.
Try using a front end instead of messing around with a command line.
https://wiki.hydrogenaud.io/index.php?title=Free_Lossless_Audio_Codec#Frontends_.28Windows.29
Try using a front end instead of messing around with a command line.
https://wiki.hydrogenaud.io/index.php?title=Free_Lossless_Audio_Codec#Frontends_.28Windows.29
Nah. More people should learn how to use CLI tools, IMHO.
To OP, you probably need to do one of the following:
1. `cd` to the right directory/folder.
2. or type the path of the command.
3. or make the command available from anywhere.
Some quick searches returned this (https://www.howtogeek.com/659411/how-to-change-directories-in-command-prompt-on-windows-10/) for 1, this (https://stackoverflow.com/questions/3903288/run-an-exe-from-a-different-directory) for 2, and this (https://stackoverflow.com/questions/4822400/register-an-exe-so-you-can-run-it-from-any-command-line-in-windows/41895179#41895179) for 3.
1. I'd make my own folder, like b:\bin and put flac.exe and others into there.
2. In win 10 there is a gui named 'environment variables', where you would edit the 'Path' variable and add your folder to it.
3. now typing 'flac' should be accessible from any path (not sure if reboot is needed or not).
According to chatgpt, path is:
"path variable" typically refers to an environment variable called "PATH." The PATH variable is used by the operating system to locate executable files and programs.
When you type a command in a command-line interface (CLI) or terminal, the operating system needs to know where to find the corresponding executable file for that command. The PATH variable provides a list of directories that the operating system searches in order when looking for executable files.
p.s. typing
echo %PATH%
should return ; separated path values.
To OP, you probably need to do one of the following:
1. `cd` to the right directory/folder.
2. or type the path of the command.
3. or make the command available from anywhere.
Yes! success. Turned out I needed the current directory to be the one containing the flac.exe file. then commands started to get recognised. Thanks for that.
The command I was trying to use though still didn't work. That was:
flac -o newfile.flac [other options] file1.flac file2.flac
Trying to combine two flac files into one without a full re-encode.
It doesn't work and complains that you cannot set the output name with two input files.
But I've moved forward thanks.
This is my first reply so I hope I got it right.
Bob.
2. In win 10 there is a gui named 'environment variables', where you would edit the 'Path' variable and add your folder to it.
3. now typing 'flac' should be accessible from any path (not sure if reboot is needed or not).
According to chatgpt, path is:
"path variable" typically refers to an environment variable called "PATH." The PATH variable is used by the operating system to locate executable files and programs.
When you type a command in a command-line interface (CLI) or terminal, the operating system needs to know where to find the corresponding executable file for that command. The PATH variable provides a list of directories that the operating system searches in order when looking for executable files.
p.s. typing
echo %PATH%
should return ; separated path values.
Brilliant, so much useful info there, I'm looking into that today.
Most helpful.
Thank you.
Bob.
Trying to combine two flac files into one without a full re-encode.
I don't know any utility that can do that in a .flac file (it should be possible in containers).
And it is more complicated than you think. Most FLAC implementations encode only in fixed block/frame sizes. Say, 4096 (ffmpeg often uses 4608). Then the last frame has a different size, of course except when the signal happens to be a multiple of block size.
So for that concatenation to work, one would have to switch blocking strategy to variable (that would mean to rewrite all frame headers and footers, but not necessarily re-encode) - and then come those cases where it wouldn't be compliant to specification: that's when the last frame of the first file is less than 16 samples. The spec forbids shorter frames except at the end.
So such a utility would have to be able to re-encode two frames. Looks like a task for some very bored coder. (If you encode CD rips, you could "solve" that part by first encoding to block size 588. But ... nah.)
For the rest of us, use e.g. foobar2000 to re-encode as one file.
I don't know any utility that can do that in a .flac file.
For the rest of us, use e.g. foobar2000 to re-encode as one file.
Oh dear, I see what you mean. Thanks for your help.
Bob.