Re: [flac-dev] warning that legacy WAVE file has format type 1 but bits-per-sample is 24
Brian Willoughby wrote: > Are there some (old) programs that will not accept WAVEX headers? I'm > trying to think of why the flac utility worked this way in the first place. Yes probably. But that was probably 10 years ago or more. > In any event, it seems like it would be prudent to add a command line > option to preserve the existing behavior, just in case anyone has archived > their audio using FLAC and would need to maintain compatibility with the > legacy WAVE format. Its trvially easy to losslessly convert between legacy and WAVEX formats. Like I said, sndfile-convert does it. > It's not always possible to replace certain old programs, > especially in recording studios. A program that suppoprts 24 bit WAV and does support WAVEX would have had to be really old even 10 years ago. I don't think its worth adding this command line flag unless someone actually runs into the problem. Erik -- -- Erik de Castro Lopo http://www.mega-nerd.com/ ___ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev
Re: [flac-dev] warning that legacy WAVE file has format type 1 but bits-per-sample is 24
On May 26, 2017, at 9:52 PM, Erik de Castro Lopo wrote: > Mark H. David wrote: >> Notice the warning was given only for the WAVE file produced by the >> flac reference executable. > > I agree. The flac decoder should not generate WAV files which it > warns about when encoding. > >> Should I file a bug for this? > > No need. This is sufficient. > > Erik Are there some (old) programs that will not accept WAVEX headers? I'm trying to think of why the flac utility worked this way in the first place. In any event, it seems like it would be prudent to add a command line option to preserve the existing behavior, just in case anyone has archived their audio using FLAC and would need to maintain compatibility with the legacy WAVE format. It's not always possible to replace certain old programs, especially in recording studios. Brian Willoughby Sound Consulting ___ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev
Re: [flac-dev] warning that legacy WAVE file has format type 1 but bits-per-sample is 24
Erik de Castro Lopo wrote: > > Notice the warning was given only for the WAVE file produced by the > > flac reference executable. > > I agree. The flac decoder should not generate WAV files which it > warns about when encoding. Fixed in Git. Thanks, Erik -- -- Erik de Castro Lopo http://www.mega-nerd.com/ ___ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev
Re: [flac-dev] warning that legacy WAVE file has format type 1 but bits-per-sample is 24
Mark H. David wrote: > Notice the warning was given only for the WAVE file produced by the > flac reference executable. I agree. The flac decoder should not generate WAV files which it warns about when encoding. > Should I file a bug for this? No need. This is sufficient. Erik -- -- Erik de Castro Lopo http://www.mega-nerd.com/ ___ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev
Re: [flac-dev] warning that legacy WAVE file has format type 1 but bits-per-sample is 24
Thank you for writing and pointing out that one can have WAVE files without getting the warning, and that your library does it. I found out Goldwave (Windows software) writes 24-bit WAVE files that do not get the warning. (Good for them!) However, the flac executable from the flac reference software apparently produces WAVE files that do get the warning. Example annotated log: Encode a 24-bit WAVE file (produced by Goldwave) into a FLAC file: $ flac -V junk-24.wav flac 1.3.2 Copyright (C) 2000-2009 Josh Coalson, 2011-2016 Xiph.Org Foundation flac comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. Type `flac' for details. junk-24.wav: Verify OK, wrote 64836 bytes, ratio=0.001 Decode the FLAC file back into a WAVE file: $ flac --decode --output-name=junk-24-back-out.wav junk-24.flac flac 1.3.2 Copyright (C) 2000-2009 Josh Coalson, 2011-2016 Xiph.Org Foundation flac comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. Type `flac' for details. junk-24.flac: done Encode the resulting WAVE file into a FLAC file: $ flac -V junk-24-back-out.wav flac 1.3.2 Copyright (C) 2000-2009 Josh Coalson, 2011-2016 Xiph.Org Foundation flac comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. Type `flac' for details. junk-24-back-out.wav: WARNING: legacy WAVE file has format type 1 but bits-per-sample=24 junk-24-back-out.wav: Verify OK, wrote 64792 bytes, ratio=0.001 Notice the warning was given only for the WAVE file produced by the flac reference executable. Should I file a bug for this? Thanks, Mark - Original message - From: Erik de Castro Lopo To: flac-dev@xiph.org Subject: Re: [flac-dev] warning that legacy WAVE file has format type 1 but bits-per-sample is 24 Date: Sat, 27 May 2017 08:40:24 +1000 Mark H. David wrote: > I'm new at this and trying to understand it. Can someone explain?\ You are correct. With a wFormatTag of 1, the bist per sample should be either 8 or 16 (according to the Microsoft specs). > Also, a related but more practical question: is there *any* way to > create a 24- or 32-bits-per-sample WAVE file without getting this > warning when flac tries to encode it? Yes there is. To avoid this wanring the it should have a WAVE_FORMATEXTENSIBLE wFormatTag. Its trivally easy to convert your legacy format file to WAVEX using the sndfile-convert program that is part of https://mega-nerd.com/libsndfile/ Erik -- -- Erik de Castro Lopo http://www.mega-nerd.com/ ___ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev ___ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev
Re: [flac-dev] warning that legacy WAVE file has format type 1 but bits-per-sample is 24
Mark H. David wrote: > I'm new at this and trying to understand it. Can someone explain?\ You are correct. With a wFormatTag of 1, the bist per sample should be either 8 or 16 (according to the Microsoft specs). > Also, a related but more practical question: is there *any* way to > create a 24- or 32-bits-per-sample WAVE file without getting this > warning when flac tries to encode it? Yes there is. To avoid this wanring the it should have a WAVE_FORMATEXTENSIBLE wFormatTag. Its trivally easy to convert your legacy format file to WAVEX using the sndfile-convert program that is part of https://mega-nerd.com/libsndfile/ Erik -- -- Erik de Castro Lopo http://www.mega-nerd.com/ ___ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev
[flac-dev] warning that legacy WAVE file has format type 1 but bits-per-sample is 24
Hello, I've tried encoding a FLAC file from a WAVE file saved with 24-bits-per-sample, using the flac executable. I get this warning: WARNING: legacy WAVE file has format type 1 but bits-per-sample=24 The code is currently here on line 373: src/flac/encode.c where the comment says let these slide with a warning since they're unambiguous I do not really understand the warning when I try to break it down. First, *legacy* WAVE file -- what makes this a "legacy" WAVE file? Second, format type 1 What is that exactly? In the source code I see "format type" is referred to as "format tag", since the variable name is "wFormatTag". Is this what's referred to in this reference http://soundfile.sapp.org/doc/WaveFormat/ as AudioFormat There it says 1 for PCM Is there something about PCM format that implies either 8- or 16-bits-per-second? I'm new at this and trying to understand it. Can someone explain? Also, a related but more practical question: is there *any* way to create a 24- or 32-bits-per-sample WAVE file without getting this warning when flac tries to encode it? Thanks, Mark ___ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev