Changeset 244922 in webkit


Ignore:
Timestamp:
May 3, 2019 2:47:37 PM (5 years ago)
Author:
eric.carlson@apple.com
Message:

AVFoundation framework isn't always installed
https://bugs.webkit.org/show_bug.cgi?id=197577
<rdar://problem/50447841>

Reviewed by Jer Noble.

Use PAL::isAVFoundationFrameworkAvailable() to check to see if AVFoundation is
installed, not PAL::AVFoundationLibrary().

  • platform/graphics/avfoundation/objc/AVFoundationMIMETypeCache.mm:

(WebCore::AVFoundationMIMETypeCache::isAvailable const):
(WebCore::AVFoundationMIMETypeCache::loadMIMETypes):

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:

(WebCore::MediaPlayerPrivateAVFoundationObjC::isAvailable):
(WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessPlaybackTargetType const):
(WebCore::exernalDeviceDisplayNameForPlayer):

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:

(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::isAvailable):

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:

(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::isAvailable):

  • platform/graphics/cocoa/HEVCUtilitiesCocoa.mm:

(WebCore::validateHEVCParameters):

  • platform/mediastream/mac/AVCaptureDeviceManager.mm:

(WebCore::AVCaptureDeviceManager::isAvailable):

Location:
trunk/Source/WebCore
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r244921 r244922  
     12019-05-03  Eric Carlson  <eric.carlson@apple.com>
     2
     3        AVFoundation framework isn't always installed
     4        https://bugs.webkit.org/show_bug.cgi?id=197577
     5        <rdar://problem/50447841>
     6
     7        Reviewed by Jer Noble.
     8       
     9        Use PAL::isAVFoundationFrameworkAvailable() to check to see if AVFoundation is
     10        installed, not PAL::AVFoundationLibrary().
     11
     12        * platform/graphics/avfoundation/objc/AVFoundationMIMETypeCache.mm:
     13        (WebCore::AVFoundationMIMETypeCache::isAvailable const):
     14        (WebCore::AVFoundationMIMETypeCache::loadMIMETypes):
     15        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
     16        (WebCore::MediaPlayerPrivateAVFoundationObjC::isAvailable):
     17        (WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessPlaybackTargetType const):
     18        (WebCore::exernalDeviceDisplayNameForPlayer):
     19        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
     20        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::isAvailable):
     21        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
     22        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::isAvailable):
     23        * platform/graphics/cocoa/HEVCUtilitiesCocoa.mm:
     24        (WebCore::validateHEVCParameters):
     25        * platform/mediastream/mac/AVCaptureDeviceManager.mm:
     26        (WebCore::AVCaptureDeviceManager::isAvailable):
     27
    1282019-05-03  Sihui Liu  <sihui_liu@apple.com>
    229
  • trunk/Source/WebCore/platform/graphics/avfoundation/objc/AVFoundationMIMETypeCache.mm

    r244704 r244922  
    9494    // FIXME: This should be using AVFoundationLibraryIsAvailable() instead, but doing so causes soft-linking
    9595    // to subsequently fail on certain symbols. See <rdar://problem/42224780> for more details.
    96     return PAL::AVFoundationLibrary();
     96    return PAL::isAVFoundationFrameworkAvailable();
    9797#else
    9898    return AVFoundationLibraryIsAvailable();
     
    110110    static std::once_flag onceFlag;
    111111    std::call_once(onceFlag, [this] {
    112         if (!PAL::AVFoundationLibrary())
     112        if (!PAL::isAVFoundationFrameworkAvailable())
    113113            return;
    114114
  • trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm

    r244704 r244922  
    16971697bool MediaPlayerPrivateAVFoundationObjC::isAvailable()
    16981698{
    1699     return PAL::AVFoundationLibrary() && isCoreMediaFrameworkAvailable();
     1699    return PAL::isAVFoundationFrameworkAvailable() && isCoreMediaFrameworkAvailable();
    17001700}
    17011701
     
    25772577
    25782578#if PLATFORM(IOS_FAMILY)
    2579     if (!PAL::AVFoundationLibrary())
     2579    if (!PAL::isAVFoundationFrameworkAvailable())
    25802580        return MediaPlayer::TargetTypeNone;
    25812581
     
    26012601{
    26022602#if HAVE(CELESTIAL)
    2603     if (!PAL::AVFoundationLibrary())
     2603    if (!PAL::isAVFoundationFrameworkAvailable())
    26042604        return nil;
    26052605
  • trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm

    r244704 r244922  
    180180bool MediaPlayerPrivateMediaSourceAVFObjC::isAvailable()
    181181{
    182     return PAL::AVFoundationLibrary()
     182    return PAL::isAVFoundationFrameworkAvailable()
    183183        && isCoreMediaFrameworkAvailable()
    184184        && getAVStreamDataParserClass()
  • trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm

    r244704 r244922  
    227227bool MediaPlayerPrivateMediaStreamAVFObjC::isAvailable()
    228228{
    229     return PAL::AVFoundationLibrary() && isCoreMediaFrameworkAvailable() && getAVSampleBufferDisplayLayerClass();
     229    return isAVFoundationFrameworkAvailable() && isCoreMediaFrameworkAvailable() && getAVSampleBufferDisplayLayerClass();
    230230}
    231231
  • trunk/Source/WebCore/platform/graphics/cocoa/HEVCUtilitiesCocoa.mm

    r244704 r244922  
    4242    CMVideoCodecType codec = kCMVideoCodecType_HEVC;
    4343    if (hasAlphaChannel) {
    44         if (!PAL::AVFoundationLibrary() || !PAL::canLoad_AVFoundation_AVVideoCodecTypeHEVCWithAlpha())
     44        if (!PAL::isAVFoundationFrameworkAvailable() || !PAL::canLoad_AVFoundation_AVVideoCodecTypeHEVCWithAlpha())
    4545            return false;
    4646
  • trunk/Source/WebCore/platform/mediastream/mac/AVCaptureDeviceManager.mm

    r244704 r244922  
    161161bool AVCaptureDeviceManager::isAvailable()
    162162{
    163     return PAL::AVFoundationLibrary();
     163    return PAL::isAVFoundationFrameworkAvailable();
    164164}
    165165
Note: See TracChangeset for help on using the changeset viewer.