Open jcampbell1710 opened 7 years ago
Flowplayer HTML5 version 6.x has no specific API for flash hls. Manual hls level selection is only possible with the hlsjs plugin: https://flowplayer.org/docs/plugins.html#hls-quality-selection
However, Flowplayer HTML5 version 7 will offer manual hls level selection for flash hls as well, see: https://github.com/flowplayer/flowplayer/issues/1080
Unfortunately, the issue I'm trying to solve is in Flash HLS only, since my problem is under non-HTML5 versions of IE. Is there any way you can recommend that could work around the API to do a manual level selection?
I don't know what the problem is you're trying to solve?
I am supporting HLS streaming to Flash-dependent browsers, and customers keep complaining about poor rendering in lower-bandwidth environments. While we are improving bandwidth where we can and recommending customers change to use HTML5-conformant browsers, some internal policies mandate use of IE on pre-Windows 8.1 environments, so we're stuck with Flash and they will be frustrated without the bandwidth solution.
In an effort to keep the visual experience steady (if not optimal), they want me to configure Flowplayer and FlashLS to keep from going down to the audio-only channels at startup (hence starfromlevel=0
, seekfromlevel=0
) and stay out of them through the length of the playback, even if this means the video has to pause for buffering. The first part works fine, and there is always video when the playback starts, but the bandwidth causes the stream to degenerate to audio-only after a few seconds. Plus, when the video is raised to a higher quality in environments with good bandwidth, the image distorts as it is is being promoted - we get pixel blocks.
I see no way to configure the parameters to set a minimum quality level or to make the channel switch any more graceful,, so I settled on the idea of just fixing it at a low or medium quality level and unconditionally forgo the attempt to render the highest qualities within these IE environments. That solves both problems - no audio-only playback occurs, and no pixelation occurs due to a stream upshift. Though I saw a way to set a fixed level in the Chromeless HLS Flash Player page (see above), it looks like that environment uses direct calls on the Flash media object to set the level, but this, as you pointed out, this is not in directly available from the API.
I tried the same method by doing a getElementsByTagName()
to get the Flash object that Flowplayer creates in the document, and to call the playerSetLevel()
method directly from it, as what appeared to be done in the Chromless HLS Flash Player page (see above). For some reason, playerSetLevel()
wasn't available from the object.
So - I'd like to know if: 1) there is a way to configure Flowplayer/FlashLS to avoid the lowest, audio only stream with the AAC files, or 2) it is possible bypass the API in a reliable way to use a fixed stream that does not change.
Is there also possibly a way to intervene on the downloaded manifest and remove the audio-stream from configuration altogether? That might also work.
I do not have any way to change the asset encodings or the manifests.
Thanks!
This sounds in part like encoding probs in your streams, but be that as it may, as I said, manual quality selection will be avaible for flash hls with the next release which we are working on right now. It sounds also like you have to doctor on the symptoms instead of curing the cause. One of the big advantages arguably of HLS is that manifests are just text files, and are easily edited ...
True but I cannot change the installed manifests. Is there a way within Flowplayer to intervene as they are loaded and remove the audio-only quality configuration from being considered? Like a "post-download, pre-load" event?
No, there isn't. And as far as I can see there won't be for flash hls even in fp 7. Sorry.
With the hlsjs plugin you can set the minAutoBitrate
option - https://github.com/dailymotion/hls.js/blob/v0.6.12/API.md#minautobitrate - but we won't put all bells and whistles into the flash backend - Flash is more and more depracated by major browsers.
Feel free to submit a patch, this is probably what you want to look at: https://github.com/flowplayer/flowplayer/blob/dev/lib/as/HLSStreamProvider.as
Then that brings me to going around the API, as I said above, using playerSetLevel()
? Do you have any examples of code that call that?
With Flowplayer 7 you will be able to do api.quality(2)
where 2 is the hls level index.
But to exclude variants (which seems to be the actual problem in your scenario) you would need a configuration setting for flashls which has the same effect as hlsjs' minAutoBitrate
, and not a method.
Right, but I was talking about something on the code level to stop it from picking the audio channel. I understand the API would handle it if we had Flowplayer 7.
On Dec 3, 2016 6:55 AM, "Christian Ebert" notifications@github.com wrote:
With Flowplayer 7 you will be able to do api.quality(2) where 2 is the hls level index. But to exclude variants (which seems to be the actual problem in your scenario) you would need a configuration setting for flashls which has the same effect as hlsjs' minAutoBitrate, and not a method.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/mangui/flashls/issues/562#issuecomment-264634830, or mute the thread https://github.com/notifications/unsubscribe-auth/ATuuuP6n25BlBJWg6Zvtd8pxfjmTOjdjks5rEVibgaJpZM4LBtLe .
To re-iterate: what will be added in fp 7 is manual level selection, i.e. the audio only level would still be there for selection and ABR.
To exclude levels from being selected by ABR and/or manual selection you'd need the equivalent of hls.js' minAutoBitrate
- or an API for flash hls engine specific methods, events etc. - and this is not planned. As much as we'd like to offer it in an ideal world, it would mean allocating a lot of resources (creation, maintenance, support) on a feature set which is not the focus of Flowplayer HTML5 and rapidly on the wane.
Is there a way to assign a fixed quality level in Flashls parameters?
In the "flashls - Chromeless HLS Flash player" test page at http://flashls.org/flashls-0.4.0/examples/chromeless, I noticed there is a setting "Set Level". This works, and when it is set, only the specified level is used - the bandwidth does not change, and if the buffers run out, the video just stops. However, I see that this page sets that parameter with a direct call using the Flash API, i.e., with
playerSetLevel(level).
However, I don't see this exposed in any of the published settings, and I looked through the source and saw no call to this method other than through the same sample page that was part of the flashls distribution.How would I do a fixed level setting? Is there a way that I am missing? If there is no way, can you suggest a workaround?
I'm using Flowplayer 6.0.4, and I presently have the following configuration.
startfromlevel
andseekfromlevel
start and seek the video at a certain level, as designed, but do not keep it there, also as designed. I see nothing in the documentation that is merely calledlevel
.