in reply to MP3 Info from filename?

If the files are missing ID3 tags, then there is really no way to get that data from the files themselves. If all the files use a common naming convention, you might be able to parse Artist & Track name from the file name and save that into the ID3 tag -- I assume that's what you're trying to do.

my ($Artist, $Track) = $Filename =~ /(.*) +- +(.*)\.mp3/i;

Replies are listed 'Best First'.
Re: Re: MP3 Info from filename?
by Willard B. Trophy (Hermit) on Oct 21, 2003 at 19:57 UTC
    It need not be all doom and gloom if you don't have meaningful file names, but you can identify all the tracks in a particular album. Rocco Caputo suggests in his documentation for CDDB.pm that you can recreate a CD's table of contents from MP3 durations.

    MP3::Info should be able to tell you the track duration with enough accuracy.

    This is all untried. It looks like it might work, though.

    --
    bowling trophy thieves, die!

      I found mp3cddb, a Perl/shell program to do freedb queries based on MP3s. It's a little old — it only supports ID3v1 — but it's GPL, so we can fix it.

      --
      bowling trophy thieves, die!