Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Convert a Lossless file to play in iTunes and iPods' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Convert a Lossless file to play in iTunes and iPods
Authored by: badger brigade on Mar 14, '04 10:14:50AM
Not ideal for iTunes and iPods, at least not yet, but there's an easy way to convert SHN files directly to Ogg Vorbis. You need oggenc installed, which is part of the vorbistools package at http://www.vorbis.com/download.psp , and the shorten CLI tool.
for i in *.shn;
do shorten -x "$i" - | oggenc --quality 6 --album ALBUM_NAME --artist ARTIST_NAME \
--date DATE --tracknum "1-${i:0:2}" --output="${i/%shn/ogg}" -;
done;
for FLAC files install the flac CLI decoder and use
for i in *.flac;
do flac -d -o - "$i" | oggenc --quality 6 --album ALBUM_NAME --artist ARTIST_NAME \
--date DATE --tracknum "1-${i:0:2}" --output="${i/%flac/ogg}" -;
done;


[ Reply to This | # ]
Convert a Lossless file to play in iTunes and iPods
Authored by: KRC on Mar 14, '04 10:42:34AM

That's pretty sweet! Thanks for the addition. I personally can't wait until Apple adds support for Ogg Vorbis in iTunes and their iPod ... that would really rock!

Of course, I would probably replace the

Quality 6
part of the script with a desired Quality number (I think highest is 10 or 400 kbps) ... for example, if all I'm doing is playing the track in UT2003 (eg. use UnrealEd to develop a map for community distribution and use that song exclusively for it), then it would be a setting equivilent to 128 kbps (which I forgot what Quality number that is since I haven't touched Ogg Vorbis in ages). If it's for general listening, I might go for a higher bitrate, say 192-ish.

[ Reply to This | # ]
the method i've been using
Authored by: ChrisR on Mar 17, '04 11:00:34AM

I've been using a similar method to get from flac to mp3:


for file in *.flac
do
  flac -c -d "$file" | 
  lame -h -m s -b 192 - "$(basename "$file" .flac).mp3"
done

Then I use id3tool (installed via fink) to hack up the tag before importing the files into iTunes. (It's possible to modify the id3 tag from the lame encoder command line, but I prefer to do it externally).

[ Reply to This | # ]

while we're at it...
Authored by: ChrisR on Mar 17, '04 11:13:47AM
...here's a script I wrote for converting my CDs to flac format:

#!/bin/sh
if test "$1"
then
  for file in "$1"/*.aiff
  do
    cp -v "$file" .
    flac \
      --endian=little \
      --sign=signed \
      --channels=2 \
      --sample-rate=44100 \
      --bps=16 \
      --delete-input-file \
      "$(basename "$file")"
  done
  for file in [1-9]\ *.flac
  do
    mv -v "$file" 0"$file"
  done
else
  echo >&2 "Usage: $(basename $0) /path/to/cd"
  exit 1
fi
Enjoy! ChrisR

[ Reply to This | # ]