FLAC 1.1.3 has been released. Almost 2 years in the making, FLAC 1.1.3 is a major release with improved compression, improved cover art and multichannel support, better recovery for corrupted files, many new features and options in the command-line tools, and several bug fixes. For developers, the decoder and encoder APIs have also been simplified and there is a new porting guide (http://flac.sourceforge.net/api/group__porting.html). See the changelog entry (http://flac.sourceforge.net/changelog.html#flac_1_1_3) for complete details.
Josh
note there is one known bug that will affect the compression ratio for some locales but there is a workaround; see known bugs (http://flac.sourceforge.net/documentation.html#bugs).
downloads at http://flac.sourceforge.net/download.html (http://flac.sourceforge.net/download.html) or http://sourceforge.net/project/showfiles.php?group_id=13478 (http://sourceforge.net/project/showfiles.php?group_id=13478)
MD5 sums:
1986cf97d7a04d8b425d9c61fe6b52b3 flac-1.1.3-devel-win.zip
de9771830c6b879632ce50ce0052b830 flac-1.1.3-linux-i386.tar.gz
ad00df28be05eaa773854cf5da31f208 flac-1.1.3-osx-ppc.tar.gz
9badf34f5f717426babd2d9da4715aa4 flac-1.1.3-win.zip
b084603948b60ee338e0c29978cc580c flac-1.1.3.tar.gz
SHA-1 sums:
b5229a913b2c860fcd879bdacb6a9b797bd44e0d flac-1.1.3-devel-win.zip
e8ad3debe240eb329d8a186e8066e08681679c62 flac-1.1.3-linux-i386.tar.gz
3c0e10dba0da045364b0cc23c3694a201a2d87c0 flac-1.1.3-osx-ppc.tar.gz
3f048d915c95e4c9478e9e7249bc508a66245247 flac-1.1.3-win.zip
e19c92bebe536b69dd14d54de76c1f626b83b295 flac-1.1.3.tar.gz
From the changelog: "Much better recovery for corrupted files"
Is this a decoder improvement, or a change to the file stream which requires the file to be encoded with 1.1.3? The speed & compression improvements are good, but not "reencode my flacs" worthy. Error correction would be though.
I think many people will never know about the workaround for the Locale bug because, seriously, who's going to read that part of the documentation?
And I don't think that only few people are affected, Germans for example, being the biggest user-base affected by this also have the "," as the decimal separator.
Hm, but I hope the difference isn't that big, but only a dozen bytes...
PS: where are the posts in which this was discovered/discussed?
I think every country in Europe except the UK use "," as decimal separator. At least we certainly do. And anyway if it's a "known bug" why can't be a 1.1.3.1 released ?
Oh wow, everyone except the English? That kind of makes it even worse. So then the FLAC user base is literally split in half into English speaking and non-English speaking (or locale using) users now... each producing a different encode with 1.1.3... weird.
Oh wow, everyone except the English?
Basically, yes...
I think every country in Europe except the UK use "," as decimal separator. At least we certainly do. And anyway if it's a "known bug" why can't be a 1.1.3.1 released ?
I hope Josh finds a way to fix this bug in the code itself without someone having to add extra command line options, as very few except the real "die hard" audiophiles use lots of command line options. Many people use the defaults.
Does this bug only affect flac.exe for Windows or is it also in the libFLAC 1.1.3 code too?
Uhm, to make things clear... is it correct that we are talking about 6 extra bytes only for the whole file? I've skimmed over the 1.1.3 beta thread and I stumbled across that number. IMHO, not enough to make a big deal out of it (<- , coming from the guy who started it).
Uhm, to make things clear... is it correct that we are talking about 6 extra bytes only for the whole file? I've skimmed over the 1.1.3 beta thread and I stumbled across that number. IMHO, not enough to make a big deal out of it (<- , coming from the guy who started it).
No we're talking a lot more than 6 bytes. Read the beta thread, it produces FLAC 1.1.2 like encoding rates, instead of FLAC 1.1.3 rates. Many people were quoting multi-megabyte difference in file size due to FLAC incorrectly using sub-optimal encoding rates due to their systems not using period dots but rather commans in their language by default.
Please re-release an upgrade to fix this Josh. FLAC 1.1.3a anyone? All this bug does is give this new FLAC release a "black eye" in my opinion and detracts from an otherwise great update. Too bad this wasn't caught in time to be in the release...
No, it's more than 6 bytes. I tried to encode a few files on my german system and the compression stays the same (or almost the same) as in 1.1.2. I would say that this [-A "tukey(0,5)"] parameter is the main difference between the 1.1.2 and 1.1.3 encoder.
Edit: goodnews was faster
I am surprised that this major update did not receive at least 1.2 status!
With regard to the point bug, I agree; there should be a maintenance release. It would be a shame for European users to miss out on one of the best new features of the encoder!
What would happen if you put both versions into the encoder? Would a comma-based machine simply ignore the point-based parameter and vice versa? Or could this confuse the encoder?
Sadly I'm not into programming, but maybe someone who is could try this since flac is open-source?
There is surely a better way to fix the problem?
I found something which I think is a potential problem with the recommended workaround. The documentation to the affected FLAC feature (apodization (http://flac.sourceforge.net/documentation.html#flac_options_apodization)) says the following:
The encoder chooses suitable defaults in the absence of any -A options; any -A option specified replaces the default(s).
So that workaround will always use "tukey(0,5)", even when the encoder would have chosen a different apodization function? That's bad.
I am surprised that this major update did not receive at least 1.2 status!
I agree. It is called a 'Major release' (http://flac.sourceforge.net/) but when you click on the explanation of 'Major release' you get a blurb on how last digit updates mean 'Micro updates'.
Oh well, it's not the end of world.
So that workaround will always use "tukey(0,5)", even when the encoder would have chosen a different apodization function? That's bad.
I don't think FLAC chooses the window depending on any criteria. It always uses tukey(0.5).
Edit: Hmm... I see you are quoting the documentation and it does give the impression that the window is chosen dynamically. I guess I must be wrong.
Thanks for the update, Josh. Keep up the great work.
From the changelog: "Much better recovery for corrupted files"
Is this a decoder improvement, or a change to the file stream which requires the file to be encoded with 1.1.3? The speed & compression improvements are good, but not "reencode my flacs" worthy. Error correction would be though.
the improvement is entirely in the decoder, not due to any format changes.
I am surprised that this major update did not receive at least 1.2 status!
yes, this is a common question so I made a FAQ for it: http://flac.sourceforge.net/faq.html#api__release_versioning (http://flac.sourceforge.net/faq.html#api__release_versioning)
as for the -A bug, I feel your pain! since this release had so much new stuff I plan on doing another one soon to correct major things that have cropped up.
I thought most people are using tools like EAC, AutoFLAC, frontend, etc where the command string is only specified once, and it is easier to do the workaround. there is another possible workaround that involves running the binary in a "C" locale. I have no idea how you do that on windows but with unix it would just be
LANG=C LC_ALL=C flac -5V ...
Josh
I am surprised that this major update did not receive at least 1.2 status!
yes, this is a common question so I made a FAQ for it: http://flac.sourceforge.net/faq.html#api__release_versioning (http://flac.sourceforge.net/faq.html#api__release_versioning)
Ah, it's clear now. Thanks!
By the way, that FAQ states 4KB as default padding, I thought it was increased to 8KB?
I thought most people are using tools like EAC, AutoFLAC, frontend, etc where the command string is only specified once, and it is easier to do the workaround. there is another possible workaround that involves running the binary in a "C" locale. I have no idea how you do that on windows but with unix it would just be
LANG=C LC_ALL=C flac -5V ...
Josh
Unfortunately it's not as easy as under Unix. One workaround for Windows might be to "customize" the locale and use "." instead of "," as the decimal seperator while encoding with flac or until an update is out. I don't know of any other application where it actually matters that much.
If anyone knows whether it's possible to change the locale per application, I'd be interested to know, since I know of at least one other problem that is related to the locale setting and which bothers me.
Great news, thanks for the update!
Is it possible to show warning if incorrect apodization function was used in command line (and was skipped by flac[.exe])? Because now I can just misspell function or parameter name (as with tukey(0.5)) and even don't know about it.
By the way, that FAQ states 4KB as default padding, I thought it was increased to 8KB?
oops, fixed.
P.S. one more note to developers and package maintainers... I went around to all the open-source flac-dependent projects I could find and made patches for the api changes. if you didn't get them and need one, let me know. also if you have a closed source project and the porting guide is not clear or you need more info, let me know too.
I thought most people are using tools like EAC, AutoFLAC, frontend, etc where the command string is only specified once, and it is easier to do the workaround.
Josh
That's me.
Josh, I want the absolute best compression (ripping from CD via EAC), and I do not care about encode time. So what combination of flags do I need to set? Currently I'm using
-8. It looks like now I need to specify
-m --best -e ?
I thought most people are using tools like EAC, AutoFLAC, frontend, etc where the command string is only specified once, and it is easier to do the workaround.
Josh
That's me.
Josh, I want the absolute best compression (ripping from CD via EAC), and I do not care about encode time. So what combination of flags do I need to set? Currently I'm using -8. It looks like now I need to specify -m --best -e ?
if you want the maximum compression available, then you should use a few -A functions. it increases the encode time with little to no improvement to the compression. also, you can use -A more than once.
Josh, I want the absolute best compression (ripping from CD via EAC), and I do not care about encode time. So what combination of flags do I need to set? Currently I'm using -8. It looks like now I need to specify -m --best -e ?
it's still -8 (same as --best) both of which turn on -m and -e. if you're affected by the locale bug you have to specify -A "tukey(0,5)" manually. then if you really don't care about the encoding time you can add more and different -A options but this is unlikely to ever get you more than .25% increased compression and they really slow things down.
I have some more ideas for compression improvements that I will be testing now that 1.1.3 is out.
Josh
Will there be a separate P4 specific build like the previous version? Or will we just have to wait and see if John33 compiles this?
Thanks for the great work Josh. Looks like it's back to FLAC for me.
1.1.2 is not affected by the locale bug, right?
1.1.2 is not affected by the locale bug, right?
Also FLAC 1.1.3 beta 2 was reportedly not affected by this bug... ?
Considering that a LOT of countries are affected by the -A bug (almost every country in fact !), and that this can cause IMHO potential problems with AccurateRip for instance (different file sizes, so no matches found) and lead to lots of wrong data being uploaded to AccurateRip's database, can we expect the "-A bug free version" to be available quite soon ?
Josh, what can be the estimated delay for the next bug-correcting version ? Are we talking about days ? weeks ? months ? years ?
Thanks in advance. I hope everybody will soon be able to fully enjoy all of 1.1.3's great improvements.
What does AccurateRip has to do with FLAC? Nothing.
I will also wait for the version which fixes the localization bug. I don't know which one (',' or '.') is set at my computer, so I'll be safe and use 1.1.2 untill a bugfix is released.
What does AccurateRip has to do with FLAC? Nothing.
Oops, sorry, you're totally right, I wrote that too fast. But my question remains the same. Thanks.
An estimate of a bigfix would be appreciated. Weeks? A month? Months? Year?
Doesn't have to be that precise, but for now I will just wait for the fix (since I don't expect to encode much until after my christmas gifts )
I don't think FLAC chooses the window depending on any criteria. It always uses tukey(0.5).
Edit: Hmm... I see you are quoting the documentation and it does give the impression that the window is chosen dynamically. I guess I must be wrong.
You're right, currently it is always "tukey(0.5)":
The encoder chooses suitable defaults in the absence of any -A options; any -A option specified replaces the default(s).
How does it choose? Is it always tukey(0.5)?
right now, yes but it may get smarter.
Thanks for the confirmation, and quotes, Egor.
I did wonder whether this referred to potential changes in the future, rather than current practise.
I uploaded a hack-fixed version for Windows here (http://www.saunalahti.fi/~cse/flac113.zip). It treats both comma and dot with apodization functions in the same way.
I uploaded a hack-fixed version for Windows here (http://www.saunalahti.fi/~cse/flac113.zip). It treats both comma and dot with apodization functions in the same way.
So it has the same behaviour as 1.1.2?
So it has the same behaviour as 1.1.2?
No. If tukey(0.5) and tukey(0,5) are working as they should then this release will do what 1.1.3 intended to do.
Unless of course Case means that now tukey(0.5) is fubar'd as well.
Edit: Also, may I say in my best Brian Blessed voice, "Gordon's alive!".
Is the new version of FLAC OK to use with FLACFrontend? I'd use the surely marvellous Foobar but it makes my tiny brain hurt.
Thanks for treating me gently!!
Is the new version of FLAC OK to use with FLACFrontend?
I'm using FLACFrontend with FLAC1.1.3 and didn't encounter any problems so far.
Is the new version of FLAC OK to use with FLACFrontend?
I'm using FLACFrontend with FLAC1.1.3 and didn't encounter any problems so far.
Thanks - I'm sure that if something goes wrong it will be MY fault!
I uploaded a hack-fixed version for Windows here (http://www.saunalahti.fi/~cse/flac113.zip). It treats both comma and dot with apodization functions in the same way.
Thanks for the fix Case.
When creating a flac file with both beta 2 and the final fixed version there is one byte difference in the file size.
I assume this is normal behavior.
Thanks for all your work Josh
To clear things up: The command line fix completely solves the issue, right? Flac does not set the switch dynamically like posted before?
I believe that is the idea, yes.
The easiest way to test (assuming that you use the comma as the decimal separator) is to run the following two command lines, and ensure that the results are identical :
FLAC.EXE -o one.flac source.wav
FLAC.EXE -A tukey(0,5) -o two.flac source.wav
Edit: In fact, on testing, this appears to work even if you use a full stop as the decimal separator. I assume that Case is simply replacing any occurrence of "," with "." or something:
C:\Documents and Settings\Neil\Desktop>FLAC.EXE -o one.flac source.wav && FLAC.E
XE -A tukey(0,5) -o two.flac source.wav && FLAC.EXE -A tukey(0.5) -o three.flac
source.wav
flac 1.1.3, Copyright (C) 2000,2001,2002,2003,2004,2005,2006 Josh Coalson
flac comes with ABSOLUTELY NO WARRANTY. This is free software, and you are
welcome to redistribute it under certain conditions. Type `flac' for details.
source.wav: wrote 24487047 bytes, ratio=0.723
flac 1.1.3, Copyright (C) 2000,2001,2002,2003,2004,2005,2006 Josh Coalson
flac comes with ABSOLUTELY NO WARRANTY. This is free software, and you are
welcome to redistribute it under certain conditions. Type `flac' for details.
source.wav: wrote 24487047 bytes, ratio=0.723
flac 1.1.3, Copyright (C) 2000,2001,2002,2003,2004,2005,2006 Josh Coalson
flac comes with ABSOLUTELY NO WARRANTY. This is free software, and you are
welcome to redistribute it under certain conditions. Type `flac' for details.
source.wav: wrote 24487047 bytes, ratio=0.723
Discussion regarding decimal separator moved here (http://www.hydrogenaudio.org/forums/index.php?showtopic=50722).
first, to save time I'll say the answers by synthetic soul and doubleXP are correct.
as for when the next release will be out, please understand first that the full release cycle for flac is actually quite a lot of work, which I am hesitant to do for a bug which has such a simple workaround (adding an option). the alternative is just specific fixed binaries, and I think case's handles that nicely for windows. the fix in CVS on the trunk will be checked in probably tonight.
I don't have a schedule for 1.1.4, but the next full release will not be 2 years away again. flac releases tend to ping-pong between major releases which take a lot of time, and shorter minor releases which are mostly fixes.
Josh
Can you not update the download on the page and add a note saying "Releases downloaded prior to xx/xx/xx . . .", explaining? It will not be much hassle for users who wish to update their encoder, and it will be available to those outside of this fine community.
I agree : strict procedures are OK, but a bit of pragmatism is better. If there is a patch and if this patch works like Josh just said, then the patch should be available for download directly at FLAC's official site until the next minor release is out.
How about a 1.1.3a?
I wanted to check out the 'better multichannel support' of this new flac release so I did the following:
I extracted some PCM .wav files from a DVD-A disc I own, they're 24 bit 44.1KHz. I used Wavewizard v0.54b to merge the 6 .wav files according to Microsoft's standard order (L, R, C, LFE, RL, RR) into one big 5.1 24bit PCM .wav.
I then fed this file to convert using Foobar 0.9.4.2 set to preserve the bit depth and using the standard commandline: -s -8 - -o %d (even put my windows locale to English (UK)). This conversion failed and gives me the following error: Error writing to file (Encoder has terminated prematurely with code 1; please re-check parameters).
I tried feeding the same merged .wav file to the official flac frontend but it failed too, giving me both a warning (legacy WAVE file has format type 1 but bits-per-sample=24) and an error (WAVE has >2 channels but is not WAVE_FORMAT_EXTENSIBLE; cannot assign channels.
I've been converting my DVD-A discs using this very same method combined with FLAC 1.1.2 without any problems before. Moreover, putting back the 'old' flac.exe (1.1.2) to the Foobar folder results in a perfect encode.
What's up with the 'better mutlichannel support'?
(Regardless of this, thank you very much for creating this nice lossless encoder!)
What's up with the 'better mutlichannel support'?
The new flac 1.1.3 requires multichannel wav files to be in WAVE_FORMAT_EXTENSIBLE, but currently [a href='index.php?showtopic=49191']fb2k generates it in WAVE_FORMAT_EX[/a] for 'compatibility' reason.
Besides convincing Peter to add _EXTENSIBLE support to Converter, you can try the following undocumented option:
Foobar2000 [a href='index.php?showtopic=49191']generates[/a] multichannel WAV files, which are not compatible with flac.exe 1.1.3 and Windows Media Encoder. I've sent you a sample to the address at sf.net.
ok, these look like the WAV files flac used to generate too, they are 6ch WAVEFORMATEX which are technically not allowed but common.
the way I am handling this in flac-1.1.3 is an undocumented option '--channel-map=none' to let flac assume the channels are in WAVEFORMATEXTENSIBLE's order. note that you still have to feed flac a multichannel file that uses one of the legal channel assignments (http://flac.cvs.sourceforge.net/*checkout*...ml#frame_header (http://flac.cvs.sourceforge.net/*checkout*/flac/flac/doc/html/format.html#frame_header)) if you want to make sure the decoded WAV later has the right channels in the right order with the right channel mask.
Besides convincing Peter to add _EXTENSIBLE support to Converter
erm, doesn't the converter feed flac.exe the raw PCM data or am i missing something here?
Thanks Egor, that '--channel-map=none' options seems to do the trick . However, what I don't understand is that if Foobar seems to be the problem than why does the official flac frontend has the same problem? And is there any way I can create a multichannel .wav file from six mono .wav files that conform to the specification FLAC 1.1.3 demands?
/edit
Nice, FLAC 1.1.3 gives a 2% compression advantage compared to 1.1.2: respectively 1.04GB and 1.06GB on a 52 minute classical album @ 24 bit 44.1KHz.
erm, doesn't the converter feed flac.exe the raw PCM data or am i missing something here?
Nope, fb2k just sends wav (not RAW) data to encoder's stdin.
However, what I don't understand is that if Foobar seems to be the problem than why does the official flac frontend has the same problem?
What frontend do you mean?
And is there any way I can create a multichannel .wav file from six mono .wav files that conform the specification FLAC 1.1.3 demands?
The only freeware application was WaveWizard.
However, what I don't understand is that if Foobar seems to be the problem than why does the official flac frontend has the same problem?
What frontend do you mean?
Well, the one that comes with the Windows Flac installer downloaded from http://flac.sourceforge.net/download.html (http://flac.sourceforge.net/download.html). Seems to be created by 'Speek': http://members.home.nl/w.speek/flac.htm (http://members.home.nl/w.speek/flac.htm).
note that if you use --channel-map=none, the incoming channels should be in the correct order (http://flac.sourceforge.net/format.html#frame_header), otherwise they might be mapped incorrectly on decoding.
Josh
What's the simplest way to re-encode FLAC files with 1.1.3? I'm a windows user, and FLAC Frontend will not take FLAC as input to be encoded to FLAC. I want to keep all tags, etc, just encode with newer FLAC. (also, i'm not a command line master, so..)
The simplest way is foobar.
The simplest way is foobar.
What kind of improvement is expected if all FLAC files encodedwith 1.1.2 at level 8 will be re-encoded with 1.1.3 at level 8? Some bytes, or will an album be some megabytes smaller?
depends on the material but probably 0.5-1.0%
This depends on the lenght of the album. I got an 1 MB difference on some while others gave me almost 20MB.
What's the simplest way to re-encode FLAC files with 1.1.3? I'm a windows user, and FLAC Frontend will not take FLAC as input to be encoded to FLAC. I want to keep all tags, etc, just encode with newer FLAC. (also, i'm not a command line master, so..)
Cut and paste the following script (author unknown to me) into a text editor and name it something like "convert.cmd". Put in in the root of your flac directory. Doubleclick. And do something great of your day while reencoding.
@echo off
set encoder="C:\Program\Sound\Coding\Flac\flac.exe"
for /r "." %%d in (.) do (cd %%d & for %%f in (*.flac) do %encoder% -8 -V -f -A "tukey(0,5)" "%%f")
Note: Of course you change the directory path of flac.exe to your specific.
Script takes care of the dot/comma bug.
EDIT: And it preserves the old tags.
What's the simplest way to re-encode FLAC files with 1.1.3?
The simplest way is foobar.
Cut and paste the following script (author unknown to me) into a text editor...
You could also use Speek's Multi-Frontend (http://members.home.nl/w.speek/multi.htm).
, which I am hesitant to do for a bug which has such a simple workaround (adding an option).
The workaround is simple but the impact is large:
1. It affects a large portion of the user base.
2. It requires the users to read the known-bugs section.
3. It requires the users to verify what the decimal seperator is on the system, and then take action accordingly.
4. If they change locale, they must remember to change the FLAC parameter too.
Many people will be affected by this bug without knowing it. Many people will think they are affected and set the parameter to a faulty value.
That is the last I will say about that.
I'd even say "Many people are currently being affected by this (small) bug without knowing it". I won't say more.
This bug is not called out with regards to other versions (notable 1.1.2, 1.1.1) Can I safely assume that this section of the website is accurate, so earlier versions are free of this bug?
Triza
note there is one known bug that will affect the compression ratio for some locales but there is a workaround; see known bugs (http://flac.sourceforge.net/documentation.html#bugs).
downloads at http://flac.sourceforge.net/download.html (http://flac.sourceforge.net/download.html) or http://sourceforge.net/project/showfiles.php?group_id=13478 (http://sourceforge.net/project/showfiles.php?group_id=13478)
MD5 sums:
1986cf97d7a04d8b425d9c61fe6b52b3 flac-1.1.3-devel-win.zip
de9771830c6b879632ce50ce0052b830 flac-1.1.3-linux-i386.tar.gz
ad00df28be05eaa773854cf5da31f208 flac-1.1.3-osx-ppc.tar.gz
9badf34f5f717426babd2d9da4715aa4 flac-1.1.3-win.zip
b084603948b60ee338e0c29978cc580c flac-1.1.3.tar.gz
SHA-1 sums:
b5229a913b2c860fcd879bdacb6a9b797bd44e0d flac-1.1.3-devel-win.zip
e8ad3debe240eb329d8a186e8066e08681679c62 flac-1.1.3-linux-i386.tar.gz
3c0e10dba0da045364b0cc23c3694a201a2d87c0 flac-1.1.3-osx-ppc.tar.gz
3f048d915c95e4c9478e9e7249bc508a66245247 flac-1.1.3-win.zip
e19c92bebe536b69dd14d54de76c1f626b83b295 flac-1.1.3.tar.gz
Cut and paste the following script[..] into a text editor and name it something like "convert.cmd".
Does it preserve the tags?
Cut and paste the following script[..] into a text editor and name it something like "convert.cmd".
Does it preserve the tags?
Yes it does.
This bug is not called out with regards to other versions (notable 1.1.2, 1.1.1) Can I safely assume that this section of the website is accurate, so earlier versions are free of this bug?
Triza
Yes they are BUT you should not switch back to an older version. The bug will not damage your files or do them any harm. The only issue is that the compression will not be as good as it could be, but it will still be as good as 1.1.2 (maybe a little bit better).
You still profit from the enhanced tagging features and the updated decoder.
What's the simplest way to re-encode FLAC files with 1.1.3? I'm a windows user, and FLAC Frontend will not take FLAC as input to be encoded to FLAC. I want to keep all tags, etc, just encode with newer FLAC. (also, i'm not a command line master, so..)
Cut and paste the following script (author unknown to me) into a text editor and name it something like "convert.cmd". Put in in the root of your flac directory. Doubleclick. And do something great of your day while reencoding.
@echo off
set encoder="C:\Program\Sound\Coding\Flac\flac.exe"
for /r "." %%d in (.) do (cd %%d & for %%f in (*.flac) do %encoder% -8 -V -f -A "tukey(0,5)" "%%f")
Note: Of course you change the directory path of flac.exe to your specific.
Script takes care of the dot/comma bug.
EDIT: And it preserves the old tags.
If I use this script under Windows XP and I run this inside a map with FLAC files (no sub directories), then FLAC first encodes all files, but then starts again with the files it has already encoded. Am I doing something wrong?
BTW, it saves me 900KB of 300MB of files, so the improvement is not that much :-).
(Moved to a new topic)
John33, does your compile of flac 1.1.3 over at Rarewares take care of the dot/comma bug?
John33, does your compile of flac 1.1.3 over at Rarewares take care of the dot/comma bug?
I've just uploaded a fresh compile which includes Josh's fix (I think! ). Can you try it and let me know, please?
Hi John33
I had just finished testing your first compile, as i suspected that it included the comma bug-fix, since it was compiled on the 8th January and the comma bug-fix submitted to CVS on the 5th January, but as you posted previously(and my test showed) it didn't. Anyway, i have just finished testing this new compile and it works perfectly and i got 0.5% better compression ratio on the default -5 setting. Also, could you please tell me if you have just included the single fix for the comma bug to the v1.1.3 release sources, or if you have done a compile of the newest CVS snapshot, so that the bug that would truncate output files after the first error when doing FLAC to FLAC transcoding of corrupt FLAC's also would be gone ?
Note: to others that want's to use this compile, then you will need to also download the libmmd.dll file, which also can be downloaded from rarewares.
Many thank's John33 for your continued efforts of making compiles available to us, it's much appreciated
Thank's in advance.
CU, Martin.
Hi John33
I had just finished testing your first compile, as i suspected that it included the comma bug-fix, since it was compiled on the 8th January and the comma bug-fix submitted to CVS on the 5th January, but as you posted previously(and my test showed) it didn't. Anyway, i have just finished testing this new compile and it works perfectly and i got 0.5% better compression ratio on the default -5 setting. Also, could you please tell me if you have just included the single fix for the comma bug to the v1.1.3 release sources, or if you have done a compile of the newest CVS snapshot, so that the bug that would truncate output files after the first error when doing FLAC to FLAC transcoding of corrupt FLAC's also would be gone ?
Note: to others that want's to use this compile, then you will need to also download the libmmd.dll file, which also can be downloaded from rarewares.
Many thank's John33 for your continued efforts of making compiles available to us, it's much appreciated
Thank's in advance.
CU, Martin.
I included the single fix. However, if the consensus is that I should use the current CVS, I can do that easily enough. Is that safe, Josh?
BTW, thanks for the feedback on the compile.
I included the single fix. However, if the consensus is that I should use the current CVS, I can do that easily enough. Is that safe, Josh?
BTW, thanks for the feedback on the compile.
Confirming that it works like a charm. Many thanks John, really appreciated! Speaking for myself, I see no use for a compile from the current CVS so no arm in the air here
I included the single fix. However, if the consensus is that I should use the current CVS, I can do that easily enough. Is that safe, Josh?
I think so, I have not checked in anything but small bug fixes since the release. best to alter the vendor string in src/libFLAC/format.c though (like make the end say 20070113-john33 or something unique)
Josh
excuse me? can i make a feature request, i need messages of flac to be marked with colours. errors - red, ok's - green.
can you make this possible? it would be very suitable!
@John33
I don't think that you have to make a CVS release of flac either(unless you want to ), and i just asked, since i wanted to know what code i was using.
Btw, the bug-fixes that i know about from CVS is :
Fix bug where FLAC-to-FLAC transcoding of a corrupted FLAC file would truncate the transcoded file at the first error (SF#1615019: https://sourceforge.net/tracker/index.php?f...mp;atid=113478) (https://sourceforge.net/tracker/index.php?func=detail&aid=1615019&group_id=13478&atid=113478))
Fix bug where using -F with FLAC-to-FLAC transcoding of a corrupted FLAC would have no effect (SF#1615391: https://sourceforge.net/tracker/index.php?f...mp;atid=113478) (https://sourceforge.net/tracker/index.php?func=detail&aid=1615391&group_id=13478&atid=113478))
From the CVS repository of flac/src/flac/encode.c : http://flac.cvs.sourceforge.net/flac/flac/...code.c?view=log (http://flac.cvs.sourceforge.net/flac/flac/src/flac/encode.c?view=log)
And then of course the comma fix already included from the stream_encoder.c source.
CU, Martin.
OK, guys, thanks for the feedback. I'll not bother with the current CVS for now, but if it becomes appropriate at a later date just ask and all shall be provided!!
@Josh Coalson
Do you know why the optimized(ICL9.1-SSE2) flac.exe builds gives different filesizes ? There's no problem though, as i have verified that the decoded WAVs are bit-identical to the source files, but i was just currious about the exact reason for this.
PS. Many thank's for this new release which IMHO is just downright awesome and actually made me switch from WavPack to FLAC
Thank's again, mate
CU, Martin.
Edit: Of course i have remembered to add -A "tukey(0,5)" to the command-line of the stock compile when i compared the output filesizes of the stock compile VS the ICL9.1-SSE2 optimized compile, as the ICL9.1-SSE2 optimized compile's sources was taken from CVS after the 5th December 2005, so that it would include the comma decimal seperator bug-fix.
Do you know why the optimized(ICL9.1-SSE2) flac.exe builds gives different filesizes ?
The answer from another topic ([a href='index.php?showtopic=48978']LAME 3.97: different binaries produce differente results![/a]):
It's because of different floating point calculations reordering dony by compilers, which are producing slightly different results. Floating point only has a limited precision, and there is often some approximations in the result compared to the theorical formal result.
Yes, i know that this is the explenation for lossy codecs, but i would just think that introducing rounding errors into the calculations for lossless PCM samples would make the output lossy ?
Thank's for your reply, mate
CU, Martin.
libFLAC still uses floating point for the LPC analysis stage, so rounding errors can affect the filter creation. losslessness is achieved by substracting the filtered signal from the original and storing that, which is why it will always be lossless. i.e. if x is original signal, f() is filter, e is error, encoder computes e=x-f(x), and sends e and f only.
Josh
@Josh
Thank you very much for the explanation
Also have you any plans of adding wild-card support to flac.exe and metaflac.exe ?
@Egor
Sorry, mate - you where absolutely right
CU, Martin.
Many thank's for this new release which IMHO is just downright awesome and actually made me switch from WavPack to FLAC
Just curious : what FLAC features made you switch ? What does FLAC currently have that WavPack doesn't ?
Thanks.
What does FLAC currently have that WavPack doesn't ?
FLAC decodes faster and compresses better than WavPack's fastest decoding mode. FLAC has a CUESHEET metadata block which can decode single tracks out from the command line. FLAC has a PICTURE metadata block. FLAC can take FLAC files as input and transcode from FLAC to FLAC and also transfer tags. FLAC has a verify-while-encoding(-V) option. FLAC has better software support. FLAC has better hardware support.
what FLAC features made you switch ?
I'm only interested in very fast decoding and not in lossy or hybrid mode or getting better compression in trade of lower decoding speed and then i saw that the new FLAC version both decoded faster while also compressing better than WavPack's fastest decoding mode. Then other features of the new FLAC version really impressed me like with it's added FLAC to FLAC transcoding while transfering all tags and a switch for embedding a cuesheet into a Vorbis comment(like WavPack) + even better than before error correction + giving better compression without decoding penalty.
CU, Martin.
Sorry, for repeating my question, but just in case that it was missed the first time around
@Josh Coalson
Would you please consider being so kind as to add wildcard support to flac.exe and metaflac.exe in a new version sometime ? Some days ago i wanted to test my FLAC archive before i re-encoded them again with the added -A "tukey(0,5)" switch, as i had forgotten to use that switch the first time around and had a comma as decimal seperator. Then i first rightclicked on my FLAC folder and selected "Open Command Window Here" and then i just typed "flac -t *.flac", but recieved an error message and so i understood that flac.exe didn't expanded wildcards unfortunetly. This then means that instead of being able to do this : "flac -t *.flac", then we have to do this instead : for %G in (*.flac) do flac -t "%G". Luckilly then Tycho has compiled a globbing utility which code is listed on the net and which i now use instead, but IMHO, then i really think that wildcard support for the command-line tools of FLAC, is a really important feature missing.
Anyway, i just wanted to fill this feature request to you, and also say many thank's for all your great work on the FLAC format.
CU, Martin.
I feel your pain Martin! this has come up before, have you seen the other discussions on it? I'm hesitant to add non-portable stuff to fix a bug in the windows shell that has been there for like 20+ years. some of the easy workarounds are too dangerous to be acceptable:
http://mail.python.org/pipermail/python-de...une/000397.html (http://mail.python.org/pipermail/python-dev/1999-June/000397.html)
Sorry, for repeating my question, but just in case that it was missed the first time around
@Josh Coalson
Would you please consider being so kind as to add wildcard support to flac.exe and metaflac.exe in a new version sometime ?
Martin, that's not a FLAC thing: it's a Windows thing. Wildcards work fine in Linux.
Wow ! A 20-year old bug ! Amazing ! Thanks Bill !
I feel your pain Martin! this has come up before, have you seen the other discussions on it? I'm hesitant to add non-portable stuff to fix a bug in the windows shell that has been there for like 20+ years. some of the easy workarounds are too dangerous to be acceptable:
http://mail.python.org/pipermail/python-de...une/000397.html (http://mail.python.org/pipermail/python-dev/1999-June/000397.html)
Thank's for your reply Josh No, i actually haden't seen any previous discussions about this before, but i perfectly understand your reasoning for not implementing it
Thank you anyways
CU, Martin.
@Heliologue
Yes, i know that, mate
What's the simplest way to re-encode FLAC files with 1.1.3? I'm a windows user, and FLAC Frontend will not take FLAC as input to be encoded to FLAC. I want to keep all tags, etc, just encode with newer FLAC. (also, i'm not a command line master, so..)
Cut and paste the following script (author unknown to me) into a text editor and name it something like "convert.cmd". Put in in the root of your flac directory. Doubleclick. And do something great of your day while reencoding.
@echo off
set encoder="C:\Program\Sound\Coding\Flac\flac.exe"
for /r "." %%d in (.) do (cd %%d & for %%f in (*.flac) do %encoder% -8 -V -f -A "tukey(0,5)" "%%f")
Note: Of course you change the directory path of flac.exe to your specific.
Script takes care of the dot/comma bug.
EDIT: And it preserves the old tags.
Tested that script, works like a charm. Many thanks. Now I only have to run that script once for every new version of FLAC. However, sometimes I get this error:
"ERROR: Input file <insert filename here> has an ID3v2 tag."
What do I do about this? I've tried foobar's "Rewrite file tags", but to no avail.
I'm using FLAC 1.2.1, if it matters.
Tested that script, works like a charm. Many thanks. Now I only have to run that script once for every new version of FLAC. However, sometimes I get this error:
"ERROR: Input file <insert filename here> has an ID3v2 tag."
What do I do about this? I've tried foobar's "Rewrite file tags", but to no avail.
I'm using FLAC 1.2.1, if it matters.
Try the Mp3tag program, it may be possible to remove the felonious ID3 tag with it.
Try the Mp3tag program, it may be possible to remove the felonious ID3 tag with it.
Thanks, I'll try. Is there no other way around this, to make it automatic? Preferably by including something in the script?
Sorry, for repeating my question, but just in case that it was missed the first time around
@Josh Coalson
Would you please consider being so kind as to add wildcard support to flac.exe and metaflac.exe in a new version sometime ?
Martin, that's not a FLAC thing: it's a Windows thing. Wildcards work fine in Linux.
Guys, wildcards are done by your shell. It is a shell thing. It is not a Linux thing or a Windows thing. It is a shell thing.
If you write *.flac shell finds all the files ending with flac and passes these filenames to flac.
Putting a functionality like this into FLAC would be very bad idea. Possibly will cause problems. For example if the filename passed onto FLAC has these metacharacters, then we have a problem. Frankly escaping them would be awfully unusual and probably difficult, too for anyone used to how command line applications should work.
Regards,
Triza
Sorry, for repeating my question, but just in case that it was missed the first time around
@Josh Coalson
Would you please consider being so kind as to add wildcard support to flac.exe and metaflac.exe in a new version sometime ? Some days ago i wanted to test my FLAC archive before i re-encoded them again with the added -A "tukey(0,5)" switch, as i had forgotten to use that switch the first time around and had a comma as decimal seperator. Then i first rightclicked on my FLAC folder and selected "Open Command Window Here" and then i just typed "flac -t *.flac", but recieved an error message and so i understood that flac.exe didn't expanded wildcards unfortunetly. This then means that instead of being able to do this : "flac -t *.flac", then we have to do this instead : for %G in (*.flac) do flac -t "%G". Luckilly then Tycho has compiled a globbing utility which code is listed on the net and which i now use instead, but IMHO, then i really think that wildcard support for the command-line tools of FLAC, is a really important feature missing.
Anyway, i just wanted to fill this feature request to you, and also say many thank's for all your great work on the FLAC format.
CU, Martin.
I still don't quite understand how this works: for %G in (*.flac) do flac -t "%G". How do I encode a entire directory to flac if I cannot use "*.wav"? What do I use to substitute "*".wav?
Who says that you can't use "*.wav"?
If running from the command line in the directory with the WAVE files, and FLAC is in a folder in PATH (like your Windows folder) the following should work fine:
FOR %G IN (*.wav) DO FLAC -6 "%G"