Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

AAC+ Icecast2 stream with JW Player


Hi,

The URL is:
http://radio.joinmyserver.com:8000/

I try to get the AAC+ stream to work with JW Player.
I read this article:
http://www.thebitstream.com/?p=233

So, it should be possible!?

bc.. <div id="player" align="center"><a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.</div>
<script type="text/javascript">
var so = new SWFObject('flash/player.swf', 'DFM-player', '300', '55','7');
so.addVariable('type', 'radio');
so.addParam('allowfullscreen','true');
so.addVariable('file', 'http://radio.joinmyserver.com:8000/radio.aac');
so.addVariable("autostart","false");
so.addVariable('displayheight','80');
so.addVariable('height','55');
so.addVariable('width','300');
so.addVariable('showeq','true');
so.addVariable('showdigits','false');
so.addVariable('frontcolor','0xffffff');
so.addVariable('backcolor','0x4F4F4F');
so.addVariable('lightcolor','0xFC9003');
so.addVariable('showicons','true');
so.addVariable('shuffle','false');
so.addVariable('usecaptions','true');
so.addVariable('usefullscreen','true');
so.addVariable('volume','95');
so.write('player');
</script>



Another try from me:
bc.. <div id='container'>The player will be placed here</div>

<script type="text/javascript">
var flashvars = {
file:'livepresentation',
flashvars:'file=http://radio.joinmyserver.com:8000/radio.aac&provider=video'
};

swfobject.embedSWF('flash/player.swf','container','480','270','9.0.115','false', flashvars,

{allowfullscreen:'false',allowscriptaccess:'always'},
{id:'jwplayer',name:'jwplayer'}

);
</script>



Both ways failed. It says it's not a valid media provider. I just don't know what I'm going wrong. The stream URL itself it just working great in XiiaLive, Winamp and VLC.

Thanks!

Kind regards,
Melroy van den Berg

46 Community Answers

JW Player

User  
0 rated :

so.addVariable('type', 'http');

Will load, no sound, but also no error... :(

JW Player

User  
0 rated :

I tried:

bc.. so.addVariable('type', 'flv');
so.addVariable('provider','video');



Still no sound.

JW Player

User  
0 rated :

How do they do it?
http://www.fastserv.com/news/article/aacplus_flash_player_support_added_to_icecast/

They got Icecast server with FLV enabled :S And some tweaks or something..?

JW Player

User  
0 rated :

You can install RTMP server like http://erlyvide.org/ to restream AAC stream into RTMP stream.
Flash player cannot read ADTS directly (container for AAC), also I don't advise FLV streaming because it will ruine your browser quckly.

JW Player

User  
0 rated :

Happily I found another solution then installing RTMP server.

You need to install/compile the Icast v2 KH version:
http://www.xiphicecast.webspace.virginmedia.com/

With '?type=.flv', you let Icecast know you want the flv stream with is a wrapper of your current one broadcasting AAC+.
The code is free and can you only need swfobject.js & player.swf. Both can be download from JW player:
http://www.longtailvideo.com/players/jw-flv-player/.

bc.. <script type="text/javascript" src="swfobject.js"></script>
<p id="preview" align="center"><a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.</p>
<script type="text/javascript">
var so = new SWFObject('player.swf','player','300','30','8');
so.addParam('allowfullscreen','true');
so.addParam('allowscriptaccess','always');
so.addVariable('file','http://ip:8000/mount_point%3Ftype%3D.flv');
so.addVariable('duration','360000');
so.addVariable('provider','video');
so.addVariable('autostart','false');
so.addVariable('backcolor','B4B4B4');
so.addVariable('frontcolor','3C3C3C');
so.addVariable('lightcolor','FFFFFF');
so.addVariable('screencolor','FFFFFF');
so.addVariable('volume','95');
so.write('preview');
</script>



Good luck :) I got it working ;)

Kind regards,
Melroy

JW Player

User  
1 rated :

Lol, about the FLV stream. It works great, no memory leaks seems working fine. Tomorrow I will test it for 8 hours non-stop listening.

JW Player

User  
0 rated :

EDIT:

I found out it's hard to send metadata with the FLV stream. Can rtmp handle metadata such as title and artist?

JW Player

User  
0 rated :

Yes. By tomorow the new shoutcast jar and shoutcast app will be released for red5.

This new version has an automatic rss playlist generator for JWPlayer.

The new version sends all stream title updates as 'onMetaData' events.

It is very easy to send the title data inside the flv stream. I think the KH version is still being stroked out.

JW Player

User  
0 rated :

As I hoped to accomplish.

New red5 shoutcast jar and app. It works like a shoutcast version one server for encoders or subscribes to another actual shoutcast server.

