mirror of
https://codeberg.org/Hyperpipe/Hyperpipe
synced 2025-06-28 13:08:01 +02:00
Changes:
- Range Headers for videoplayback - Changed behaviour of local playlists - Added UTC timestamps to footer
This commit is contained in:
parent
dac17fbc2d
commit
599e024afa
12 changed files with 465 additions and 416 deletions
|
@ -66,6 +66,22 @@ async function Stream() {
|
|||
|
||||
const codecs = useStore().getItem('codec');
|
||||
|
||||
audioPlayer
|
||||
.getNetworkingEngine()
|
||||
.registerRequestFilter((_type, req) => {
|
||||
const headers = req.headers;
|
||||
|
||||
let url = new URL(req.uris[0]);
|
||||
|
||||
if (url.pathname.indexOf('/videoplayback') > -1) {
|
||||
if (headers.Range) {
|
||||
url.searchParams.set('range', headers.Range.split('=')[1]);
|
||||
req.headers = {};
|
||||
req.uris[0] = url.toString();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
audioPlayer.configure({
|
||||
preferredAudioCodecs: codecs ? codecs.split(':') : ['opus', 'mp4a'],
|
||||
manifest: {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue