Bug 199581 - Hop explicitly to the main thread after generating a frame in ScreenDisplayCaptureSourceMac
Summary: Hop explicitly to the main thread after generating a frame in ScreenDisplayCa...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebRTC (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: youenn fablet
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-07-08 11:24 PDT by youenn fablet
Modified: 2019-07-08 16:51 PDT (History)
4 users (show)

See Also:


Attachments
Patch (6.14 KB, patch)
2019-07-08 11:27 PDT, youenn fablet
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description youenn fablet 2019-07-08 11:24:19 PDT
Hop explicitly to the main thread after generating a frame in ScreenDisplayCaptureSourceMac
Comment 1 youenn fablet 2019-07-08 11:27:59 PDT
Created attachment 373648 [details]
Patch
Comment 2 Eric Carlson 2019-07-08 14:15:47 PDT
Comment on attachment 373648 [details]
Patch

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

> Source/WebCore/platform/mediastream/mac/ScreenDisplayCaptureSourceMac.mm:169
> +                weakThis->newFrame(status, WTFMove(frame));

There isn't a lot of code in newFrame now, it might make sense to move it here.
Comment 3 youenn fablet 2019-07-08 16:17:01 PDT
Comment on attachment 373648 [details]
Patch

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

>> Source/WebCore/platform/mediastream/mac/ScreenDisplayCaptureSourceMac.mm:169
>> +                weakThis->newFrame(status, WTFMove(frame));
> 
> There isn't a lot of code in newFrame now, it might make sense to move it here.

It makes a nice separation between main-thread/non main thread.
And we might want to beef-up newFrame so that it becomes something like generateNewFrame if we get rid of the timer.
Comment 4 Radar WebKit Bug Importer 2019-07-08 16:17:21 PDT
<rdar://problem/52803327>
Comment 5 WebKit Commit Bot 2019-07-08 16:51:49 PDT
Comment on attachment 373648 [details]
Patch

Clearing flags on attachment: 373648

Committed r247238: <https://trac.webkit.org/changeset/247238>
Comment 6 WebKit Commit Bot 2019-07-08 16:51:51 PDT
All reviewed patches have been landed.  Closing bug.