Includes automatic rss playlist for JWPlayer.

http://www.thebitstream.com/?p=243

JW Player

User  
0 rated :

The FLV handling including metadata inserts (which I expanded on) has been rather solid in the last few releases but in kh29 I added some extra checks for some odd cases on input so kh29 is the one to use. And just for reference I use onMetadata event which works well.

karl.

JW Player

User  
0 rated :

AAC+ working and running on www.ned.fm

<div id="metadata">
<p> <!-- Now Playing shows up here --> </p>
</div>

<script type="text/javascript" src="http://www.fastserv.com/player/player.js"></script>
<div id="player"><a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to hear this stream.</div>
<script type="text/javascript">
// SET THE FOLLOWING VARIABLES ACCORDING TO YOUR STREAM
var stream = 'http://209.9.238.123:80/dreadlockradio_aacp';
var autostart = 'true';
// DO NOT EDIT ANYTHING BELOW THIS POINT
var so = new SWFObject('http://www.fastserv.com/player/player.swf','mpl','470','20','9');
so.addParam('allowscriptaccess','always');
so.addParam('allowfullscreen','false');
so.addVariable('autostart', autostart);
so.addVariable('file', stream+'%3Ftype%3D.flv');
so.write('player');
</script>

JW Player

User  
0 rated :

Just a heads up NED.

The memory leak issues with flash appear to still be present if you upgrade to JW Player 5.x. I had to upgrade. It seems JW Palyer doesn't recognize the wrapper, needs additional params, or KH-Icecast needs to me modified?

Ethan Feldman

JW Player Support Agent  
0 rated :

This is more of a flash memory leak that specifically related to the JW Player.

JW Player

User  
0 rated :

Hello, i have compiled icecast kh30 and got icecast server started but no audio on jw player, any idea? i have test the fastserv code, but nothing

JW Player

User  
0 rated :

Now is working! if you need help can contact me
dnlx[@] live.com

in kh 30 when access to admin are show the source code...

Ethan Feldman

JW Player Support Agent  
0 rated :

How did you get it working?

JW Player

User  
0 rated :

Using icecast kh servers.
Onlye work with jwplayer *4.x* version

anyone has been able to make it work with version 5?

Ethan Feldman

JW Player Support Agent  
0 rated :

We don’t officially support it…can you show a link to where it is working at all?

JW Player

User  
0 rated :

sent my your email
dnlx[@]hotmail.com

JW Player

User  
0 rated :

the code is the same posted by NED fm on Fri, 2011-02-25 19:47

Ethan Feldman

JW Player Support Agent  
0 rated :

http://www.longtailvideo.com/support/contact-us,thanks

JW Player

User  
0 rated :

form sent..
thanks

Ethan Feldman

JW Player Support Agent  
0 rated :

And replied.

JW Player

User  
0 rated :

thanks

Ethan Feldman

JW Player Support Agent  
0 rated :

Np

JW Player

User  
0 rated :

Sir how to bypass icecast 2 authentication in jw player 8? any idea?

Ethan Feldman

JW Player Support Agent  
0 rated :

No idea. JW Player 8 doesn’t even exist yet.

JW Player

User  
0 rated :

Any idea why the icecast2 kh trick only work in jwplayer4.x?

I work well on jwplayer 4.x but refuse to work on jwplayer 5.x and I do have a skin for jwplayer 5.x so would prefer to use the latest player.

Ethan Feldman

JW Player Support Agent  
0 rated :

No idea. We never officially supported it.

JW Player

User  
0 rated :

It's sad as you would be the first know flash player to get aac+ streaming without using RTMP server.

Using icecast kh is really cost effective.

JW Player

User  
0 rated :

last time I tried it, v4 worked without the duration but v5 required it, just state a very large value (this was around 5.3 iirc). provider may of needed to be set as well eg video. I'll check tomorrow with the latest update

karl.

Ethan Feldman

JW Player Support Agent  
0 rated :

Sorry, we just never supported it officially…

JW Player

User  
0 rated :

I've just tried it here using the mediaplayer-5.8 tree inside the icecast webroot I then copied the readme slightly modified to refer to the stream on icecast and the args such as

file=/stream%3Ftype%3D.flv&provider=video&duration=9999999

and it plays in my firefox. This is an mp3 stream here but an aac stream should work in the exactly same way. You may need the crossdomain.xml if the web page is not from icecast

so as far as I can tell it's working as it did before.

karl.

Ethan Feldman

JW Player Support Agent  
0 rated :

Cool, glad you got it working.

JW Player

User  
0 rated :

I am trying to use http://www.fastserv.com/kb/article/icecast_embedded_flash_player/

