getting java.lang.ClassNotFoundException: javazoom.jl.decoder.JavaLayerException on linux but works on windows -
i using jlayer play mp3 file
the next code works after compiling project jar command java - jar blahblahblah.jar
but not linux.... ideas? java.lang.classnotfoundexception: javazoom.jl.decoder.javalayerexception
import java.io.bufferedinputstream; import java.io.file; import java.io.fileinputstream; import java.io.filenotfoundexception; import javazoom.jl.decoder.javalayerexception; import javazoom.jl.player.player; public class mp3jlayertest { /** * @param args command line arguments */ string filename; string directory; file mp3file; static player player; public static void main(string[] args) throws filenotfoundexception, javalayerexception { fileinputstream fis; fis = new fileinputstream("kalimba.mp3"); bufferedinputstream bis = new bufferedinputstream(fis); player = new player(bis); player.play(); new thread((runnable) new mp3jlayertest()).start(); } public void run() throws javalayerexception { player.play(); }
}
java linux mp3 raspberry-pi jlayer
No comments:
Post a Comment