HLS and DASH streams provide different bit rate encodings (profiles) for the same short burst of video. TVSDK can select the quality level for each burst based on the current buffering level and the available bandwidth.
TVSDK constantly monitors the bit rate to ensure that the content is played at the optimal bit rate for the current network connection. You can set the adaptive bit rate (ABR) switching policy and the initial, minimum, and maximum bit rates for a multiple-bit-rate (MBR) stream. TVSDK automatically switches to the bit rate that provides the best playback experience in the specified configuration.
|Initial bit rate||
The desired playback bit rate (in bits per second) for the first segment.
When playback starts, the closest profile, which is equal to or greater than the initial bit rate, is used for the first segment. If a minimum bit rate is defined, and the initial bit rate is lower than the minimum rate, TVSDK selects the profile with the lowest bit rate above the minimum bit rate. If the initial rate is above the maximum rate, TVSDK selects the highest rate below the maximum rate. If the initial bit rate is zero or undefined, the initial bit rate is determined by the ABR policy.
getABRInitialBitRate returns an integer value that represents the byte-per-second profile.
|Minimum bit rate||
The lowest allowed bit rate to which the ABR can switch.
ABR switching ignores profiles with a bit rate that is lower than this bit rate. getABRMinBitRate returns an integer value that represents the bits-per-second profile.
|Maximum bit rate||
The highest allowed bit rate to which the ABR can switch.
ABR switching ignores profiles with a bit rate higher than this bit rate. getABRMaxBitRate returns an integer value that represents the bits-per-second profile.
|ABR switching policy||
Playback switches gradually to the highest-bit-rate profile when possible. You can set the policy for ABR switching, which determines how quickly TVSDK switches between profiles. The default is ABR_MODERATE.
When TVSDK decides to switch to a higher bit rate, the player selects the ideal bit rate profile to switch to based on the current ABR policy:
If the initial bit rate is zero, or is not specified but a policy is specified, playback starts with the lowest bit rate profile for a conservative policy, the profile closest to the median bit rate of available profiles for a moderate policy, and the highest bit rate profile for an aggressive policy.
The policy works in the constraints of the minimum and maximum bit rates, if these rates are specified.
getABRPolicy returns the current setting from the ABRControlParameters enum: ABR_CONSERVATIVE, ABR_MODERATE, or ABR_AGGRESSIVE.
For more information, see ABR Control Parameteres API doc.
Keep the following information in mind:
The TVSDK failover mechanism might override your settings, because TVSDK favors a continuous playback experience over strictly adhering to your control parameters.
When the bit rate changes, TVSDK dispatches
onProfileChanged events in
You can change your ABR settings at any time, and the player switches to use the profile that most closely matches the most recent settings.
For example, if a stream has the following profiles:
If you specify a range of 300000 to 2000000, TVSDK considers only profiles 1, 2 and 3. This allows applications to adjust to various network conditions, such as switching from wi-fi to 3G or to various devices such as a phone, a tablet, or a desktop computer.
To set ABR control parameters, set the parameters on the