Wowza Community

Combine several cupertino packetized streams in a single .m3u8 for multi-bitrate

We have a Wowza server that does not have Transcoder AddOn enabled, and as a consequence we have to stream several local bitrates in order to enable multi-bitrate in a player:

Now, to actually enable multi-bitrate, I need not three .m3u8 files:

http://hls0.60001-live0.dna.qbrick.com/60001-live0/lego_low/playlist.m3u8
http://hls0.60001-live0.dna.qbrick.com/60001-live0/lego_medium/playlist.m3u8
http://hls0.60001-live0.dna.qbrick.com/60001-live0/lego_high/playlist.m3u8

I need a a single one referring to the three streams. I suppose I have to create my own .m3u8 file, but how?

#EXTM3U
#EXT-X-VERSION:3
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=2691072,CODECS="avc1.77.31,mp4a.40.2",RESOLUTION=1280x720
[COLOR="#FF0000"]how do I refer to high bitrate stream?[/COLOR]
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=1155072,CODECS="avc1.77.31,mp4a.40.2",RESOLUTION=832x468
[COLOR="#FF0000"]how do I refer to medium bitrate stream?[/COLOR]
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=448512,CODECS="avc1.66.30,mp4a.40.2",RESOLUTION=640x360
[COLOR="#FF0000"]how do I refer to low bitrate stream?[/COLOR]

I have already created a .smil file that enables JWPlayer to do multi-bitrate on the RTMP streams:

<smil>
	<head>
		<meta base="rtmp://flash0.60001-live0.dna.qbrick.com/60001-live0/_definst_" />
	</head>
	<body>
		<switch>
			<video src="mp4:lego_high" system-bitrate="2691072" width="1280" height="720"/>
			<video src="mp4:lego_medium" system-bitrate="1155072" width="832" height="468"/>
			<video src="mp4:lego_low" system-bitrate="448512" width="640" height="360"/>
		</switch>
	</body>
</smil>

Hello,

All you need is to use the .smil file you have already created. Let’s say your smil file is named lego.smil, you will have to use it like this:

http://flash0.60001-live0.dna.qbrick.com/60001-live0/_definst_/smil:lego.smil/playlist.m3u8

The iOS player should get the playlist.m3u8 file containing all the different bitrate streams. Then, depending on the available bandwidth at the client side, the player will settle on the most appropriate stream.

Zoarn

Hi,

Yes, the .smil file has to be placed in the Wowza content folder.

You could enable the MediaCache addon for your Wowza server. Your .smil file can be placed on a remote webserver, and have the MediaCache addon retrieve the content file from that location.

You can request the MediaCache addon by following the instructins from this URL: https://www.wowza.com/docs/how-to-scale-video-on-demand-streaming-with-media-cache

The instructions on how to install and configure it are available within the addon package.

Zoran

Zoran, in your example code above, I’m assuming that lego.smil is placed in the [install-dir]/content folder as suggested in How to set up live streaming using an RTMP-based encoder: Adaptive bitrate streaming

Using a text editor, create a SMIL file … in the [install-dir]/content folder

I do no not have access to actually uploading files to this Wowza server.

Can I put the .smil file in another location and append the /playlist.m3u8 relative to the .smil location? Or do the .smil file have to be in [install-dir]/content?

If I can’t put the .smil on the Wowza server, how then do I go about this?