[webkit-reviews] review granted: [Bug 224469] [GPUP] WebContent process should not create AVOutputContext instances when media in GPU Process is enabled : [Attachment 426066] Revise the patch after a discussion with Eric

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Apr 15 08:29:11 PDT 2021


Eric Carlson <eric.carlson at apple.com> has granted Peng Liu
<peng.liu6 at apple.com>'s request for review:
Bug 224469: [GPUP] WebContent process should not create AVOutputContext
instances when media in GPU Process is enabled
https://bugs.webkit.org/show_bug.cgi?id=224469

Attachment 426066: Revise the patch after a discussion with Eric

https://bugs.webkit.org/attachment.cgi?id=426066&action=review




--- Comment #11 from Eric Carlson <eric.carlson at apple.com> ---
Comment on attachment 426066
  --> https://bugs.webkit.org/attachment.cgi?id=426066
Revise the patch after a discussion with Eric

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

> Source/WebCore/platform/graphics/cocoa/MediaPlaybackTargetContext.mm:41
> +    if (m_outputContext)

If the context us null m_type will be ‘unknown’, which doesn’t seem right. I
think we should always set m_type or assert if it isn’t valid to have a null
context

> Source/WebCore/platform/graphics/cocoa/MediaPlaybackTargetContext.mm:97
> +    ASSERT(m_type == MediaPlaybackTargetContext::Type::AVOutputContext);

This same assertion is done above

> Source/WebCore/platform/mock/MediaPlaybackTargetMock.h:46
> +    bool hasActiveRoute() const final { return m_context.hasActiveRoute(); }

If we did this in the base class, the two derived classes wouldn’t have to do
anything

> Source/WebCore/platform/mock/MediaPlaybackTargetMock.h:47
> +    String deviceName() const final { return m_context.deviceName(); }

Ditto

> Source/WebCore/platform/mock/MediaPlaybackTargetMock.h:48
> +    bool supportsRemoteVideoPlayback() const final { return
m_context.supportsRemoteVideoPlayback(); }

Ditto


More information about the webkit-reviews mailing list