Go Back   Winamp Forums > Developer Center > Winamp Development

Reply
Thread Tools Search this Thread Display Modes
Old 19th June 2002, 14:53   #1
schar4
Junior Member
 
Join Date: Jun 2002
Location: Montreal
Posts: 2
Streaming with java

I'm builded a SwingApplet that displays last songs played and some statistics.

Now I want to add a button that connect to the stream and play my station through the applet, so I won't need winamp to listen to it. I think I can use the javax.sound.sampled class to do it (AudioInputStream...) but I don't know exactly how. I DL some free codes but they belong to complexes API and I don't know what is doing what and I can't get it to work.

Your solution would be strongly appreciate.

Bye everyone.
schar4 is offline   Reply With Quote
Old 20th June 2002, 17:09   #2
schar4
Junior Member
 
Join Date: Jun 2002
Location: Montreal
Posts: 2
Sample of my code

public Player(){
try{
m_audioInputStream = AudioSystem.getAudioInputStream( new URL ("http", "www.myURL.com", 8000, "") );
...

The program exit after that line, heres the error message :

javax.sound.sampled.UnsupportedAudioFileException: could not get audio input stream from input stream

I tried ... new URL("http", "www.myURL.com", 8000, "listen.pls"); and it's not working either.

please HELP ME
schar4 is offline   Reply With Quote
Old 20th June 2002, 21:50   #3
Gourou
Senior Member
 
Gourou's Avatar
 
Join Date: Feb 2002
Location: The backside of the universe on the trailing edge of eternity
Posts: 238
I think that only gets a wave stream, not an mp3 stream
Gourou is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Developer Center > Winamp Development

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump