From 4abfdb389d6a90fdc9a2117393886ffe68039a6a Mon Sep 17 00:00:00 2001 From: Antonio Stoilkov Date: Tue, 16 Jan 2024 14:09:28 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20user-visible=20should=20run=20fo?= =?UTF-8?q?r=2080%=20of=201=20frame=20when=2060fps=20(13ms)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/isTimeToYield.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/isTimeToYield.ts b/src/isTimeToYield.ts index 31d20e5..1445c17 100644 --- a/src/isTimeToYield.ts +++ b/src/isTimeToYield.ts @@ -50,7 +50,7 @@ function calculateDeadline(priority: SchedulingPriority): number { case 'user-visible': { // spent 80% percent of the frame's budget running 'user-visible' tasks: // - Math.round((1000/60) * 0.8) = Math.round(13,333) = 13 - return schedulingState.thisFrameWorkStartTime + 4 + return schedulingState.thisFrameWorkStartTime + 13 } case 'background': { const idleDeadline =