1 Reply Latest reply on Dec 8, 2011 7:53 PM by TheRossman

    NetStreamSwitchManager: Stuttering video when switching bitrates

    manuel2005

      I'm creating a DynamicStreamingResource and adding four DynamicStreamingItem elements to the resource's streamItems array. When I play the video, however, it keeps on stuttering, and I see in the logs that OSMF is constantly trying to switch renditions. If I only add one DynamicStreamingItem to the array, the video plays without a problem. If I only add the top three renditions (1200, 800 and 600), it also plays fine and switches normally, without hiccups. It's when add the lower rendition (300) that the hiccups start. Any insight will be greatly appreciated. Below is a snipet of the log:

       

      Thu Sep 29 2011 04:09:20 PM [DEBUG] [org.osmf.net.NetStreamSwitchManager] 16:09:20 GMT-0400>>> NetStreamSwitchManager.onNetStatus() - event.info.code=NetStream.Buffer.Empty

      Thu Sep 29 2011 04:09:20 PM [INFO] [org.osmf.net.NetLoader] Stream reconnect: onNetStatus: NetStream.Buffer.Empty

      Thu Sep 29 2011 04:09:20 PM [DEBUG] [org.osmf.net.NetLoader] Stream reconnect: buffer empty, netConnection.connected=true

      Thu Sep 29 2011 04:09:20 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] getNewIndex() - about to return: 0, detail=Buffer was empty

      Thu Sep 29 2011 04:09:20 PM [INFO] [org.osmf.net.NetStreamLoadTrait] NetStream.Pause.Notify

      Thu Sep 29 2011 04:09:20 PM [DEBUG] [org.osmf.net.NetStreamSwitchManager] 16:09:20 GMT-0400>>> NetStreamSwitchManager.onNetStatus() - event.info.code=NetStream.Pause.Notify

      Thu Sep 29 2011 04:09:20 PM [INFO] [org.osmf.net.NetLoader] Stream reconnect: onNetStatus: NetStream.Pause.Notify

      Thu Sep 29 2011 04:09:20 PM [INFO] [org.osmf.net.NetStreamLoadTrait] NetStream.Buffer.Flush

      Thu Sep 29 2011 04:09:20 PM [DEBUG] [org.osmf.net.NetStreamSwitchManager] 16:09:20 GMT-0400>>> NetStreamSwitchManager.onNetStatus() - event.info.code=NetStream.Buffer.Flush

      Thu Sep 29 2011 04:09:20 PM [INFO] [org.osmf.net.NetLoader] Stream reconnect: onNetStatus: NetStream.Buffer.Flush

      Thu Sep 29 2011 04:09:21 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] Move up since avg dropped FPS 2 < 2 and bufferLength > 0.3

      Thu Sep 29 2011 04:09:21 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] getNewIndex() - about to return: 3, detail=null

      Thu Sep 29 2011 04:09:21 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] getNewIndex() - about to return: 0, detail=Buffer was empty

      Thu Sep 29 2011 04:09:21 PM [INFO] [org.osmf.net.NetStreamLoadTrait] NetStream.Buffer.Full

      Thu Sep 29 2011 04:09:21 PM [DEBUG] [org.osmf.net.NetStreamSwitchManager] 16:09:21 GMT-0400>>> NetStreamSwitchManager.onNetStatus() - event.info.code=NetStream.Buffer.Full

      Thu Sep 29 2011 04:09:21 PM [INFO] [org.osmf.net.NetLoader] Stream reconnect: onNetStatus: NetStream.Buffer.Full

      Thu Sep 29 2011 04:09:21 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] Buffer of 1 < 2 seconds

      Thu Sep 29 2011 04:09:21 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] getNewIndex() - about to return: 0, detail=Buffer was empty

      Thu Sep 29 2011 04:09:22 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] Buffer of 1 < 2 seconds

      Thu Sep 29 2011 04:09:22 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] getNewIndex() - about to return: 0, detail=Buffer was empty

      Thu Sep 29 2011 04:09:22 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] Move up since avg dropped FPS 0 < 2 and bufferLength > 0.3

      Thu Sep 29 2011 04:09:22 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] getNewIndex() - about to return: 3, detail=null

      Thu Sep 29 2011 04:09:22 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] Buffer of 1 < 2 seconds

      Thu Sep 29 2011 04:09:22 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] getNewIndex() - about to return: 0, detail=Buffer was empty

      Thu Sep 29 2011 04:09:23 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] Move up since avg dropped FPS 0 < 2 and bufferLength > 0.3

      Thu Sep 29 2011 04:09:23 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] getNewIndex() - about to return: 3, detail=null

      Thu Sep 29 2011 04:09:23 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] Buffer of 1 < 2 seconds

      Thu Sep 29 2011 04:09:23 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] getNewIndex() - about to return: 0, detail=Buffer was empty

      Thu Sep 29 2011 04:09:23 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] Move up since avg dropped FPS 0 < 2 and bufferLength > 0.3

      Thu Sep 29 2011 04:09:23 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] getNewIndex() - about to return: 3, detail=null

      Thu Sep 29 2011 04:09:23 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] Buffer of 2 < 2 seconds

      Thu Sep 29 2011 04:09:23 PM [DEBUG] [org.osmf.net.rtmpstreaming.InsufficientBufferRule] getNewIndex() - about to return: 0, detail=Buffer was empty

      Thu Sep 29 2011 04:09:24 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] Move up since avg dropped FPS 0 < 2 and bufferLength > 0.3

      Thu Sep 29 2011 04:09:24 PM [DEBUG] [org.osmf.net.rtmpstreaming.SufficientBandwidthRule] getNewIndex() - about to return: 3, detail=null

      Thu Sep 29 2011 04:09:24 PM [DEBUG] [org.osmf.net.NetStreamSwitchManager] 16:09:24 GMT-0400>>> NetStreamSwitchManager.checkRules() - Calling for switch to 3 at 339 kbps

      Thu Sep 29 2011 04:09:24 PM [DEBUG] [org.osmf.net.NetStreamSwitchManager] 16:09:24 GMT-0400>>> NetStreamSwitchManager.executeSwitch() - Switching to index 3 at 339 kbps