Bug 147014 - Make MediaPlayerPrivateMediaStreamAVFObjC rely on pre rendered platformLayers
Summary: Make MediaPlayerPrivateMediaStreamAVFObjC rely on pre rendered platformLayers
Status: RESOLVED INVALID
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Matthew Daiter
URL:
Keywords: InRadar, PlatformOnly
Depends on: 147011
Blocks:
  Show dependency treegraph
 
Reported: 2015-07-16 14:04 PDT by Matthew Daiter
Modified: 2015-07-22 13:52 PDT (History)
6 users (show)

See Also:


Attachments
Patch (2.14 KB, patch)
2015-07-16 14:16 PDT, Matthew Daiter
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Matthew Daiter 2015-07-16 14:04:57 PDT
Currently, the MediaPlayerPrivateMediaStreamAVFObjC class relies on generating PlatformLayers on the fly from calls to the AVVideoPreviewCaptureLayer class. Switching over to an easier method to make sure that the system can easily grab rendered images to display from a more efficient method of grabbing frames from the camera wrapper class.
Comment 1 Radar WebKit Bug Importer 2015-07-16 14:07:24 PDT
<rdar://problem/21862276>
Comment 2 Matthew Daiter 2015-07-16 14:16:32 PDT
Created attachment 256925 [details]
Patch
Comment 3 Brent Fulgham 2015-07-22 09:47:51 PDT
Comment on attachment 256925 [details]
Patch

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

> Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:178
> +        return (PlatformLayer*)static_cast<AVVideoCaptureSource*>(m_MediaStreamPrivate->client()->getVideoTracks().at(0)->source())->previewLayer();

Why are you removing the FIXME comment? this is still just getting the first webcam, isn't it? Or is this post-user-selection?
Comment 4 Matthew Daiter 2015-07-22 09:49:55 PDT
Comment on attachment 256925 [details]
Patch

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

>> Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:178
>> +        return (PlatformLayer*)static_cast<AVVideoCaptureSource*>(m_MediaStreamPrivate->client()->getVideoTracks().at(0)->source())->previewLayer();
> 
> Why are you removing the FIXME comment? this is still just getting the first webcam, isn't it? Or is this post-user-selection?

This is actually outdated. The getVideoTracks() and getAudioTracks() removal bug should take care of this, so that we don't need to check getVideoTracks().