illustrate
Products            Buy            Support Forum            Registrations            Professional            About           
 

Is there a way to batch convert .IMG files to Flac or MP3

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sandman

    • Oct 2012
    • 5

    Is there a way to batch convert .IMG files to Flac or MP3

    Is there a way to batch convert .IMG files to Flac or MP3. I have an MF digital Scribe PC that saves audio cd images as .IMG files.
  • pablogm123
    dBpoweramp Enthusiast

    • May 2012
    • 86

    #2
    Re: Is there a way to batch convert .IMG files to Flac or MP3

    As far I kwow, dBpoweramp cannot handle raw headerless file (.bin/.img images of CDDA discs outputted by CDRWin, CloneCD and similar programs are actually a monolithic PCM audio file without header [but .mdf files created by Alcohol 120% can contain interleaved subcode data]). However, the FLAC and WAVPACK official command line encoders can handle easily these files. If that files are actually headerless PCM audio files, you can do this:

    I run this .cmd file to batch convert these files into .wv files, assuming that those files are named .pcm:
    Code:
    @set path=[Absolute path to folder which contains the encoder]
    @for /r %%G in (*.pcm) do call :process "%%G"
    @:process
    @set tmpfile=%1
    @if NOT %~x1==.pcm goto exit
    @wavpack.exe -hhx3 -m -l --raw-pcm -t %tmpfile% %tmpfile:.pcm=.wv%
    :exit
    It seems that you are interested in FLAC format. Replace the @wavpack line with this one:
    Code:
    @flac.exe -8 -V --endian=little --channels=2 --bps=16 --sample-rate=44100 --sign=signed --force-raw-format %tmpfile% %tmpfile:.pcm=.flac%
    Of course, you can alter the compression settings, to obtain faster encodes.

    Last but not least, to split these files into individual tracks you need a .cue file, and you have to modify the first line of that file. For example:
    FILE "file.IMG" BINARY ----> FILE "file.flac" WAVE

    If you don't have a cue, you can generate it from subcode (CDs where TOC differs from subcode are veeery weird, so that using subcode for that is fine), using a old app named Subcode Analyzer 0.73.

    Once done, Foobar can open that images.
    Last edited by pablogm123; October 14, 2012, 06:30 PM.

    Comment

    • sandman

      • Oct 2012
      • 5

      #3
      Re: Is there a way to batch convert .IMG files to Flac or MP3

      Thanks! I will give it a try.

      Comment

      Working...