I need to calculate the total length of an mp3 file.
Currently I am using a PHP class which I found @ http://www.zedwood.com/article/php-calculate-duration-of-mp3.>
A Famous and Very SPI that you can use MP3 SPI and the code is also very simple
File file = new File("filename.mp3"); AudioFileFormat baseFileFormat = AudioSystem.getAudioFileFormat(file); Map properties = baseFileFormat.properties(); Long duration = (Long) properties.get("duration");