Bug 234168 - Momentum Event Dispatcher: Tail frames are the wrong velocity if momentum event dispatch rate doesn't match screen refresh rate
Summary: Momentum Event Dispatcher: Tail frames are the wrong velocity if momentum eve...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Tim Horton
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-12-10 12:37 PST by Tim Horton
Modified: 2021-12-11 16:39 PST (History)
2 users (show)

See Also:


Attachments
Patch (13.96 KB, patch)
2021-12-10 12:38 PST, Tim Horton
no flags Details | Formatted Diff | Diff
Patch (14.58 KB, patch)
2021-12-10 14:15 PST, Tim Horton
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Horton 2021-12-10 12:37:57 PST
Momentum Event Dispatcher: Tail frames are the wrong velocity if momentum event dispatch rate doesn't match screen refresh rate
Comment 1 Tim Horton 2021-12-10 12:38:29 PST
Created attachment 446783 [details]
Patch
Comment 2 Tim Horton 2021-12-10 12:38:32 PST
<rdar://problem/86247557>
Comment 3 Simon Fraser (smfr) 2021-12-10 13:04:29 PST
Comment on attachment 446783 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=446783&action=review

> Source/WebKit/WebProcess/WebPage/MomentumEventDispatcher.cpp:295
> +    DisplayProperties properties;
> +    properties.displayID = displayID;
> +    properties.nominalFrameRate = nominalFramesPerSecond.value_or(WebCore::FullSpeedFramesPerSecond);

auto properties = DisplayProperties { displayID, nominalFramesPerSecond.value_or(WebCore::FullSpeedFramesPerSecond) } ?

> Source/WebKit/WebProcess/WebPage/MomentumEventDispatcher.h:78
> +        float nominalFrameRate;

Use the FramesPerSecond type?

> Source/WebKit/WebProcess/WebPage/MomentumEventDispatcher.h:144
> +        float displayNominalFrameRate { 0 };

Is this a frames per second, or a frame duration? If the former, can it use FramesPerSecond?
Comment 4 Tim Horton 2021-12-10 14:15:58 PST
Created attachment 446810 [details]
Patch
Comment 5 EWS 2021-12-11 16:39:23 PST
Committed r286919 (245145@main): <https://commits.webkit.org/245145@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 446810 [details].