From 90db6445593f27c129192ce8fc470930c049ebfc Mon Sep 17 00:00:00 2001 From: Ted Michael Celis Date: Sat, 27 Apr 2024 13:15:21 -0700 Subject: [PATCH] changed canvas resolution formula --- ytglow.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ytglow.js b/ytglow.js index 0ee706f..f80558c 100644 --- a/ytglow.js +++ b/ytglow.js @@ -13,8 +13,8 @@ var fograf; function updatefog() { var video = document.querySelector("ytd-watch-flexy video") || document.querySelector("video"); var rect = video.getBoundingClientRect(); - canvas.width = rect.width / 8; - canvas.height = rect.height / 8; + canvas.width = 64; + canvas.height = 64 * rect.height / rect.width; canvas.style.width = rect.width + "px"; canvas.style.height = rect.height + "px"; context.drawImage(video, 0, 0, canvas.width, canvas.height);