Changeset 84988 in webkit


Ignore:
Timestamp:
Apr 26, 2011 5:15:31 PM (13 years ago)
Author:
jer.noble@apple.com
Message:

2011-04-26 Jer Noble <jer.noble@apple.com>

Reviewed by Brady Eidson.

HTML5 video fullscreen transition causes an audio stutter
https://bugs.webkit.org/show_bug.cgi?id=59544

AVFoundation will momentarily stutter when you disconnect a AVPlayerLayer
from its AVPlayer. Since you shouldn't necessarily have to destroy the
layer to render it invisible, instead just set the layer as hidden.

  • platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp: (WebCore::MediaPlayerPrivateAVFoundation::setVisible): Call through to platformSetVisible().
  • platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
  • platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h:
  • platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::platformSetVisible): Added.
Location:
trunk/Source/WebCore
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r84983 r84988  
     12011-04-26  Jer Noble  <jer.noble@apple.com>
     2
     3        Reviewed by Brady Eidson.
     4
     5        HTML5 video fullscreen transition causes an audio stutter
     6        https://bugs.webkit.org/show_bug.cgi?id=59544
     7
     8        AVFoundation will momentarily stutter when you disconnect a AVPlayerLayer
     9        from its AVPlayer.  Since you shouldn't necessarily have to destroy the
     10        layer to render it invisible, instead just set the layer as hidden.
     11
     12        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
     13        (WebCore::MediaPlayerPrivateAVFoundation::setVisible): Call through to platformSetVisible().
     14        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
     15        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h:
     16        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
     17        (WebCore::MediaPlayerPrivateAVFoundationObjC::platformSetVisible): Added.
     18
    1192011-04-26  Christian Dywan  <christian@lanedo.com>
    220
  • trunk/Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp

    r84497 r84988  
    527527    if (visible)
    528528        setUpVideoRendering();
    529     else
    530         tearDownVideoRendering();
     529   
     530    platformSetVisible(visible);
    531531}
    532532
  • trunk/Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h

    r84497 r84988  
    185185    virtual AVAssetStatus assetStatus() const = 0;
    186186
     187    virtual void platformSetVisible(bool) = 0;
    187188    virtual void platformPlay() = 0;
    188189    virtual void platformPause() = 0;
  • trunk/Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h

    r83667 r84988  
    7474    virtual PlatformMedia platformMedia() const;
    7575
     76    virtual void platformSetVisible(bool);
    7677    virtual void platformPlay();
    7778    virtual void platformPause();
  • trunk/Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm

    r84504 r84988  
    356356}
    357357
     358void MediaPlayerPrivateAVFoundationObjC::platformSetVisible(bool isVisible)
     359{
     360    if (m_videoLayer)
     361        [m_videoLayer.get() setHidden:!isVisible];
     362}
     363   
    358364void MediaPlayerPrivateAVFoundationObjC::platformPlay()
    359365{
Note: See TracChangeset for help on using the changeset viewer.