/*******************************************************/ /* AudioCD grabber & encoder */ /*******************************************************/ /* Req: */ /* - Alfons.exe - The Digital CDROM grabber */ /* http://hobbes.nmsu.edu/h-search.php?key=alfons */ /* */ /* - lame.exe - LAME encoder for create MP3-files */ /* http://hobbes.nmsu.edu/h-search.php?key=lame-3.9 */ /* */ /* - oggenc.exe; */ /* ogg.dll; */ /* vorbis.dll - Ogg vorbis encoder files for create */ /* OGG-files */ /* http://hobbes.nmsu.edu/h-search.php?key=oggvorbis */ /*******************************************************/ /* Before use, set the following values: */ CDROMname = "G:" /* name of the CD-drive, containing the audio CD */ erasef = 0 /* 1 - erase source files after encoding */ audiograb = 1 /* 1 - use alfons for grabbing CD */ coder = "lame" /* "ogg" or "lame" - used encoder */ artist = "Artist" /* Name of artist */ album = "Album" /* Name of album */ year = "2009" /* year of album */ genrie = "POP" /* genrie of album */ numf = 20 /* number of tracks in the album */ title.1 ="" /* name songs 1 */ title.2 ="" /* name songs 2 */ title.3 ="" /* ... */ title.4 ="" title.5 ="" title.6 ="" title.7 ="" title.8 ="" title.9 ="" title.10="" title.11="" title.12="" title.13="" title.14="" title.15="" title.16="" title.17="" title.18="" title.19="" title.20="" /* title.21="" title.22="" title.23="" title.24="" title.25="" */ /*******************************************************/ PARSE ARG pauseAt do num=1 to numf if title.num = "" then title.num = "Track "||num end SAY "Number of files: "numf SAY " Artist: "artist SAY " CD Name: "album SAY " Year: "year Say " TG: "genrie DO num=1 to numf fname.num = "TRACK"||num||".WAV" if coder="ogg" then oname.num = "Track_"right(num,2,0)".ogg" else oname.num = "Track_"right(num,2,0)".mp3" if audiograb=1 then do SAY " " SAY "Grabbing Song #"num "ALFONS.EXE "||CDROMname||" g "||num end SAY " " SAY "Encoding Song #"num", Title: "title.num SAY fname.num" => "oname.num if coder="ogg" then 'start /c /min OGGENC.EXE -q 6 -t "'||title.num||'" -a "'||artist||'" -l "'||album||'" -d '||year||' -N '||num||' -G '||genrie||' -o "'||oname.num'" 'fname.num else 'start /c /min LAME.EXE -h -V 3 --tt "'||title.num||'" --ta "'||artist||'" --tl "'||album||'" --ty "'||year||'" --tg "'||genrie||'" --tn '||num fname.num oname.num IF pauseAt = num THEN "@PAUSE" END if erasef=1 then do say " " say "Wait the end of encoding of tracks" '@PAUSE' do num=1 to numf fname.num = "TRACK"||num||".WAV" SAY "Deleting File "fname.num '@ERASE 'fname.num end end SAY " " SAY "The end. Total encoded "numf" files"