feat: adaptive bitrate support, engine improvements, demo updates, and electron preload
This commit is contained in:
@@ -12,6 +12,15 @@ const emit = defineEmits<{
|
||||
const fontSizeOptions = [20, 24, 28, 32]
|
||||
const bgAlphaOptions = [0, 0.3, 0.5, 0.7, 0.9]
|
||||
|
||||
const qualityOptions = [
|
||||
{ key: '', label: '自动' },
|
||||
{ key: '超清 (1080P)', label: '超清 (1080P)', speed: '需要 2.5 Mbps' },
|
||||
{ key: '高清 (720P)', label: '高清 (720P)', speed: '需要 2 Mbps' },
|
||||
{ key: '标清 (480P)', label: '标清 (480P)', speed: '需要 0.8 Mbps' },
|
||||
]
|
||||
|
||||
const isWeb = typeof window !== 'undefined' && !(window as any).__ELECTRON__
|
||||
|
||||
const langLabels: Record<string, string> = {
|
||||
zh: '中文',
|
||||
en: 'English',
|
||||
@@ -39,6 +48,15 @@ const langLabels: Record<string, string> = {
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="setting-row" v-if="isWeb">
|
||||
<span class="setting-label">画质</span>
|
||||
<select :value="store.preferredQuality" @change="store.setPreferredQuality(($event.target as HTMLSelectElement).value)">
|
||||
<option v-for="q in qualityOptions" :key="q.key" :value="q.key">
|
||||
{{ q.label }}{{ q.speed ? '(' + q.speed + ')' : '' }}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="setting-row">
|
||||
<span class="setting-label">{{ t('ui.subtitleSize') }}</span>
|
||||
<select :value="store.subFontSize" @change="store.setSubFontSize(+($event.target as HTMLSelectElement).value)">
|
||||
|
||||
Reference in New Issue
Block a user