summaryrefslogtreecommitdiffstats
path: root/media/capture
Commit message (Collapse)AuthorAgeFilesLines
* Automatic resolution throttling for screen capture pipeline.miu2015-07-087-80/+737
| | | | | | | | | | | | | | | | | This makes VideoCaptureOracle responsible for proposing frame capture sizes. The oracle is given utilization feedback signals for each frame, and uses these to decide when to increase or decrease the capture size. Its goal is to automatically adapt to the current, ever-changing user environment and maintain capture at the frame rate of the content by lowering the capture resolution when necessary. NOTE: This new functionality is not enabled by default. BUG=156767 Review URL: https://codereview.chromium.org/1199593005 Cr-Commit-Position: refs/heads/master@{#337731}
* Make VideoCaptureFormat::ToString static.ajose2015-07-011-1/+2
| | | | | | | | BUG=501134 Review URL: https://codereview.chromium.org/1213193004 Cr-Commit-Position: refs/heads/master@{#337111}
* Remove superfluous checks in ScreenCaptureDeviceCore::AllocateAndStart()ajose2015-07-011-16/+0
| | | | | | | | BUG=503813 Review URL: https://codereview.chromium.org/1208093005 Cr-Commit-Position: refs/heads/master@{#337055}
* Reland: Video Capture: extract storage info from pixel format in ↵mcasas2015-06-252-11/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | VideoCaptureFormat. Relanding https://codereview.chromium.org/1179323002/ with dcheng@ comments addressed. Original description --------------------------------------------------- Video Capture: extract storage info from pixel format in VideoCaptureFormat. Video Capture Devices treat both Texture and GpuMemoryBuffer as a VideoPixelFormat, but they are storage types. Moreover, this merging prevents capture devices from indicating a combination of Storage and Capture formats, i.e. Texture + ARGB, or GpuMemoryBuffer+YUY2. This CL separates both concepts and updates necessary call points. It also extends the translation VideoCaptureFormat --> VideoFrame in VideoCaptureDeviceClient and in VideoCaptureBufferPool. VideoCaptureBufferPool::ReserveOutputBuffer() also gets a param to specify the StorageType. This separation also allows for VideoCaptureBufferPool to operate using VideoPixel{Format, Storage} ISO VideoFrame types, which spares the constant conversion between ones and others. Test: All video captures working exactly as before. BUG=440843 -------------------------------------------------------------------------- TBR=dalecurtis@chromium.org, miu@chromium.org, hubbe@chromium.org Rationale: they already LGTM PS1 and the changes from there onwards are either cosmetic (git cl format, DCHECK_EQ(expected, actual)) or discussed with dcheng@. Review URL: https://codereview.chromium.org/1204063005 Cr-Commit-Position: refs/heads/master@{#336208}
* CaptureResolutionChooser now takes targeted frame area into account.miu2015-06-243-15/+344
| | | | | | | | | | | | | | | For the variable-resolution use cases, CaptureResolutionChooser now takes a client-provided frame area into account when computing the capture size. An upcoming change will use this to increase or decrease the capture resolution in response to systemic bottlenecks, such as CPU/network availability. For now, this change won't cause any observable behavior differences. BUG=156767 Review URL: https://codereview.chromium.org/1185783006 Cr-Commit-Position: refs/heads/master@{#336007}
* Revert of Video Capture: extract storage info from pixel format in ↵dcheng2015-06-242-17/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | VideoCaptureFormat. (patchset #7 id:290001 of https://codereview.chromium.org/1179323002/) Reason for revert: The IPC changes in this patch were not reviewed. Original issue's description: > Video Capture: extract storage info from pixel format in VideoCaptureFormat. > > Video Capture Devices treat both Texture and GpuMemoryBuffer > as a VideoPixelFormat, but they are storage types. Moreover, > this merging prevents capture devices from indicating a > combination of Storage and Capture formats, i.e. > Texture + ARGB, or GpuMemoryBuffer+YUY2. > > This CL separates both concepts and updates necessary > call points. It also extends the translation > VideoCaptureFormat --> VideoFrame in > VideoCaptureDeviceClient and in VideoCaptureBufferPool. > VideoCaptureBufferPool::ReserveOutputBuffer() > also gets a param to specify the StorageType. > > This separation also allows for VideoCaptureBufferPool > to operate using VideoPixel{Format, Storage} ISO > VideoFrame types, which spares the constant conversion > between ones and others. > > Test: All video captures working exactly as before. > BUG=440843 > > TBR=dcheng@chromium.org for media_param_traits.cc > (Rationale: the change is small and I'm still going to be > actively working in this area so we can follow up in > other reviews). > > Committed: https://crrev.com/957fb245c45052e2c4b2bb0f59e165ba05096904 > Cr-Commit-Position: refs/heads/master@{#335872} TBR=dalecurtis@chromium.org,hubbe@chromium.org,miu@chromium.org,mcasas@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=440843 Review URL: https://codereview.chromium.org/1204843004 Cr-Commit-Position: refs/heads/master@{#335968}
* Video Capture: extract storage info from pixel format in VideoCaptureFormat.mcasas2015-06-242-11/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Video Capture Devices treat both Texture and GpuMemoryBuffer as a VideoPixelFormat, but they are storage types. Moreover, this merging prevents capture devices from indicating a combination of Storage and Capture formats, i.e. Texture + ARGB, or GpuMemoryBuffer+YUY2. This CL separates both concepts and updates necessary call points. It also extends the translation VideoCaptureFormat --> VideoFrame in VideoCaptureDeviceClient and in VideoCaptureBufferPool. VideoCaptureBufferPool::ReserveOutputBuffer() also gets a param to specify the StorageType. This separation also allows for VideoCaptureBufferPool to operate using VideoPixel{Format, Storage} ISO VideoFrame types, which spares the constant conversion between ones and others. Test: All video captures working exactly as before. BUG=440843 TBR=dcheng@chromium.org for media_param_traits.cc (Rationale: the change is small and I'm still going to be actively working in this area so we can follow up in other reviews). Review URL: https://codereview.chromium.org/1179323002 Cr-Commit-Position: refs/heads/master@{#335872}
* VideoCapture: merge IPC VideoCaptureMsg_BufferReady and ↵mcasas2015-06-191-5/+1
| | | | | | | | | | | | | | | | | | | | | | | | VideoCaptureMsg_MailboxBufferRead. Currently Browser->Render VideoFrame capture notifications has two messages, one for I420 ShMem frames and another for textures. This CL unifies both by sending the necessary data over IPC to reconstruct any at the Render side. This is also in anticipation of sending other pixel formats and/or combinations of format+storage types than the ones described in ToT. RESOLUTION_POLICY_LAST is updated so IPC validator can use it to test proper (de)serialisation of values. BUG=440843 TEST=This CL does _not_ introduce new functionality (does not pretend to), so all video capture should work as before. Review URL: https://codereview.chromium.org/1185443007 Cr-Commit-Position: refs/heads/master@{#335381}
* Move ContentVideoCaptureDeviceCore from src/content to src/mediajiajia.qin2015-06-1720-0/+3715
This CL moves ContentVideoCaptureDeviceCore related classes from src/content/browser/media/capture to src/media/capture. That will benefit the class under media which can use core and machine directly without depending on content. Review URL: https://codereview.chromium.org/1162863003 Cr-Commit-Position: refs/heads/master@{#334804}