Author Topic: Encoding from FLAC to MP3 (VBR) or Ogg generates clicks  (Read 348 times)

MikaelS

  • Posts: 201
Hello,

When I'm converting a FLAC file to either MP3 (VBR) or Ogg the converted file gets a small click at the start.
This is constantly reproducable, no matter which MP3 VBR quality that's used. Converting to MP3 CBR does not generate any clicks.

I'm using the most recent BASS version and the encoding is handled via a mixer. Using WASAPI or DirectSound does not make any change.

Has anyone else noticed this and are aware of a possible solution?

Thanks in advance.

Ian @ un4seen

  • Administrator
  • Posts: 21372
Are you using the BASSFLAC add-on or the Media Foundation FLAC codec to decode the FLAC file? If you're unsure, you can use BASS_ChannelGetInfo to find out (see the "ctype"). If it's Media Foundation, does using BASSFLAC instead prevent the problem? If not, here's an updated version of the BASSenc CONTEST example that supports plugins, for you to try:

   www.un4seen.com/stuff/bassenc-contest.zip

Can you reproduce the problem with that? If not, please compare its code with yours to hopefully find what's causing the problem.

MikaelS

  • Posts: 201
Thanks Ian. I will test this further.
In my application I use the BASSFLAC addon, but I will try to reproduce the issue with your example app.

MikaelS

  • Posts: 201
I think I found the reason.
When using BASS.NET and the MP3Encoder to get the commandline parameters for encoding, it adds some unwanted parameters, "-r -s 44.1 --bitwidth 16 -h".
By removing these parameters the encoding now works fine.

Thanks for your help Ian!