32-bit float to 24-bit FLAC?

This section is now closed.
Forum rules
Audacity 1.3.x is now obsolete. Please use the current Audacity 2.1.x version.

Mac 0S X 10.3 and earlier are no longer supported but you can download legacy versions of Audacity for those systems HERE.
allencmcbride
Posts: 149
Joined: Wed Jul 30, 2008 2:02 am
Operating System: Please select

32-bit float to 24-bit FLAC?

Post by allencmcbride » Wed Apr 08, 2009 3:47 am

Koz wrote, in another thread,
FLAC will not manage floating point sound files. So if the original was 32-bit floating -- Audacity's famous default -- the FLAC output is undetermined if it works at all.
I'd like more information about this. In what sense is the FLAC output "undetermined"? I have been exporting 32-bit float files as 24-bit FLAC for archiving. I tested before I started doing this; re-import seemed to work fine, and I couldn't hear any loss of quality. I haven't noticed any trouble since then, either. But this makes me nervous all the same about what I've been doing to my audio. I haven't tried re-importing every FLAC file I've made.

Thanks,
Allen

P.S. Here is an old conversation between me and stevethefiddle, which is part of why I have been (over?)confident about exporting to 24-bit FLAC: http://audacityteam.org/forum/viewtopic.php?f=17&t=5744

kozikowski
Forum Staff
Posts: 69374
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: 32-bit float to 24-bit FLAC?

Post by kozikowski » Wed Apr 08, 2009 6:02 am

<<<I'd like more information about this.>>>

http://en.wikipedia.org/wiki/FLAC#Technical_details

"FLAC supports only fixed-point samples, not floating-point."

<<<I couldn't hear any loss of quality.>>>

That's not surprising. 44100/16/Stereo (CD) is good to go for something like 98% of people who listen to it. 48000/16/Stereo (Television) takes you up to something in the 99% range and probably higher. Any audio standard above that carries advantages that are completely inaudible by humans.

Super Standards are valuable for post production. The original capture quality is carried by so many bits in so many levels that you can maintain excellent quality after you apply serious special effects and edit your brains out.

Koz

allencmcbride
Posts: 149
Joined: Wed Jul 30, 2008 2:02 am
Operating System: Please select

Re: 32-bit float to 24-bit FLAC?

Post by allencmcbride » Wed Apr 08, 2009 4:00 pm

