mirror of
https://github.com/TeamPiped/Piped.git
synced 2024-11-24 14:37:20 +00:00
feat: add option to favor hls over dash
This commit is contained in:
parent
174a4cc86c
commit
f00b9cafcd
@ -69,6 +69,10 @@
|
||||
<strong v-t="'actions.audio_only'" />
|
||||
<input id="chkAudioOnly" v-model="listen" class="checkbox" type="checkbox" @change="onChange($event)" />
|
||||
</label>
|
||||
<label class="pref" for="chkPreferHls">
|
||||
<strong v-t="'actions.prefer_hls'" />
|
||||
<input id="chkPreferHls" v-model="preferHls" class="checkbox" type="checkbox" @change="onChange($event)" />
|
||||
</label>
|
||||
<label class="pref" for="ddlDefaultQuality">
|
||||
<strong v-t="'actions.default_quality'" />
|
||||
<select id="ddlDefaultQuality" v-model="defaultQuality" class="select w-auto" @change="onChange($event)">
|
||||
@ -438,6 +442,7 @@ export default {
|
||||
autoPlayNextCountdown: 5,
|
||||
listen: false,
|
||||
resolutions: [144, 240, 360, 480, 720, 1080, 1440, 2160, 4320],
|
||||
preferHls: false,
|
||||
defaultQuality: 0,
|
||||
bufferingGoal: 10,
|
||||
countryMap: CountryMap,
|
||||
@ -619,6 +624,7 @@ export default {
|
||||
localStorage.setItem("autoDisplayCaptions", this.autoDisplayCaptions);
|
||||
localStorage.setItem("autoPlayNextCountdown", this.autoPlayNextCountdown);
|
||||
localStorage.setItem("listen", this.listen);
|
||||
localStorage.setItem("preferHls", this.preferHls);
|
||||
localStorage.setItem("quality", this.defaultQuality);
|
||||
localStorage.setItem("bufferGoal", this.bufferingGoal);
|
||||
localStorage.setItem("region", this.countrySelected);
|
||||
|
@ -328,7 +328,12 @@ export default {
|
||||
if (this.video.livestream) {
|
||||
uri = this.video.hls;
|
||||
mime = "application/x-mpegURL";
|
||||
} else if (this.video.audioStreams.length > 0 && !lbry && MseSupport) {
|
||||
} else if (
|
||||
this.video.audioStreams.length > 0 &&
|
||||
!lbry &&
|
||||
MseSupport &&
|
||||
!this.getPreferenceBoolean("preferHls", false)
|
||||
) {
|
||||
if (!this.video.dash) {
|
||||
const dash = (await import("../utils/DashUtils.js")).generate_dash_file_from_formats(
|
||||
streams,
|
||||
|
@ -160,7 +160,8 @@
|
||||
"creator_replied": "Creator replied",
|
||||
"creator_liked": "Creator liked",
|
||||
"playback_speed": "Playback speed",
|
||||
"invalid_input": "Invalid input"
|
||||
"invalid_input": "Invalid input",
|
||||
"prefer_hls": "Prefer HLS over DASH"
|
||||
},
|
||||
"comment": {
|
||||
"pinned_by": "Pinned by {author}",
|
||||
|
Loading…
Reference in New Issue
Block a user