|
$Id: mp3info.rb,v 1.3 2003/09/04 18:25:31 moumar Exp $
ruby-mp3info gives you access to low level informations on mp3 files (bitrate, length, samplerate, etc...). It can read, write, remove id3v1 tag and read id3v2. It is written in pure ruby.
get tar.gz at rubyforge.org/projects/ruby-mp3info/
$ ruby install.rb config $ ruby install.rb setup # ruby install.rb install
require "mp3info" mp3info = Mp3Info.new("myfile.mp3") puts "MPEG #{info.mpeg_version} Layer #{info.layer} #{info.vbr ? "VBR" : "CBR"} #{info.bitrate} Kbps #{info.channel_mode} #{info.samplerate} Hz length #{info.length} sec. error protection #{info.error_protection}"
Test::Unit library is used for tests. see testunit.talbott.ws/
$ ruby test.rb
[0.2.1 04/09/2003]
[0.2 18/08/2003]
[0.1 17/03/2003]
License: | Ruby |
Author: | Guillaume Pierronnet (moumar_AT__rubyforge_DOT_org) |
Website: | ruby-mp3info.rubyforge.org/ |
Classes and Modules |