Controlling quality with adaptive streaming
I know that there are various streaming profiles which control the resolution of the video. However, it seems that, regardless of which profile you use, Cloudinary starts with a lower bitrate and increases to higher bitrate if the network allows. Is there any way to invert this such that Cloudinary starts optimistically with a high bitrate and reduces if required?
-
Hi Ravi,
To give a general answer, when you use adaptive bitrate streaming profile to play a video, the decision about which version to start playing is made by the player. Depending on the player, you may be able to request a specific size or version is opened first, or it may always choose the smallest or largest first, or it may choose the first one in the m3u8 file first. I think it's very common to start with the smallest/lowest quality version so that it loads quickly, then replace it with a higher quality version if the available screen size/bandwidth/CPU supports that.
In the m3u8 files we create for the default streaming profiles we offer, the largest / highest quality videos are listed first, followed by the lower quality/size versions.
In your example, are you using the Cloudinary player or another? If it's our player, may I ask for an example of how you're initializing it, and if it's another, may I ask for some more information about that so I can check if it's possible to configure a specific order
Thanks,
Stephen0 -
Thank you for the information, Stephen!
We're not using the Cloudinary player, we're using iOS's AVQueuePlayer (https://developer.apple.com/documentation/avfoundation/avqueueplayer). I do see that the m3u8 files are listing the highest quality first, and it should be loading the first stream listed.
I just found preferredPeakBitRate (https://developer.apple.com/documentation/avfoundation/avplayeritem/1388541-preferredpeakbitrate) so that might be what we need to do. We'll investigate that, but if you can think of any other options, please let me know.
Thanks,
Ravi
0 -
Hi Ravi,
Apologies for the slow reply; It may be that you can configure this behavior in the Player (in this case, AVQueuePlayer) but I'm afraid I'm not personally aware of how to do so.
If you were having the opposite problem and wanted the small version to play instead of the large version, I could recommend manually creating the m3u8 file or using a streaming profile which changes the order of the representations, but it seems like the playlist is already correct and the issue lies with the player in this case
Regards,
Stephen0
Post is closed for comments.
Comments
3 comments