Wowza Community

live streaming with jw player

Hello!

I’m havnig trouble with jw player and my live stream though wowza.

Using this tutorial http://www.wowza.com/forums/showthread.php?p=5020 i got video and audio thru wowza test flash player (using Broadcast over TCP in Broadcaster). Trying to connect jw player and wowza using manual http://www.wowza.com/community/t/-/33 i don’t see anything.

Where i should put this code:

i put it in readme file of jw player around line 24 (before existing line script type=“text/javascript”… when i push play i got message Video not found: video.flv

jw player version - 4.4.198

Please, help to resolve my problem.

Thanks in advance

The stream name (file in JW) is wrong:

<script type="text/javascript">
var s1 = new SWFObject("player.swf","ply","328","200","9","#FFF FFF");
s1.addParam("allowfullscreen","true");
s1.addParam("allowscriptaccess","always");
s1.addParam("flashvars","fullscreen=true&bufferlength=2&streamer=rtmp://[server-ip-address]/live&file=myStream.sdp");
s1.write("container");
</script>

Obviously you need to change [server-ip-address] to the ip address of the srever running Wowza Pro.

Charlie

I had the same issue today. It seems like live playback is broken in the current version of JW Player. I am also having problems with video on demand playback as well (stutters for 2 seconds at the start). I suggest installing JW Player 4.x for now until it gets resolved:

http://www.wowza.com/community/t/-/33

I have sent a message to the JW Player folks to make sure we get this resolved quickly.

Charlie

As mentioned, if you are getting “video not found”, this indicates the problem is the “file” Flashvar, which you have set to “myStream.sdp”. Is there a file named “myStream.sdp” in your content folder?

Note the upper case “S”

Richard

As noted by rrlanham, you need to specify .sdp (session description protocol) for Live streams, instead of .flv; Note that the .sdp “file” never really exists as an actual file - it’s a placeholder to ensure the server understands this is a live stream, and not a file of the same name.

I found (today) with some awkward debugging, the same issue with slightly different embed code. The problem was present when using JW plyer 4.4.198 (newest) rather than a previously tested 4.1.60, and gave ‘Stream Not Found’ with otherwise just right URLs.

Also in your streamer : this application name is similar to a directory path, and should end in a slash (see code example below) or again, you’ll get Stream Not Found, as the request made to wowza seen in the log files, is incorrcet and you’d see " Application folder ([install-location]/applications/) is missing" in the logs.

Here’s the test code I was using - YMMV - but if all else fails, try with earlier JW player to ensure you’ve not ‘crossed the beams’ !

sFileName = ‘test.sdp’;

sContainer = ‘preview’;

function showLoader(sFileName, sContainer) {

var flashvars = {

file: sFileName,

streamer: “rtmp://ec2.xxx.xxx.xxx/event/”,

type: “video”,

bufferlength: “0.5”,

repeat: “none”,

playlist: “none”,

autostart: “false”,

fullscreen: “true”,

volume: “100”,

quality: “true”,

stretching: “none”

};

var params = { };

var attributes = { };

// NS : The syntax above was developed for JW player 4.1.60, but shows ‘stream not found’ for JM player player-4.4.198.swf

// You will need to re-check the JW player site to find out what’s changed for later player versions which causes this

// DO NOT DEPLOY 4.4.198. to customers until this is resolved.

swfobject.embedSWF(“flash/player-4.1.60.swf”, sContainer, “273”, “223”, “9”, “/flash/expressInstall.swf”, flashvars, params, attributes);

} // End function showLoader

NS : Correction - After more investigations, the change of behaviour was pinned down to the ‘type:’ value above. If it’s specified as ‘video’ this works OK in 4.1.60; For 4…4.198, the value MUST read type = “rtmp” for live video from a Wowza or Flash streaming server.

HTH - Cheers, Neil

FYI, I was able to play live stream from WOWZA in the latest JW Player (v4.4) with the codes below.

<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
	swfobject.registerObject("player","9.0.98","expressInstall.swf");
</script>
<object id="player" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" name="player" width="480" height="360">
	<param name="movie" value="player.swf" />
	<param name="allowfullscreen" value="true" />
	<param name="allowscriptaccess" value="always" />
	<param name="flashvars" value="fullscreen=true&bufferlength=0.5&streamer=rtmp://[SERVER-IP]/rtplive&file=mystream.flv" />
</object>

Thanks,

Bruce

I used the basic code and I had modified the string in second part of the script with live streaming settings. It works fine. I’m testing for the autostart function…

<script type="text/javascript"> 
var s1 = new SWFObject("player.swf","ply","328","200","9","#FFFFFF"); 
s1.addParam("allowfullscreen","true"); 
s1.addParam("allowscriptaccess","always"); 
s1.addParam("flashvars","fullscreen=true&bufferlength=2&streamer=rtmp://<serverIP>/<wowza_app>&file=live.sdp"); 
s1.write("container"); 
</script> 
<script type="text/javascript" src="swfobject.js"></script> 
<script type="text/javascript"> 
swfobject.registerObject("player","9.0.98","expressInstall.swf"); 
</script> 
<object id="player" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" name="player" width="328" height="200"> 
<param name="movie" value="player-viral.swf" /> 
<param name="allowfullscreen" value="true" /> 
<param name="allowscriptaccess" value="always" /> 
<param name="flashvars" value="fullscreen=true&bufferlength=2&streamer=rtmp://<serverIP>/<wowza_app>&file=live.sdp" /> 
<object type="application/x-shockwave-flash" data="player-viral.swf" width="328" height="200"> 
<param name="movie" value="player-viral.swf" /> 
<param name="allowfullscreen" value="true" /> 
<param name="allowscriptaccess" value="always" /> 
<param name="flashvars" value="fullscreen=true&bufferlength=2&streamer=rtmp://<serverIP>/<wowza_app>&file=live.sdp" /> 
Get" target="_blank">http://get.adobe.com/flashplayer">Get Flash to see this player.
</object> 
</object>

No, there i put ip of my server :slight_smile: for security reasons i put default configuration

anybody help :confused:

Hey everyone, I am trying to get JW PLAYER 5 working w/ Wowza 2

I have the following:

I also tried streamer=rtmp://192.168.1.185:1935/live/

What happens is I only get an image of the stream and the loading icon continues. The stream works perfect with wowza livestream example.