SSME (Smooth Streaming Media Element) config.xml review (Smooth Streaming Client configuration file) RSS

5 replies

Last post Mar 25, 2014 04:45 PM by rceles1982

  • SSME (Smooth Streaming Media Element) config.xml review (Smooth Streaming Client configuration fi...

    Oct 07, 2010 08:35 AM|SGamzu|LINK

    SSME has this little "configPath" property that is a path to an XML file containing some impressive number of configuration nodes.

    If it is not set SSME tries to call "config.xml" from its root directory.

    I could not find any documentation on this topic but it seams to be really powerful tool for SSME heuristics' configuration.

    The only place I could find info on one of the config parameters was the Ezequiel Jadib’s Blog:

    http://blogs.southworks.net/ejadib/category/smooth-streaming-media-element/

    that explains how to configure exact seek on SSME, i.e. a way to seek to exact frame in media and not only closest keyframe.

    Except this blog, no other information could be found yet as far  as I concern

    So it leaves no choice to the developer that want to use SSME as to investigate it himself.

    It sound kind of interesting also. So I post below this XML file with my coments while the level of each comment investigation reliability would be marked as followed:

    (H) for HIGH reliability.  Sure enough and tested by me.

    (M) for MEDIUM reliability. Not sure enough, needs more testing, hard to test.

    (L) for LOW reliability. Only guessing or not tested directly

    I should say that SSME heuristics are really complicated as you will see from the XML, so testing its components is not the easiest thing.
    I'm waiting for a lot of inaccuracy places that you guys would find in my research.
    Please feel free to notify me on those so I can retest and fix the post if needed or change the specific parameter reliability.
    This is the real goal of this thread as I see it untill microsoft would release official docs on this.

    NOTE! you must remove all the comments before using the below XML configuration file, because XML does not support comments inside a tag

    <?xml version="1.0" encoding="utf-8" ?>
    <LiveSmoothStreamingSettings>
      <BufferingEngineSettings
                       

                        //(H) Allows seek between keyframes,
                        //i.e. to exact frame 
                        //(Originaly posted by Ezequiel Jadib in his Blog)
            ForceAccurateSeeks="true"  
      
            LiveBackOffTimeIncrementMilliseconds = "250"
            LiveBackOffTimeMilliseconds = "250"
            LiveBufferTimeMilliseconds = "7000"
      
                            //(H) try downloading the same chunk 
                            //until this number of 404 chunks is achieved
            Max404ErrorsPerChunk = "2"
      
                             //(L) try downloading the same chunk
                             // until this number of 412 chunks is achieved
            Max412ErrorsPerChunk = "8"
      
                            //(L) if "ChunkDownloadTimeoutSeconds" is reached
                            // while downloading chunk try this more times
            NumRetriesOnTimeout ="1"
      
                            //(L) after "bad" buffering occurs and "RebufferSizeMultiplier "
                            // and "RebufferSizeAddendMilliseconds " are applied,
                            // time that takes for player to rebuffer should not exceed this number of ms
            MaxAllowableTimeForRebuffersAfterSeekMilliseconds = "2000"
      
                            //(L) the difference between quantity of video data
                           // and audio data that were buffered must not exceed this number if ms
            MaxAudioVideoBufferDiscrepancyMilliseconds = "5000"
      
      
            MaxChunkDownloadRetries = "2"
      
                            //(M) maximum Consecutive 404 error per stream until it finally fails
            MaxConsecutiveChunkDownloadErrorsPerStream = "50"
      
                            //(L) maximum Consecutive 412 error per stream until it finally fails
            MaxConsecutiveChunkParseErrorsPerStream = "5"
      
      
            MaxGetNextStreamSampleRetries = "3"
      
                            //(H) maximum number of ms that could be buffered
                           // when playing Live or VOD if no rebuffering occurred
            MaxPlaybackBufferSizeMilliseconds = "30000"
      
                            //(L) after "bad" buffering occurs and "RebufferSizeMultiplier "
                            // and "RebufferSizeAddendMilliseconds " are applied,
                            // the maximum rebuffer size should be no more then this number of ms
            MaxPlaybackRebufferSizeMilliseconds ="15000"
      
                             //(H) playback will not start until this number of ms is buffered
                              // (valid when switching between Quality Levels and when starting or seeking,
                             // but valid also when switching Quality Levels in Live mode and not only in VOD mode)
            MinPlaybackBufferSizeMilliseconds = "5000"
      
                              //(H) When starting playing for the first time or back from the stop state,
                             // this number of ms must be buffered before playback starts
            MinPlaybackBufferSizeOnStartupMilliseconds = "2000"
      
                              //(M) after seeking, this number of ms must be buffered before playback starts
            MinPlaybackBufferSizeAfterSeekMilliseconds = "2000"
      
                              //(L) after "bad" buffering occurs,
                              // this number of ms is added to MaxPlaybackBufferSizeMilliseconds (or Some other buffer?)
            RebufferSizeAddendMilliseconds = "500"
      
                              //(L) after "bad" buffering occurs, MaxPlaybackBufferSizeMilliseconds (or Some other buffer?) 
                              // multiplied by this number
            RebufferSizeMultiplier = "1.25"
      
                            //(0.0 to 1.0)
                              //(M) should work only if "ForceAccurateSeeks" is not set to "true"
            SkipToNextAudioChunkIfSeekPointGreaterThanXPercentOfChunk="0.50"
      
      
                            //see SkipToNextAudioChunkIfSeekPointGreaterThanXPercentOfChunk
            SkipToNextVideoChunkIfSeekPointGreaterThanXPercentOfChunk="0.50"
      
                            //(H) if position pointer is this number of milliseconds close to live position treat 404 error as 412
            Treat404sAs412sIfWithinXMillisecondsOfLivePosition="3000"
      
      
            UseMasterSsmeTimestampForPipsIfWithinXMillisecondsOfPipSeekPosition="2000"
            BackOffFromLiveNumChunks="3"
      
                             //(H) if manifest could not be downloaded within this number of seconds, 
                            //throw Media Error
            ManifestDownloadTimeoutSeconds="30.0"
      
                            //(L) if downloading chunk for more 
                            //then this number of seconds, abort
            ChunkDownloadTimeoutSeconds="8.0"
      
                            //(L) maximum Consecutive ChunkTimeouts per stream until it finally
            MaxConsecutiveChunkTimeoutsPerStream="10"
      
      
            HighestPlayableTrackUpdateInterval="10000000"
      />
      <HeuristicsEngineSettings
       
                                //(L) maximum part of bandwidth that could be used for chunks downloading in relation to
                                // " BandwidthPercentageForUpgrade"
                BandwidthPercentageForSeekChunks="2.0"
       
                                 //(L) maximum part of bandwidth that could be used for update info downloading
                                 // in relation to " BandwidthPercentageForSeekChunks"
                BandwidthPercentageForUpgrade = "1.15"
       
       
                BandwidthSelectionType = "Avg"
       
                                //(L) if reading data faster than this number of bps take it as coming from cache
                CacheDetectionDownloadRateBytesPerSecond = "12500000"
       
                                //(L) Clear buffer if there is more than this percents of frames dropped.
                                // New Quality Level starts buffering
                FrameRateHeuristicsFlushBufferIfMoreThanXPercentDroppedFrames = "0.25"
       
                                // "TrackHistory" issue is to be investigated
                FrameRateHeuristicsOverallHistorySize = "8"
       
                                // "TrackHistory" issue is to be investigated
                FrameRateHeuristicsTrackHistorySize = "6"
       
                                // (L) On runtime player resizing sometimes causes Frame Dropping.
                                // Discard it this number of seconds after browser restores from being minimized
                FrameRateHeuristicsIgnoreFrameRateStatsWithinXSecondsOfBrowserUnminimization = "2"
       
                                 //(L) After seek request buffering of new position and Bandwidth Heuristics occurs,
                                 // causing frame dropping sometimes. Discard it this number of seconds after seek
                FrameRateHeuristicsIgnoreFrameRateStatsWithinXSecondsOfSeeks = "2"
       
                                // (L) On runtime player resizing sometimes causes Frame Dropping.
                                // Discard it this number of seconds after player was resized
                FrameRateHeuristicsIgnoreFrameRateStatsWithinXSecondsOfWindowSizeIncrease = "2"
       
                                //(H) if the Quality Level is not good check it next time in this number of seconds
                FrameRateHeuristicsInitialSuspensionPeriodSeconds = "30"
       
                                  //(H) number of times that any QualityLevel can be marked as not good by fr heuristics
                                 // before FR heuristics stops working. 
                                 //Note that from now on current QualityLevel is marked as Max Highest for all other heuristics
                FrameRateHeuristicsMaxSuspensions = "8"
       
                               // "Blessing" issue is to be investigated
                FrameRateHeuristicsXSuccessiveSecondsCountAsBlessing = "20"
                
                                // "Blessing" issue is to be investigated
                FrameRateHeuristicsNoBanAfterXBlessings = "3"
       
                                  // "Blessing" issue is to be investigated
                FrameRateHeuristicsBlessingsHaveToBeSuccessive = "false"
       
       
                FrameRateHeuristicsPreserveXSecondsOfBufferWhenFlushing = "3"
       
                                // "TrackHistory" issue is to be investigated
                FrameRateHeuristicsResetTrackHistoryAfterXSecondsOfInactivity = "10"
       
                                //(H) If more than this percents of frames are dropped,
                                 // mark current quality as "not good". If this value is "1" and
                               //  "FrameRateHeuristicsSuspendNextLowestTrackIfMoreThanXPercentDroppedFrames" value is "1.0"
                                // Framerate heuristics are neutralized until all frames are dropped
                FrameRateHeuristicsSuspendTrackIfMoreThanXPercentDroppedFrames = "0.15"
       
                                 //(H) If more than this percents of frames are dropped, 
                                 //mark lower quality as "not good". If this value is "1" and
                                 // "FrameRateHeuristicsSuspendTrackIfMoreThanXPercentDroppedFrames" value is "1.0"
                                 // Framerate heuristics are neutralized untill all frames are dropped
                FrameRateHeuristicsSuspendNextLowestTrackIfMoreThanXPercentDroppedFrames = "0.30"
       
                                 //(H) add this number of seconds (or ms?) to previous SuspensionPeriod
                                 // to calculate next SuspensionPeriod
                FrameRateHeuristicsSuspensionAddend = "0"
       
                                //(H) multiply previous Suspensoin Period by this value
                                 // to calculate next Suspensoin Period
                FrameRateHeuristicsSuspensionMultiplier = "1.0"
       
       
                LiveStableBufferSizeMilliseconds = "5000"
                LiveToOnDemandCrossoverTimeMilliseconds = "12000"
                LiveUpgradeBufferSizeMilliseconds = "3000"
                OnDemandStableBufferSizeMilliseconds = "6000"
                OnDemandUpgradeBufferSizeMilliseconds = "3000"
       
                                 //(H) number of chunks to be downloaded (and played) 
                                   // before switching to the lower QualityLevel. Should be 0 for fast fallback
                SwitchingFrequencyChunksBeforeDowngrade = "0"
       
                                // (H) number of chunks to be downloaded (and played) 
                                 //before switching to the higher QualityLevel
                SwitchingFrequencyChunksBeforeUpgrade = "2"
       
                                //(H) number of QualityLevels that could be stepped over
                                  // when moving to the higher QualityLevel .
                                 // Effects on starting (and may be seeking also). 
                                 // Should not exceed the allover number of QualityLevels
                SwitchingFrequencyStepSizeForUpgrade ="3"
       
                                  // (M) Errors are to be tracked within this number of consecutive chunks.
                                  // Rebuffering is a type of error, fo example
                TrackErrorHeuristicsWindowSize = "6"
       
                                   // (H) This number of errors is to occur for the current Quality Level to be suspended
                TrackErrorHeuristicsNumErrorsInWindowForSuspension = "3"
       
                                     //(H) number of times that any QualityLevel can marked as not good
                                     // by Track Error heuristics before it stops working
                TrackErrorHeuristicsMaxSuspensions = "5"
       
                                 //(H) if the Quality Level is for the first time marked by Track Error Heuristics as "not good",
                                // check it next time in this number of seconds. 
                                 //Every next time that the Quality Level is to marked as "not good" 
                                // suspend it for period that equals to this number of seconds multiplied by
                                // " TrackErrorHeuristicsSuspensionPeriodMultiplier" and/or add it
                                 // to "TrackErrorHeuristicsSuspensionPeriodAddend" number of seconds
                TrackErrorHeuristicsInitialSuspensionPeriod = "60"
       
                                  //(H) See TrackErrorHeuristicsInitialSuspensionPeriod
                TrackErrorHeuristicsSuspensionPeriodMultiplier = "2"
       
                                //(H) See TrackErrorHeuristicsInitialSuspensionPeriod
                TrackErrorHeuristicsSuspensionPeriodAddend = "0"
       
                                // (H) current display dimensions must be at least this part
                                // of the highest Quality Level dimensions
                WindowSizeHeuristicsMinimumPercentageOfNextLargestTrack = "0.75"
       
                RatioOfFullChunkToKeyframe="5.0"
       
                                 //(H) Disable Window Size Heuristics
                WindowSizeHeuristicsEnabled="true"
       />
      <DownloadManagerSettings   
                MaxCacheEntryAgeSeconds = "300"
                PruningIntervalMilliseconds = "5000"
                ReadSize="32768"
                ResponseCacheEnabled = "false"
                ResponseCacheSizeBytes = "50000000"
                NetworkingStackType="BrowserHttp"
                ClipNetworkingStackType="BrowserHttp"
        />
      <PlaybackSettings
                ParseSDTPBox="true"
                LowLatencyFramesPerChunk="3"
                AudioBufferLength="250"
                SeekClampTimeWindow="500"
                SeekClampPositionRange="2000"
                LoggingHistoryMaxLength="262144"
                AutomatedDefibrillatorTimeoutMilliseconds="3000"
      />
    </LiveSmoothStreamingSettings>

     

    Smooth Streaming smooth Smooth Streaming Client IIS Smooth Streaming IIS Smooth Streaming Client SmoothStreamingMediaElement

  • Re: SSME (Smooth Streaming Media Element) config.xml review (Smooth Streaming Client configuratio...

    Jan 27, 2011 10:57 AM|zebeubeul|LINK

    Hi
    This post is a nice one. Thank you for these hidden informations
    I know there is a long time this had been posted.
    I am currently writting a player on wp7. It works well with rtsp and ssme.
    But I have to say that heuristic of ssme on wp7 is not working well
    (Commutation does not occur at the right place, tested with Wanem)
    I tried the Config file to tune it and it works well (I mean the parameters really
    acts)
    But have theses fields (meaning) been explained now by Microsoft ?
    It is a bit tricky to tune !
    Zbb

     

     

     

  • Re: SSME (Smooth Streaming Media Element) config.xml review (Smooth Streaming Client configuratio...

    Jan 27, 2011 11:32 AM|SGamzu|LINK

    Have not checked in 3-rd party resources for a while but pretty sure there is still no official docs on this topic even after the new version (1.5) was released.

    And yes, you're right it's not a straight forward issue to tune

  • Re: SSME (Smooth Streaming Media Element) config.xml review (Smooth Streaming Client configuratio...

    Jul 19, 2011 11:51 AM|Timmy G|LINK

  • Re: SSME (Smooth Streaming Media Element) config.xml review (Smooth Streaming Client configuratio...

    Aug 10, 2011 09:35 PM|abarker|LINK

    zebeubeul

    Hi
    This post is a nice one. Thank you for these hidden informations
    I know there is a long time this had been posted.
    I am currently writting a player on wp7. It works well with rtsp and ssme.
    But I have to say that heuristic of ssme on wp7 is not working well
    (Commutation does not occur at the right place, tested with Wanem)
    I tried the Config file to tune it and it works well (I mean the parameters really
    acts)
    But have theses fields (meaning) been explained now by Microsoft ?
    It is a bit tricky to tune !
    Zbb

     

     

     

    I'm curious to know what elements you tweaked. I'm not satisfied with the current heuristics I'm seeing...
  • Re: SSME (Smooth Streaming Media Element) config.xml review (Smooth Streaming Client configuratio...

    Mar 25, 2014 04:45 PM|rceles1982|LINK

    Hi SGamzu,

    Very old post, but this is the only post related with configPath attribute of SSME that we found.

    we are using the 2.0 version, and we are trying to add “buffer progressbar” feature like youtube (other technology) or other companies that are using silverlight too.

    Right now we have the UX of the “buffer progressbar” (behind the playback progressbar) working  properly, using the SmoothStreamingCache interface like a monitor of chunk downloads, and with the config xml we can increase or decrease the buffer time without a very big start delay (MaxPlaybackBufferSizeMilliseconds). 

    But we have an issue that is blocking us, related with the normal behavior in offline scenario (when the network is down); the media player tries to download additional chunks and after 50 failed downloads it halts the playback.

    We can set MaxConsecutiveChunkDownloadErrorsPerStream to a higher number, but it gives an awful behavior of the mp, so we want to avoid that the media player still trying to request additional qualities, moving ahead in time of the playback, etc. to allow that it consume the buffer, and after finishing to consume all the buffer stop or pause the playback, allowing internet connection going down or up etc.

    Any idea?

    Thanks.

    Roberto.