Topic: 谁知道用Java播放mp3使用哪个类库?

  Print this page

1.谁知道用Java播放mp3使用哪个类库? Copy to clipboard
Posted by: laukin
Posted on: 2004-12-09 13:31

用JAVA实现播放MP3文件应该使用哪些类库

2.Re:谁知道用Java播放mp3使用哪个类库? [Re: laukin] Copy to clipboard
Posted by: littledeer1974
Posted on: 2004-12-09 17:31

不知道这个对你有没有帮助

http://java.sun.com/products/java-media/jmf/mp3/download.html

Unzip the JavaMP3plugin.zip in the JRE directory of your choice.
The included jar file (mp3plugin.jar) contains a Java Sound plugin as well as a Java Media Framework plugin for playing MPEG-2 Layer 3 Audio.

The jar file will be installed in the /lib/ext directory, where stands for the location on your system where the Java Runtime Environment is installed. For instance, on windows, this could be something like C:\Program Files\Java\j2re1.4.2_01.

That will make the plugin available for Java Sound applications and applets run using that specific JRE. If you have multiple JREs installed on your system, you must copy the mp3plugin.jar to each of those JRE installations.

For the plugin to work within a JMF application, you need to :

- ensure that jmf.jar is also in the /lib/ext directory
- run the following command:

java com.sun.media.codec.audio.mp3.JavaDecoder

You should see a message that it was successfully registered, without any error message.



---------------------------------------------------------------------------------------------
这个好象也可以参考
http://www.codetoad.com/java_mp3_player.asp


   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923