Wowza Community

Unable to play f4m with smil in OSMF properly

Hello,

We are trying to implement multiple bitrate switching using f4m/smil. We have the latest Wowza 2 installed with patch7.

Contents of our test.smil file:

<smil xmlns="http://www.w3.org/2001/SMIL20/Language">
	<head>
        </head>
	<body>
		<switch>
			<video src="mp4:vdtv2" system-bitrate="49552" width="480" height="360"/>
			<video src="mp4:vtv_1" system-bitrate="970752" width="640" height="480"/>
                </switch>
	</body>
</smil>

Contents of our f4m generated using test.smil file are available here

When we play the f4m url in OSMF (1.6) player, the multiple bitrate switching does not work, always only one stream is being played.

We tried playing a sample f4m file from here and multiple bitrate switching worked like a charm in OSMF 1.6.

After that we compared the f4m created by Wowza and sample f4m and saw that Wowza has lost width and height from the smil, which could lead to this problem.

Is there any way to tell Wowza to create the f4m file based on smil file and not loose width and height properties defined in smil file? I have spent some time looking through Wowza forums, and did not find anyone reporting this problem, so perhaps the cause is in my smil structure?

Try applying patch 12, it should be fixed:

https://www.wowza.com/docs/wowza-streaming-engine-software-updates

Richard

Unfortunately we still have an infrastructure of Wowza 2 servers, that will take some time to migrate. And this patch is only for Wowza 3:(

By the way can you tell me how long Wowza 2 will be supported by releasing some critical new patches?

I just tried installing Wowza 3 and see if it would solve the problem. It did not. The manifest.f4v does not contain width and height. It looks like this:

<manifest xmlns="http://ns.adobe.com/f4m/1.0">
<id>test.smil</id>
<mimeType>video/mp4</mimeType>
<streamType>recorded</streamType>
<deliveryType>streaming</deliveryType>
<media streamId="1" bootstrapInfoId="bootstrap0" bitrate="48" url="media_b49552_w1370823808.abst/"></media>
<media streamId="2" bootstrapInfoId="bootstrap0" bitrate="948" url="media_b970752_w1370823808.abst/"></media>
</manifest>

Hence, the problem is not in Wowza version or patch applied, but somewhere else, can anyone help me?

As an alternative, would it be possible to manually create a manifest.f4v, host it on a different server and use for live streaming with multiple bitrate switching?

Hello, randall,

Yes, the bitrate was wrong. It has been corrected now and smil file updated to:

<smil xmlns="http://www.w3.org/2001/SMIL20/Language">
	<head>
        </head>
	<body>
		<switch>
			<video src="mp4:vtv_1" system-bitrate="970752" width="640" height="480"/>
			<video src="mp4:vdtv2" system-bitrate="495520" width="480" height="360"/>
                </switch>
	</body>
</smil>

Also the respective f4m was automatically updated and is available here (this is via Wowza 2)

However, it did not solve the problem.

Also I applied the patch12 to Wowza 3 and got a similar result with no width or height properties:

<manifest xmlns="http://ns.adobe.com/f4m/1.0">
<id>test.smil</id>
<mimeType>video/mp4</mimeType>
<streamType>recorded</streamType>
<deliveryType>streaming</deliveryType>
<media streamId="1" bootstrapInfoId="bootstrap0" bitrate="948" url="media_b970752_w2000321709.abst/"></media>
<media streamId="2" bootstrapInfoId="bootstrap0" bitrate="483" url="media_b495520_w2000321709.abst/"></media>
</manifest>

Yes, always only one stream is being played - vdtv2, even if I change the sequence of the streams. Only when I remove vdtv2 from the smil, the other stream gets played.

Im playing this URL with OSMF player (available Wowza%20Media%20Server%203.0.3/examples/SimpleVideoStreaming/clientOSMF/bin-release/SimpleOSMFPlayer.html)

Im have basically put two completely dfferent streams in one smil to see when the switching happens, but it never does. I also saw that switching works just fine with sample f4m from internet available here. I noticed that the difference between my f4m produced by Wowza using smil and the sample f4m is missing width and height properties. Perhaps this is the cause of the problem and now Im looking to solve it.

Also as an alternative I could manually put together a manifest.f4m and host it on a different server, could this possibly work for livestreaming?

Yes, the streams are completely different so that I can notice when the switching happens.

Im trying to achieve multiple bitrate switching and NOT adaptive bitrate at this point. Are you saying that Wowza checks the keyframes and if they are not aligned, produces bad manifest.f4v (with no width and height properties) ?

Thanks, my fault was that I did testing with 2 completely different streams and they were not keyframe aligned. With keyframe aligned streams everything works fine.

However, Wowza is still loosing width property defined in smil, which could be useful for me to display 360p or 720p indication on flash player (the funny thing that Wowza does not loose it for iPhone playlist file which is also based on the same smil file).

Hi dundurs,

I’m just going to ask some basic questions here to try to narrow down the problem.

“always only one stream is being played”

Which stream? Exactly what URL are you playing? With what player? You installed WM3, but did you apply the patch? What is your WMS version reported in the logs?

Is a bitrate of 48kbps correct? It doesn’t seem sufficient to play a video. Can you describe your setup in more detail? Thanks.

I was able to play your individual streams via RTMP in the OSMF player: rtmp://live10.tiesraides.lv/live/vdtv2

I notice that “vdtv2” frequently pauses. This would point to a bandwidth limitation. Ensure that you have sufficient bandwidth between your encoder and your Wowza server.

But that is another issue. I see that the two streams are completely different. (Different channels?) So, it is likely they are not keyframe aligned. So, this will not work.

From the tutorials: “Adaptive Bitrate (ABR) live streaming to Flash, Apple iOS devices and Silverlight requires that you have an encoder that can generate multiple bitrate streams from the same source that are properly key-frame aligned. Once have you an encoder that can generate properly aligned streams then you need to create a Synchronized Multimedia Integration Language (SMIL) file that links the streams together for playback.”

Let me try to understand. Can you explain the difference between multiple bitrate switching and adaptive bitrate?

“Are you saying that Wowza checks the keyframes and if they are not aligned, produces bad manifest.f4v (with no width and height properties)?”

No, I’m saying that the width/height properties don’t matter to the players, which are concerned with the bitrate. Also, the players will not be able to switch streams in the .smil if they are not from the same source and keyframe aligned.

Fixes/patches are being developed for the Wowza Media Sever 3 version.

-Lisa