Streamalot: Streaming
Media Tips, Tricks, and Hints
Wowza Tips & Tricks
Using JW Player
Below are the instructions for using JW Player with Wowza Pro. For this example you are going to setup an application named streamingvideo to stream pre-recorded video content from the folder c:\movies.
Instructions:
Create the folder c:\movies and copy your .flv content into this folder
Create the folder [install-dir]/applications/streamingvideo
Create the folder [install-dir]/conf/streamingvideo
Copy [install-dir]/conf/Application.xml into [install-dir]/conf/streamingvideo
Edit the newly copied Application.xml and make the following changes:
Set Streams/StorageDir to c:/movies
Uncomment the <Module> definition for the module named flvplayback
Code:
<Module>
<Name>flvplayback</Name>
<Description>FLVPlayback</Description>
<Class>com.wowza.wms.module.ModuleFLVPlayback</Class>
</Module>Download the JW Player and unzip
Edit the flvplayer.html file in the JW Player root directory and make the following changes (starting line 18):
To (add id variable and change file variable to rtmp url):
s1.addParam("allowfullscreen","true");
s1.addVariable("file","rtmp://[server-ip-address]/streamingvideo"); // <-- change to rtmp url
s1.addVariable("id","mycoolvideo"); // <-- add id variable and set to flv filename (minus .flv extension)
s1.addVariable("image","preview.jpg");
s1.addVariable("width","300");
s1.addVariable("height","170");
s1.write("player1");
where:
[server-ip-address] is the ip address of your server or local host if running on the same machine as the Wowza Pro server
streamingvideo is the name of the application you setup
mycoolvideo is the name of the your .flv media content that you copied into the c:\movies folder
Open flvplayer.html in a web browser
It may not work due to a security restriction in Flash. If it does not play do the following:
Right click on the flash movie below the title single file, with preview image and select Settings... from the popup menu.
Click the Advance... button and it will pop open a browser window.
Click the Global Security Settings Panel link.
A new web page will open with a flash swf file in the top right corner.
In this flash movie select Add location... from the Edit locations... popup.
Select Browse for files... and select the flvplayer.swf that is in the same folder with the flvplayer.html file and click Open
Close all web browsers and try opening the flvplayer.html file again. It should work.
Note: This problem can be avoided by hosting the files flvplayer.html, flvplayer.swf, swfobject.js and preview.jpg on your web server.
[install-dir]
Windows (default): C:\Program Files\Wowza Media Systems\Wowza Media Server Pro
Mac OS X: /Library/WowzaMediaServerPro
Linux: /usr/local/WowzaMediaServerPro
If you have an idea for a Tutorial, would like to contribute, or
are just interested in being notified of an update, please Contact Us.