Skip navigation
Currently Being Moderated

maxAllowedDynamicStreamIndex not used by NetStreamSwitchManager

Mar 16, 2012 1:20 PM

Tags: #mediaplayer #dynamic_switching



I'm using OSMF 1.5 and am trying to limit set the maxAllowedDynamicStreamIndex.  I'm setting it in a listener when a DynamicStream capability is added:


               private function onCapabilityChange(event:MediaPlayerCapabilityChangeEvent):void
                    trace("onCapabilityChange(): type=" + event.type + " enabled=" + event.enabled);
                    if ((event.type == MediaPlayerCapabilityChangeEvent.IS_DYNAMIC_STREAM_CHANGE) && (event.enabled)) {
                         mediaPlayer.maxAllowedDynamicStreamIndex = asset.getMaxStreamIndexForDimensions(mediaHolder.width,mediaHolder.height);
                         trace("max stream index set to:" + asset.getMaxStreamIndexForDimensions(mediaHolder.width,mediaHolder.height));


After noticing that the MediaPlayer continued to exceed the maxAllowedIndex when running its switching rules (checking for bandwidth , buffer etc).  I managed to sniff my way into the NetStreamSwitchManger which seems to completely ignore the setting that is made in the mediaPlayer and DynamicStreamTrait and instead it simply uses the number of streams defined in the DynamicStreamingResource.


I've seen a few posts that seem to imply that this should just simply work - but after looking at the code in OSMF 1.5 I can't see how.


Am I missing something?  Is this fixed in OSMF 1.6?

  • Currently Being Moderated
    Mar 19, 2012 4:07 AM   in reply to griley64

    Can you check the stream in Strobe media playback? it allows you to give the value as a flashvare, ex:

    .../debug.html?maxAllowedDynamicStreamIndex=2&optimizeInitialIndex=fal se

    Mark as:
  • Currently Being Moderated
    Mar 19, 2012 9:18 AM   in reply to griley64



    SMP is included in the OSMF sources. The line I provided turns off the initial optimization for switching, so it should be OSMF-only behavior.


    Regarding the plugin, it could cause different behavior - have you talked with Akamai?

    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points