For the example you can download these 3 versions of bigbuckbunny and put them in the Wowza content folder:
http://www.wowzamedia.com/_h264/bigbuckbunny_450.mp4
http://www.wowzamedia.com/_h264/bigbuckbunny_750.mp4
http://www.wowzamedia.com/_h264/bigbuckbunny_1100.mp4
Each item must be key frame aligned for switching to work (at present). For encoding suggestions to achieve this, see this article.
Make sure the Stream Class Scheduler is setup
- Get the Module Collection jar,
- Add the ServerListener to /conf/Server.xml, then restart Wowza.
Code:<ServerListener> <BaseClass>com.wowza.wms.plugin.collection.serverlistener.ServerListenerStreamPublisher</BaseClass> </ServerListener>
- Create the streamschedule.smil file in the /content folder:
Code:<smil> <head> </head> <body> <stream name="Stream1"></stream> <stream name="Stream2"></stream> <stream name="Stream3"></stream> <playlist name="pl1" playOnStream="Stream1" repeat="true" scheduled="2009-12-11 16:26:00"> <video src="mp4:bigbuckbunny_450.mp4" start="0" length="-1"/> </playlist> <playlist name="pl2" playOnStream="Stream2" repeat="true" scheduled="2009-12-11 16:26:00"> <video src="mp4:bigbuckbunny_750.mp4" start="0" length="-1"/> </playlist> <playlist name="pl3" playOnStream="Stream3" repeat="true" scheduled="2009-12-11 16:26:00"> <video src="mp4:bigbuckbunny_1100.mp4" start="0" length="-1"/> </playlist> </body> </smil> - Then create the switching smil file also in the content folder, name it "switch.smil"
Code:<smil> <head> </head> <body> <switch> <video src="Stream1" system-bitrate="450000"/> <video src="Stream2" system-bitrate="750000"/> <video src="Stream3" system-bitrate="1100000"/> </switch> </body> </smil>
- Restart Wowza to load the Scheduler.
Playback in iOS:
Code:
http://[wowza-address]:1935/live/smil:switch.smil/playlist.m3u8
Code:
http://[wowza-address]:1935/live/smil:switch.smil/Manifest
Code:
http://[wowza-address]:1935/live/smil:switch.smil/manifest.f4m


Article List
Categories
Wowza Media