MP3 - ID 2 or 3 tags

Can anyone give me a hint how to pull MP3 ID tags out of the file ?
I’m guessing, it’s just part of the header information. I’m going to
dig around ruby-lang.org but just in case thought to ask here as well.

TIA
Stuart

I found the ID3lib on rubyforge which looks pretty good. Could I just
forgoe the library though and do this through standard FILE class ?

Stuart

Can anyone give me a hint how to pull MP3 ID tags out of the file ?

Have you tried ruby-mp3info ?

http://ruby-mp3info.rubyforge.org/

I’ve used it a bit and it worked fine for my needs.

Dark A. wrote:

TIA
Stuart

Funny advice on a Ruby list, I know, but Practical Common Lisp has
exactly this as an example :slight_smile:

http://www.gigamonkeys.com/book/practical-an-id3-parser.html

Interesting , this little exercise could turn into something way bigger.

Stuart

Alex Y. wrote:

Funny advice on a Ruby list, I know, but Practical Common Lisp has
exactly this as an example :slight_smile:

http://www.gigamonkeys.com/book/practical-an-id3-parser.html

It’s a good book, even if all you plan on doing is Ruby code.


James B.

“People want simple stories.”

Dark A. wrote:

I found the ID3lib on rubyforge which looks pretty good. Could I just
forgoe the library though and do this through standard FILE class ?

Stuart

Hey,

I wouldn’t recommend doing the parsing yourself, because there are
various versions of the ID3 standard (ID3v1, ID3v2.2.0, ID3v2.3.0, etc)
and ID3v2 is not a too simple format. The difficulty of doing it
yourself depends on what files you have and whether you also want to be
able to write ID3 data or not.

Rather use a library for the task, here are two you can try:

http://rubyforge.org/projects/id3lib-ruby/
http://rubyforge.org/projects/ruby-mp3info/

id3lib-ruby is based on the id3lib C++ library, so you have an
additional dependency there. Other than that, I’m its developer and can
recommend it of course :wink:

ruby-mp3info is written in Ruby, so you don’t have any additional
dependencies. I don’t know very much about its interface or stability,
but give it a try.

Regards,
Robin S.

On 7/6/06, Robin S. [email protected] wrote:

id3lib-ruby is based on the id3lib C++ library, so you have an
additional dependency there. Other than that, I’m its developer and can
recommend it of course :wink:

I found yours first and played around a bit ,seemed to work well.

Stuart

On Jul 6, 2006, at 9:31 AM, Alex Y. wrote:

well.
Alex

I was thinking the exact same thing.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs