AVS › AVS Forum › Audio › Audio theory, Setup and Chat › Strange Problem with FLAC to WAV Conversion
New Posts  All Forums:Forum Nav:

Strange Problem with FLAC to WAV Conversion

post #1 of 8
Thread Starter 
I have a problem with converting FLAC into WAV that I cannot solve and hope someone here has some tips.
A lot of audiofiles are in .flac format.
I use the batchconverter from Soundforge 10 to make wav's out of them.
I also change the bitdepth of these files into 24 bits.

I do a lot of upmixing to surround and use two different DTS encoders.
When I convert to 24 bits wav, the result of accepting these wavs' as real wav's varies a lot.
Every wav is accepted in Surcode DVD/DTS, in the DTS HD Encoder Suite some wav's are giving an
error message : only wav or aiff is accepted.

The surcode encoder gives back DTS in 16 bits although fed with 24 and the HD encoder suite,
gives back DTS in 24 bits for the wavs it accepts.

So, how come it accepts one flac to wav, but doesn't accept another one, made in the same way.
I'm completely lost here ;-)

What can I use to see if there is any difference between those wavs and flacs in their headers?
post #2 of 8
Thread Starter 
ADDITION : other flac to wav converters show the same problem, so I suspect it must be in the flac files.....
But what ? I have no idea !
post #3 of 8
Could it be a problem with the metadata? I know that FLAC has good support for tags, but WAV's support is ill defined and spotty. The converters may be trying to preserve tags in the WAV files, and some of those tags may be causing some programs to throw-up.

Try removing all tags from one of the FLAC files that fail, and see how the resulting WAV does.
post #4 of 8
Do the resulting files play in standard media players? If so, and the DTS encoding tool has problem opening them then it is a bug in its parser. Alternatively you can search for .wav file analyzers which parse the file and point out errors they see in them. I have used one of these before but don't recall its name right now.

By the way, there is no reason to change the resolution to 24. It simply expands the file and makes the encoding less efficient. So if you don't have problems with 16 bit depth, then stay with that.
post #5 of 8
Thread Starter 
Quote:
Originally Posted by MarkHotchkiss View Post

Could it be a problem with the metadata? I know that FLAC has good support for tags, but WAV's support is ill defined and spotty. The converters may be trying to preserve tags in the WAV files, and some of those tags may be causing some programs to throw-up.
Try removing all tags from one of the FLAC files that fail, and see how the resulting WAV does.

Thanks for your answer.
Well, it made it even more strange !
The flac files that give an error after converting to wav............ have no metadata at all in them !
The files with metadata went without a problem.

Difference I noticed :
Those I tested without metadata were done with FLAC 1.1
The ones with metadata were done with 1.2

Could this be the problem ?
post #6 of 8
Thread Starter 
Quote:
Originally Posted by amirm View Post

Do the resulting files play in standard media players? If so, and the DTS encoding tool has problem opening them then it is a bug in its parser. Alternatively you can search for .wav file analyzers which parse the file and point out errors they see in them. I have used one of these before but don't recall its name right now.
By the way, there is no reason to change the resolution to 24. It simply expands the file and makes the encoding less efficient. So if you don't have problems with 16 bit depth, then stay with that.

Yes, both the files flac and the corresponding wav, play fine in all players.

The reason to change the bitdepth to 24 bit is the fact that the conversion routines for stereo to surround work more secure with 24 bits than with 16 and even better with 96 or 88.2 Khz than with 44.1 Khz.
But beside that, the 24 bits are not the problem.
I like the suggestion of analysers on the wav files, but (see my other response) I believe it must be in the FLAC files........
I will search for a good analyser and see if that can fix the problems......
post #7 of 8
Just for grins, have you tried 16 bit conversions? If that works, it rules out the source files as the problem and definitely points to an encoder problem.
post #8 of 8
Thread Starter 
Quote:
Originally Posted by amirm View Post

Just for grins, have you tried 16 bit conversions? If that works, it rules out the source files as the problem and definitely points to an encoder problem.

Well, well, now this is really strange.
I took one of the files that gave problems.
Loaded the FLAC into Soundforge, saved it as 16 bit WAV and ...... it loaded into the DTS Master suite.
Then I loaded the wav into Soundforge, made it 24 bits, saved it and........ it loaded !

The problem is now brought back to :
- some flacs can be turned into 24 bits wav directly in Soundforge and work in DTS HD Mastersuite
- some flacs must be saved first as 16 bit wav, then the wav must be made into 24 bits and work in DTS HD Mastersuite.

At least now it's a lot easier, I just save every wav first with 16 bit and introduce an extra step to turn it into 24 bits.

It rules out the encoder, the fault definitely seems to be in different FLAC versions, where I conclude that version 1.1 flacs cannot be turned directly into 24 bits wavs and
version 1.2 flacs do ! OR flacs without metadata cannot be turned dorectly into 24 bits wavs and flacs with metadata do !

I know I have to do more tests with different wavs to see if this is a general rule.

It remains strange though smile.gif

Anyway thanks for pointing me into the right direction !

(FWIW stereo to surround conversion, my website : www.dtsac3.com in case you're interested.)
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Audio theory, Setup and Chat
AVS › AVS Forum › Audio › Audio theory, Setup and Chat › Strange Problem with FLAC to WAV Conversion