I run a Linux mpriki 2.6.26-2-686 #1 SMP Mon Jun 21 05:58:44 UTC 2010 i686 GNU/Linux (lenny distribution)

I don't know linux commands!!
I install icecast2 following these: http://www.howtoforge.com/linux_webradio_with_icecast2_ices2 instructions...
Any help?
My mail is el07694@mail.ntua.gr
Thx in advance

Ethan Feldman

JW Player Support Agent  
0 rated :

We don’t officially support ShoutCast…

JW Player

User  
0 rated :

Hi Ethan,

bc.. We don't officially support ShoutCast...


I see this a lot. Why is that given that we, the uninitiated, are constantly given the choice between shoutcast - what most of the world uses - and Icecast - what most of the rest of the world uses - for audio streaming, and yet you don't apparently "support" either?

Can you give us some background on this and please be clear about whether this is a company policy or a technical imposition. If longtail prioritizes video and audio is further down the list, let us know. The streaming audio realm has a LOT of bad information, poorly written documentation, seemingly arbitrary and conflicting authoritative opinion and WAY too many self styled experts. This is not a, uh, good thing.

Thanks

Ethan Feldman

JW Player Support Agent  
0 rated :

ShoutCast itself has huge memory leak issues in Flash. We tried supporting it in the past, but there are so many different flavors of it that it makes it impossible to support them all, in addition to it adding memory leak issues to the player. It might work, it might not, you can try it, but we still don’t officially support it because ShoutCast support is very hit or miss (usually miss).

JW Player

User  
0 rated :

I think that was true in 2009 ;)

My buddies and I have been running shoutcast players for a couple years now without those problems.

The reasons that it does or does not work are very specific, and its about time JWPlayer actually looked into it hehehe

If you need AAC support, look into Thunder Snow.

http://code.google.com/p/project-thunder-snow/

Here is a demo AACplus player that will never leak memory, and plays direct from icecast without a problem.

http://thundersnow.thebitstream.com/NBaac.html

Get with the times guys... there are solutions. hehehe



Have Fun!

Ethan Feldman

JW Player Support Agent  
0 rated :

Thanks, I will pass these to Jeroen.

JeroenW

JW Player Support Agent  
0 rated :

We don’t support Shoutcast, since it is not officially supported by Adobe Flash. It may work in the player, but we have no control over it.

For audio streaming, we suggest using Adobe RTMP streaming (note a Wowza server can re-broadcast Shoutcast to RTMP). Streaming of MP3 or AAC livestreams over RTMP is supported by Wowza and Flash Media Server, implemented by our engineers and tested by our support team.

JW Player

User  
0 rated :

All of that is false info.

Jereon, you first contacted me in August 2008, asking how to stream aacplus to flash player, and if you could add it to JWPlayer. You saw me writing about it on the red5 mailing list.

Well, here it is. flash player DOES play shoutcast and icecast with aac and without memory problems.

see here: AAC and no leaks! http://thundersnow.thebitstream.com/NBaac.html and its not using any special build of icecast.



Adobe doesnt support playing shoutcast with a 'Sound' Object, however they are improving their 'Sound' object api.

They do support playing shoutcast with url stream. They do support playing aacplus in shoutcast/icecast.

Wowza and FMS is no longer required to re-stream aacplus, and being paid solutions, it's be nice to mention the free solution, red5, which also does the same. Also, red5 is the only one that can also play shoutcast TV.

Pushing people into a paid solution when there is a free one or where one is not needed?

Come on guys.

JeroenW

JW Player Support Agent  
0 rated :

Again, you’re free to play these streams with JW Player, but we don’t test or officially support it. Have you looked into adding the ThunderSnow library into a provider for JW Player, similar to what we have for e.g. Apple HLS? That way, you can use JW Player for playback, but have control over the AAC decoding through your provider (which is an externally loaded SWF).

JW Player

User  
0 rated :

Hi!

How should I setup jwplayer for an AAC+ stream?

I managed to play an AAC stream using the simplest configuration but having the stream name ended in .aac.

For AAC+ I tried the extensions mp4, m4a but it won't play.

Would it change smthg if I would use an rtmp server?

From the site of the thundersnow player I didn't figure it out how to use it. :(

Any help?

Andy S, do you have a solution for aac+ streaming? The most simple.

I listem to radio stations which use aac+ and a flash player...so it's possible for sure.

Alexandru

JW Player

User  
0 rated :

Hi, i have same question like Alexandru, I have Centova cast with installed Shoutcast and IceCast v2 so i'm interested in FLASH player that can be installed on this platform and that plays AAC+. Any solutions?

Ethan Feldman

JW Player Support Agent  
0 rated :

Do you have a sample stream?

This question has received the maximum number of answers.