Hi Koz, thanks for the link and response, but what I'm really trying to ask is what Audacity does when I save a 32-bit float file as a 24-bit FLAC. I understand that FLAC doesn't support floating point, but I thought that when I saved as 24-bit FLAC, it just took the 24-bit "fractional part", left out the 8-bit "exponent", and that this was considered fine. (My scare-quotes are there to indicate that I don't fully understand what I'm saying, not that I'm skeptical of it. :-)) But you seem to be saying that Audacity might well be doing something else entirely when I save 32-bit float data as 24-bit FLAC. --Allen

kozikowski
Forum Staff
Posts: 69374
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: 32-bit float to 24-bit FLAC?

Post by kozikowski » Wed Apr 08, 2009 4:54 pm

<<<But you seem to be saying that Audacity might well be doing something else entirely>>>

Oh, it's worse than that. There is a recent thread by someone who is trying really hard to get good, simple digital accuracy with the Audacity Import and Export functions ... and is failing. His last posting is him throwing in the towel and going with a different audio program.

http://audacityteam.org/forum/viewtopic ... 429#p38424

Koz

allencmcbride
Posts: 149
Joined: Wed Jul 30, 2008 2:02 am
Operating System: Please select

Re: 32-bit float to 24-bit FLAC?

Post by allencmcbride » Wed Apr 08, 2009 5:38 pm

Thanks. Actually, that was the thread I was originally quoting you from. I'm not worried about a truncated sample or two, or the teensy dithering error that Steve describes. Just as long as, when I export, nothing's happening like, say, all the audio being converted to 16-bit and then dithered back up to 24-bit. But it doesn't sound like that's what you're talking about. --Allen

kozikowski
Forum Staff
Posts: 69374
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: 32-bit float to 24-bit FLAC?

Post by kozikowski » Wed Apr 08, 2009 8:31 pm

To your ears, Audacity always seems to do something desirable even if it's not exactly what you think it's going to do. Because Macs have the fewest developers and least number of helpers, we get pretty serious problems and it takes us a bit longer to stamp them out. We had that Long File AIFF Import problem a while back and there have been other Import-Export problems on other platforms.

I'd be delighted to be able to say that plain file handling was perfectly stable, but it doesn't seem to be the case. Although I will say when people lead their question with "Audacity won't import my music file," they usually mean they dug up an oddball file on the internet and it's in a wacko or protected file format. It gets our attention when somebody claims to export a standard audio file and then can't import it again. We can sometimes trace that back to a wacky import file that Audacity is just hanging onto with three fingers and then it finally breaks the whole way at the export step.

The poster references Cool Edit. I have a license for Cool Edit 2000 as well as the child, Audition. In order to export plain WAV files, they make you dig through many different flavors of WAV, and they do have an INFO panel to tell you what your prospective file type is before you import it.

Neither program was cheap and neither will run on a Mac.

I'm finding a semantic problem, too. If "I recorded it live" means you grabbed the stream from the internet, what words do you use for capturing a microphone and no internet connection?

Koz

allencmcbride
Posts: 149
Joined: Wed Jul 30, 2008 2:02 am
Operating System: Please select

Re: 32-bit float to 24-bit FLAC?

Post by allencmcbride » Wed Apr 08, 2009 9:54 pm

Thanks. I hope you don't think I'm complaining about Audacity or anything. I'm thrilled with it; I just want to understand what I'm doing with it as best I can. I think what I hear you saying is, Audacity may very well be exporting my 32-bit float data to 24-bit FLAC files just fine, preserving a full 24 bits of information in the process. But no one can guarantee, or necessarily even tell from the output, whether that's true. If that's the current state of knowledge, I'm cool with that. --Allen

kozikowski
Forum Staff
Posts: 69374
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: 32-bit float to 24-bit FLAC?

Post by kozikowski » Thu Apr 09, 2009 12:32 am

Somebody proved a bit ago that the 24 bit files weren't actually 24-bit, so I'm not making any claims at all.

Koz

allencmcbride
Posts: 149
Joined: Wed Jul 30, 2008 2:02 am
Operating System: Please select

Re: 32-bit float to 24-bit FLAC?

Post by allencmcbride » Thu Apr 09, 2009 4:49 am

Thanks, Koz. I assume you're referring to this thread that I just found through Google: http://audacityteam.org/forum/viewtopic.php?f=12&t=8653? (If not, please post a link to the discussion you are talking about, if you happen to know where to find it, and if you don't, don't worry about it.) But this thread has helped me understand how to test these things by setting the max dB display range and zooming in. I think what I've figured out is that my exported 24-bit FLAC files *are* in fact 24-bit, but not lossless. Rather, they're just a bit jiggled from the original data.

As for my soundcard, I think I can now see that it is truly recording in 24 bits as advertised (because I do see *some* samples below -96dB), but its noise floor seems to be around -90dB, making its 24-bit capability useless if I understand correctly. Good stuff to finally understand. I guess now I can save a bunch of disk space by converting all my exported files to 16 bits. --Allen

kozikowski
Forum Staff
Posts: 69374
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: 32-bit float to 24-bit FLAC?

Post by kozikowski » Thu Apr 09, 2009 6:46 am

Well, yes, if all you're going to do is straight capture a live performance and listen to it later, then my personal favorite, 48000/16/Stereo is enough for pretty much anybody. All digital television and Movie DVDs use that unless you're in Dolby Surround.

However, if you need filters or special effects, then you might need the additional bits, levels, and response typical of the higher numbers.

Knowing the destination or goal is a big deal.

The other way to check out your sampling is to simply magnify any waveform until you can see the time ruler and the sample points and count the points. It's a little harder to figure out if each point is unique, but any really high frequency tone or sound will do it.

Koz

Locked