utgg wrote:
> Actually, the real reason the streams were often erroring before they
> could start was due to a bug in HLS.pm. I don't know if you are
> monitoring any of this Triode, but you may want to include this in your
> next update. Near the end of HLS.pm:
> >
Code:
--------------------
> > if (!${*$self}{'_pl_noupdate'} && time() >
${*$self}{'_pl_fetched'} + ${*$self}{'_pl_lastint'}) {
--------------------
> >
> wants to be:
> >
Code:
--------------------
> > if (length ${*$self}{'_pl_url'} && !${*$self}{'_pl_noupdate'}
&& time() > ${*$self}{'_pl_fetched'} + ${*$self}{'_pl_lastint'}) {
--------------------
> >
>
> It still doesn't seem to do any harm in reducing FETCH_CHUNKS to 1 as
> I suggested originally. It gives a much faster start-up to the streams
> - the start-up time could be a bit variable with 5 chunks. This is
> because several async http chunk fetches are launched at once and it
> is random which one arrives first - if the first chunk arrives last it
> will take longer to start than if the first chunk arrives first. And
> having several chunks being fetched simultaneously will slow the first
> one down anyway.
I couldn't resist even more fiddling with the alpha HLS plugin; I hope
you don't mind if you are watching Triode!
With the attached HLS.pm I've done a small optimisation of the string
copies, as already hinted at by Triode. This reduces the number of bytes
copied by around 500 fold, and reduces the HLS decoding overhead
massively on my NAS, from about 40% to about 5% processor load. With
this change, the earlier bug fix and reduction in FETCH_CHUNKS, I'm very
happy indeed - streaming is reliable, interface is snappy, and I'm
heating up the planet just a little less now!
N.B. The attached file has FETCH_CHUNKS = 2, to be conservative. Startup
is even faster still with that set to 1 though, with no issues that I
can discern.
+-------------------------------------------------------------------+
|Filename: HLS.pm |
|Download: http://forums.slimdevices.com/attachment.php?attachmentid=17708|
+-------------------------------------------------------------------+
------------------------------------------------------------------------
utgg's Profile: http://forums.slimdevices.com/member.php?userid=40900
View this thread: http://forums.slimdevices.com/showthread.php?t=53229
_______________________________________________
plugins mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/plugins