Every time I export a track as a FLAC file, the waveform appears “cut” at the top and bottom. After some testing, I discovered that the cut consistently measures around -0.1 dB when applying the “Amplify” effect. This happens every single time I export to FLAC, regardless of how the waveform looks before exporting, the exported file always ends up slightly “silenced” by about -0.1 dB.
In the attached images, the first waveform shows the original file. The second shows what it looks like after the first export. The second image is the result after exporting that same file again, repeating the export process five times in total, the waveform ends up quieter by around -0.5 dB overall.
Why does this happen, and is there any way to prevent it?
That shouldn’t happen (and it doesn’t happen to me). FLAC is lossless but it’s an integer format (like WAV) so it is hard-limited to 0dB.
I just tried a file that goes over 0dB and the FLAC came-back with peaks at exactly 0dB (as expected).
Are you just looking visually?
You can quickly check the peak level by running the Amplify effect. Audacity has already scanned your file and Amplify will default to whatever up or down change is needed for 0dB peaks. For example, if Amplification defaults to 1dB, your peaks are currently -1dB. If it defaults to -1dB your peaks are currently +1dB (and it wants to attenuate rather than amplify).
If you don’t actually want to run the Amplify effect you can cancel after making note of the peak.
NOTE - In case you don’t know this, 0dB should be considered the “digital maximum”. Your ADC (recording), your DAC (playback), regular WAV files, FLAC files, and audio CDs are all limited 0dB and you’ll get clipping (distortion if you “try” to go over.
One of the side effects of MP3 compression is that some peaks get higher and some lower so it’s not unusual for an MP3 ripped from a CD to go over 0dB, and MP3 can go over 0dB without clipping. You’ll clip your DAC if you play it a full-digital volume and for that reason, some people normalize to about -1dB before exporting as MP3. (I can’t hear the slight clipping and MP3 is lossy anyway so I don’t worry about it,)
P.S.
Are you changing the sample rate? Re-sampling is be “imperfect”. But I wouldn’t think you are re-sampling 5 times.
If you are not using real-time effects, the exported FLAC file should be virtually identical to the track (it probably won’t be exactly the same due to dither, but should be extremely close).
If you are using real-time effects, the exported file is likely to look significantly different due to the effect being applied.