From 1f11c16aefe71d68605d2cd0ad5da9c016aa3570 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Mon, 2 Oct 2023 22:58:44 +0200 Subject: testing profile autoselect --- web/script/player/mod.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'web/script/player/mod.ts') diff --git a/web/script/player/mod.ts b/web/script/player/mod.ts index 9c1b060..89919e4 100644 --- a/web/script/player/mod.ts +++ b/web/script/player/mod.ts @@ -22,7 +22,7 @@ function initialize_player(el: HTMLElement, node_id: string) { el.innerHTML = "" // clear the body const player = new Player(node_id) - const show_stats = new OVar(false); + const show_stats = new OVar(true); const toggle_playing = () => player.playing.value ? player.pause() : player.play() const pri_map = (v: number) => (v / player.duration.value * 100) + "%" @@ -123,7 +123,7 @@ function mouse_idle(e: HTMLElement, timeout: number, cb: (b: boolean) => unknown function show_profile(profile: EncodingProfile): string { if (profile.audio) return `codec=${profile.audio.codec} ar=${show.metric(profile.audio.sample_rate ?? -1, "Hz")} abr=${show.metric(profile.audio.bitrate, "b/s")}` - if (profile.video) return `codec=${profile.video.codec} vw=${show.metric(profile.video.width ?? -1, "Hz")} vbr=${show.metric(profile.video.bitrate, "b/s")} preset=${profile.video.preset}` + if (profile.video) return `codec=${profile.video.codec} vw=${profile.video.width} vbr=${show.metric(profile.video.bitrate, "b/s")} preset=${profile.video.preset}` if (profile.subtitles) return `codec=${profile.subtitles.codec}` return `???` } \ No newline at end of file -- cgit v1.2.3-70-g09d2