[webkit-changes] [WebKit/WebKit] db72dc: [MSE][Cocoa] Playback pauses when HTMLMediaElement...

Jer Noble noreply at github.com
Wed Sep 4 10:15:28 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: db72dcabba7e9d80280ecc0ca9ba1183b7f3ae21
      https://github.com/WebKit/WebKit/commit/db72dcabba7e9d80280ecc0ca9ba1183b7f3ae21
  Author: Jer Noble <jer.noble at apple.com>
  Date:   2024-09-04 (Wed, 04 Sep 2024)

  Changed paths:
    M Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h
    M Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm

  Log Message:
  -----------
  [MSE][Cocoa] Playback pauses when HTMLMediaElement renderer is destroyed
rdar://134811678
https://bugs.webkit.org/show_bug.cgi?id=278945

Reviewed by Eric Carlson.

MediaPlayerPrivateMediaSourceAVFObjC will destroy any display layers when its HTMLMediaElement
is removed from the render tree (e.g., through being removed from the DOM or display:none).
When it does this, it querys whether all the renderers have video or audio for display, and if not
will pause the synchronizer and stall playback.

The check to see whether all the renderers have something to display should query whether any
renderers exist, not just whether a video track exists.

* Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::maybeCompleteSeek):
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::updateAllRenderersHaveAvailableSamples):
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setReadyState):

Canonical link: https://commits.webkit.org/283161@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list