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

Issue 974513002: content: Split out VideoCaptureMachine from DesktopCaptureDeviceAura (Closed)

Created:
5 years, 9 months ago by robert.bradford
Modified:
5 years, 9 months ago
Reviewers:
*Sergey Ulanov, *no sievers
CC:
chromium-reviews, darin-cc_chromium.org, feature-media-reviews_chromium.org, jam, miu+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

content: Split out VideoCaptureMachine from DesktopCaptureDeviceAura This refactoring would allow the creation of capturing devices without having a DesktopMediaID. This change pulls the DesktopVideoCaptureMachine class out from DesktopCaptureDeviceAura and renames it to AuraWindowCaptureMachine. The class is also refactored to take the target window (rather than a DesktopMediaID) after construction through a SetWindow method. BUG=425060 TEST=Using Chrome Cast beta extension and capture both screen and window and observe that the capture works correctly and that histogram values are updated. Committed: https://crrev.com/8a244ea4bd4547fa7481b548b6997f3412f6c215 Cr-Commit-Position: refs/heads/master@{#320953}

Patch Set 1 #

Total comments: 1

Patch Set 2 : Move from assigning window in ctor. to SetWindow() #

Patch Set 3 : Remove duplicated call to UpdateCaptureSize #

Patch Set 4 : Restore ctor. setting of desktop_window_ #

Patch Set 5 : Don't rely on desktop_window_ being valid in DidCopyOutput #

Patch Set 6 : Rename to AuraCaptureMachine and move to own file #

Total comments: 4

Patch Set 7 : Remove unnecessary use of WeakPtr & rebase on ToT #

Total comments: 8

Patch Set 8 : Move DesktopCaptureDeviceAura code to the correct place and move task posting into ctor. #

Total comments: 8

Patch Set 9 : Address review feedback. #

Patch Set 10 : Fix non-aura mac build #

Unified diffs Side-by-side diffs Delta from patch set Stats (+213 lines, -692 lines) Patch
M content/browser/BUILD.gn View 1 2 3 4 5 6 7 8 9 1 chunk +2 lines, -0 lines 0 comments Download
A content/browser/media/capture/aura_window_capture_machine.h View 1 2 3 4 5 6 1 chunk +128 lines, -0 lines 0 comments Download
A + content/browser/media/capture/aura_window_capture_machine.cc View 1 2 3 4 5 6 7 8 15 chunks +61 lines, -173 lines 0 comments Download
M content/browser/media/capture/desktop_capture_device_aura.h View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M content/browser/media/capture/desktop_capture_device_aura.cc View 1 2 3 4 5 6 7 8 2 chunks +13 lines, -516 lines 0 comments Download
M content/content_browser.gypi View 1 2 3 4 5 6 7 8 9 2 chunks +8 lines, -2 lines 0 comments Download

Messages

Total messages: 24 (9 generated)
robert.bradford
Hi Sergey, in follow-up to your comments on my virtual desktop capturing patch please can ...
5 years, 9 months ago (2015-03-02 18:47:05 UTC) #3
Sergey Ulanov
https://codereview.chromium.org/974513002/diff/1/content/browser/media/capture/desktop_capture_device_aura.cc File content/browser/media/capture/desktop_capture_device_aura.cc (right): https://codereview.chromium.org/974513002/diff/1/content/browser/media/capture/desktop_capture_device_aura.cc#newcode519 content/browser/media/capture/desktop_capture_device_aura.cc:519: aura::Window* window = content::DesktopMediaID::GetAuraWindowById(source); DesktopMediaID::GetAuraWindowById() is not thread-safe and ...
5 years, 9 months ago (2015-03-02 21:58:59 UTC) #4
robert.bradford
Hi Sergey, thanks for the review feedback. I've done as you've requested. In order to ...
5 years, 9 months ago (2015-03-03 17:21:09 UTC) #5
Sergey Ulanov
https://codereview.chromium.org/974513002/diff/100001/content/browser/media/capture/desktop_capture_device_aura.cc File content/browser/media/capture/desktop_capture_device_aura.cc (right): https://codereview.chromium.org/974513002/diff/100001/content/browser/media/capture/desktop_capture_device_aura.cc#newcode33 content/browser/media/capture/desktop_capture_device_aura.cc:33: device->AsWeakPtr(), source)); weak pointers are not thread-safe and shouldn't ...
5 years, 9 months ago (2015-03-04 01:54:03 UTC) #6
robert.bradford
Hi Sergey, thanks for the education wrt. WeakPtr. I've also rebased this patch on the ...
5 years, 9 months ago (2015-03-04 18:33:06 UTC) #7
Sergey Ulanov
https://codereview.chromium.org/974513002/diff/120001/content/browser/media/capture/aura_window_capture_machine.cc File content/browser/media/capture/aura_window_capture_machine.cc (right): https://codereview.chromium.org/974513002/diff/120001/content/browser/media/capture/aura_window_capture_machine.cc#newcode448 content/browser/media/capture/aura_window_capture_machine.cc:448: DesktopCaptureDeviceAura::DesktopCaptureDeviceAura() Move this to desktop_capture_device_aura.cc? https://codereview.chromium.org/974513002/diff/120001/content/browser/media/capture/aura_window_capture_machine.cc#newcode454 content/browser/media/capture/aura_window_capture_machine.cc:454: DesktopCaptureDeviceAura::~DesktopCaptureDeviceAura() { ...
5 years, 9 months ago (2015-03-04 18:48:59 UTC) #8
robert.bradford
Hi Sergey, thanks for the feedback, I also spotted that if I reordered the position ...
5 years, 9 months ago (2015-03-04 21:05:10 UTC) #12
Sergey Ulanov
https://codereview.chromium.org/974513002/diff/200001/content/browser/media/capture/aura_window_capture_machine.cc File content/browser/media/capture/aura_window_capture_machine.cc (right): https://codereview.chromium.org/974513002/diff/200001/content/browser/media/capture/aura_window_capture_machine.cc#newcode124 content/browser/media/capture/aura_window_capture_machine.cc:124: DCHECK(desktop_window_); window may be destroyed between SetWindow() and Start(). ...
5 years, 9 months ago (2015-03-04 22:07:42 UTC) #13
robert.bradford
Hi Sergey, updated the patch with your review feedback. Please take a look when you ...
5 years, 9 months ago (2015-03-05 18:12:11 UTC) #14
Sergey Ulanov
LGTM. Sorry about the delay.
5 years, 9 months ago (2015-03-16 19:42:32 UTC) #15
robert.bradford
Hi sievers@ can you review the changes in content/browser/BUILD.gn
5 years, 9 months ago (2015-03-17 18:51:41 UTC) #18
no sievers
lgtm
5 years, 9 months ago (2015-03-17 19:04:41 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/974513002/240001
5 years, 9 months ago (2015-03-17 19:06:39 UTC) #22
commit-bot: I haz the power
Committed patchset #10 (id:240001)
5 years, 9 months ago (2015-03-17 19:12:59 UTC) #23
commit-bot: I haz the power
5 years, 9 months ago (2015-03-17 19:13:52 UTC) #24
Message was sent while issue was closed.
Patchset 10 (id:??) landed as
https://crrev.com/8a244ea4bd4547fa7481b548b6997f3412f6c215
Cr-Commit-Position: refs/heads/master@{#320953}

Powered by Google App Engine
This is Rietveld 408576698