Open SamJarmanPP opened 4 years ago
@SamJarmanPP, is the problem you are facing that you only get one parsed object instead of an array of them ?
Honestly, I cant remember now. But that does sound right - is that the current behaviour?
I believe so. I played around with it today and I have quite a simple fix. I plan to submit a PR on Sunday. See how it goes
Does this mean EXT-X-I-FRAME-STREAM-INF still is only supported by making custom parser?
Yes it seems so after some testing...
Workaround:
const entries = [];
parser.addParser({
expression: /^#EXT-X-I-FRAME-STREAM-INF/,
customType: 'iframes',
dataParser: (line) => {
// Process line into entry...
entries.push(entry);
return entries;
}
});
parser.push(data);
parser.end();
parser.manifest.custom.iframes // <- Array of entries.
Thx - I guess it should be
entries.push(line)
?
Not sure videojs-http-streaming support custom stuff though where I use this. The playlist contains a mixture of these INFs and "regular # variants" - I tried to removed those to make sure custom was used - but then it didn't work. Perhaps I removed too much...
I noticed I could provide a customTagParser to videojs-http-streaming - seemed to parse it - but still couldn't play the stream...
I'd like to see support for the parsing of
#EXT-X-I-FRAME-STREAM-INF
lines. eg#EXT-X-I-FRAME-STREAM-INF: BANDWIDTH=100403,RESOLUTION=392x216,CODECS="avc1.42c01e",URI="QualityLevels(90258)/Manifest(video,format=m3u8-aapl,type=keyframes)"
I tried to make a custom parser for this, but I cant seem to get it to work right with an object for each time this line occurs (many times)
Any ideas welcome, Thanks!