Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(718)

Issue 2343423003: Extract nested and private classes from VideoCaptureBufferPool (Closed)

Created:
4 years, 3 months ago by chfremer
Modified:
4 years, 3 months ago
CC:
chromium-reviews, posciak+watch_chromium.org, jam, feature-media-reviews_chromium.org, darin-cc_chromium.org, mcasas+watch+vc_chromium.org, miu+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Extract nested and private classes from VideoCaptureBufferPool This CL is part of the Mojo Video Capture work. For the bigger picture, see [1] CL1.6.2. This CL is a step towards being able to reuse the classes VideoCaptureDeviceClient and VideoCaptureBufferPool as part of the Video Capture Mojo Service, because they implement functionality that is needed there. Expressed in class-diagram form, we want to realize the cut indicated by the red line in [2]. Currently, the classes VideoCaptureDeviceClient and VideoCaptureBufferPool live in content/browser/renderer_host/media. Even though their functionality is not specific to renderer_host, their dependencies create a tight coupling to code that is. In order to use them in services/video_capture, we need to move them out of there (and probably into media/capture/video). In this CL we move the nested and private classes from video_capture_buffer_pool.h/cc into stand-alone classes using separate files. After this separation, we will be able to move the parts that do not depend on content/browser/renderer_host/media to media/capture/video and keep the other parts where they are. Additional changes: * Rename interface VideoCaptureBufferPoolBufferHandle to VideoCaptureBufferHandle Note: Code in new file comes from either video_capture_buffer_pool.h or .cc. No additions or modifications oder than the required includes and guards. BUG=584797 TEST=This is a pure refactoring. No new functionality. content_unittests still pass. [1] https://docs.google.com/a/chromium.org/document/d/1Qw7rw1AJy0QHXjha36jZNiEuxsxWslJ_X-zpOhijvI8/edit?usp=sharing [2] https://docs.google.com/drawings/d/1acJSbj8eCK5Lpvv9QPiU_V34t8GfgqfYSoYbA93jb5o/edit Committed: https://crrev.com/71238feb8a373499b95a8b78572c81a456a37106 Cr-Commit-Position: refs/heads/master@{#420475}

Patch Set 1 #

Total comments: 10

Patch Set 2 : mcasas' comments #

Patch Set 3 : Add mcasas@ as owner for extraced code #

Patch Set 4 : Merge branch 'master' into BufferPoolRefactor #

Unified diffs Side-by-side diffs Delta from patch set Stats (+605 lines, -330 lines) Patch
M content/browser/BUILD.gn View 1 2 3 2 chunks +12 lines, -0 lines 0 comments Download
M content/browser/media/capture/web_contents_video_capture_device_unittest.cc View 1 3 chunks +5 lines, -5 lines 0 comments Download
M content/browser/renderer_host/media/OWNERS View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/gpu_memory_buffer_handle.h View 1 chunk +38 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/gpu_memory_buffer_handle.cc View 1 1 chunk +44 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/gpu_memory_buffer_tracker.h View 1 chunk +42 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/gpu_memory_buffer_tracker.cc View 1 2 3 1 chunk +105 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/shared_memory_buffer_handle.h View 1 chunk +38 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/shared_memory_buffer_handle.cc View 1 1 chunk +41 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/shared_memory_buffer_tracker.h View 1 chunk +39 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/shared_memory_buffer_tracker.cc View 1 1 chunk +52 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/video_capture_buffer_handle.h View 1 chunk +29 lines, -0 lines 0 comments Download
M content/browser/renderer_host/media/video_capture_buffer_pool.h View 1 7 chunks +7 lines, -81 lines 0 comments Download
M content/browser/renderer_host/media/video_capture_buffer_pool.cc View 1 2 3 11 chunks +17 lines, -240 lines 0 comments Download
M content/browser/renderer_host/media/video_capture_buffer_pool_unittest.cc View 1 4 chunks +4 lines, -3 lines 0 comments Download
A content/browser/renderer_host/media/video_capture_buffer_tracker.h View 1 1 chunk +78 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/video_capture_buffer_tracker_factory.h View 1 chunk +22 lines, -0 lines 0 comments Download
A content/browser/renderer_host/media/video_capture_buffer_tracker_factory.cc View 1 chunk +28 lines, -0 lines 0 comments Download
M content/browser/renderer_host/media/video_capture_device_client.cc View 1 2 chunks +2 lines, -1 line 0 comments Download

Dependent Patchsets:

Messages

Total messages: 28 (19 generated)
chfremer
mcasas@: PTAL miu@: PTAL emircan@: FYI
4 years, 3 months ago (2016-09-19 22:08:44 UTC) #8
mcasas
lgtm with some comments/ suggestions https://codereview.chromium.org/2343423003/diff/1/content/browser/renderer_host/media/gpu_memory_buffer_tracker.cc File content/browser/renderer_host/media/gpu_memory_buffer_tracker.cc (right): https://codereview.chromium.org/2343423003/diff/1/content/browser/renderer_host/media/gpu_memory_buffer_tracker.cc#newcode97 content/browser/renderer_host/media/gpu_memory_buffer_tracker.cc:97: case gfx::SURFACE_TEXTURE_BUFFER: https://codereview.chromium.org/2353453002/ is ...
4 years, 3 months ago (2016-09-20 00:51:08 UTC) #10
chfremer
mcasas@: PTAL miu@: PTAL RS Note: Besides addressing the comments, I added mcasas@ as owner ...
4 years, 3 months ago (2016-09-20 18:43:10 UTC) #13
chfremer
miu@: ping PTAL RS
4 years, 3 months ago (2016-09-21 21:30:13 UTC) #14
chfremer
avi@chromium.org: PTAL RS for BUILD.gn and OWNERS
4 years, 3 months ago (2016-09-22 19:33:56 UTC) #16
Avi (use Gerrit)
lgtm stampity stamp
4 years, 3 months ago (2016-09-22 19:41:05 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2343423003/100001
4 years, 3 months ago (2016-09-22 22:00:04 UTC) #24
commit-bot: I haz the power
Committed patchset #4 (id:100001)
4 years, 3 months ago (2016-09-22 22:07:03 UTC) #26
commit-bot: I haz the power
4 years, 3 months ago (2016-09-22 22:08:59 UTC) #28
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/71238feb8a373499b95a8b78572c81a456a37106
Cr-Commit-Position: refs/heads/master@{#420475}

Powered by Google App Engine
This is Rietveld 408576698