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

Issue 649023002: Win Video Capture: Add device blacklisting, used for IPCamera and YouCam, collect UMA for those (Closed)

Created:
6 years, 2 months ago by mcasas
Modified:
6 years, 2 months ago
CC:
chromium-reviews, posciak+watch_chromium.org, feature-media-reviews_chromium.org, wjia+watch_chromium.org, mcasas+watch_chromium.org, asvitkine+watch_chromium.org, perkj_chrome
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Win Video Capture: Add device blacklisting, used for IPCamera and YouCam, collect UMA for those BUG=422048, 421991 Committed: https://crrev.com/db1ccf962f7785f4c37edfce00ac3f5d685522d7 Cr-Commit-Position: refs/heads/master@{#299558}

Patch Set 1 #

Total comments: 8

Patch Set 2 : Consolidated 'google camera adapter' into blacklist; other tommi@s comments #

Total comments: 3

Patch Set 3 : Removed VfW (Video For Windows) blacklisting. #

Total comments: 9

Patch Set 4 : asvitkine@ comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+55 lines, -13 lines) Patch
M media/video/capture/win/video_capture_device_factory_win.cc View 1 2 3 5 chunks +39 lines, -13 lines 0 comments Download
M tools/metrics/histograms/histograms.xml View 2 chunks +16 lines, -0 lines 0 comments Download

Messages

Total messages: 26 (7 generated)
mcasas
tommi@: video_capture_device_factory_win.cc asvitkine@: histograms.xml
6 years, 2 months ago (2014-10-11 21:10:22 UTC) #2
tommi (sloooow) - chröme
https://codereview.chromium.org/649023002/diff/1/media/video/capture/win/video_capture_device_factory_win.cc File media/video/capture/win/video_capture_device_factory_win.cc (right): https://codereview.chromium.org/649023002/diff/1/media/video/capture/win/video_capture_device_factory_win.cc#newcode51 media/video/capture/win/video_capture_device_factory_win.cc:51: {"IP Camera [JPEG/MJPEG]" }, nit: no space before } ...
6 years, 2 months ago (2014-10-12 09:46:03 UTC) #3
mcasas
guys PTAL https://codereview.chromium.org/649023002/diff/1/media/video/capture/win/video_capture_device_factory_win.cc File media/video/capture/win/video_capture_device_factory_win.cc (right): https://codereview.chromium.org/649023002/diff/1/media/video/capture/win/video_capture_device_factory_win.cc#newcode51 media/video/capture/win/video_capture_device_factory_win.cc:51: {"IP Camera [JPEG/MJPEG]" }, On 2014/10/12 09:46:03, ...
6 years, 2 months ago (2014-10-12 14:45:40 UTC) #4
tommi (sloooow) - chröme
+perkj fyi on the google camera adapter. https://codereview.chromium.org/649023002/diff/90001/media/video/capture/win/video_capture_device_factory_win.cc File media/video/capture/win/video_capture_device_factory_win.cc (right): https://codereview.chromium.org/649023002/diff/90001/media/video/capture/win/video_capture_device_factory_win.cc#newcode168 media/video/capture/win/video_capture_device_factory_win.cc:168: if (wcsstr(str_ptr, ...
6 years, 2 months ago (2014-10-13 10:32:01 UTC) #5
tommi (sloooow) - chröme
On 2014/10/13 10:32:01, tommi wrote: > +perkj fyi on the google camera adapter. > > ...
6 years, 2 months ago (2014-10-13 10:32:21 UTC) #6
perkj_chrome
lgtm https://codereview.chromium.org/649023002/diff/90001/media/video/capture/win/video_capture_device_factory_win.cc File media/video/capture/win/video_capture_device_factory_win.cc (right): https://codereview.chromium.org/649023002/diff/90001/media/video/capture/win/video_capture_device_factory_win.cc#newcode168 media/video/capture/win/video_capture_device_factory_win.cc:168: if (wcsstr(str_ptr, L"(VFW)") != NULL) On 2014/10/13 10:32:01, ...
6 years, 2 months ago (2014-10-13 10:46:40 UTC) #8
tommi (sloooow) - chröme
On 2014/10/13 10:46:40, perkj wrote: > lgtm > > https://codereview.chromium.org/649023002/diff/90001/media/video/capture/win/video_capture_device_factory_win.cc > File media/video/capture/win/video_capture_device_factory_win.cc (right): > ...
6 years, 2 months ago (2014-10-13 10:49:06 UTC) #9
mcasas
PTAL at the rationale, strong enough for me. https://codereview.chromium.org/649023002/diff/90001/media/video/capture/win/video_capture_device_factory_win.cc File media/video/capture/win/video_capture_device_factory_win.cc (right): https://codereview.chromium.org/649023002/diff/90001/media/video/capture/win/video_capture_device_factory_win.cc#newcode168 media/video/capture/win/video_capture_device_factory_win.cc:168: if ...
6 years, 2 months ago (2014-10-13 11:35:26 UTC) #10
perkj_chrome
fine by me.
6 years, 2 months ago (2014-10-13 14:43:43 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/649023002/200001
6 years, 2 months ago (2014-10-13 15:01:54 UTC) #13
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/17238)
6 years, 2 months ago (2014-10-13 15:09:04 UTC) #15
Alexei Svitkine (slow)
LGTM % comments, thanks! https://codereview.chromium.org/649023002/diff/200001/media/video/capture/win/video_capture_device_factory_win.cc File media/video/capture/win/video_capture_device_factory_win.cc (right): https://codereview.chromium.org/649023002/diff/200001/media/video/capture/win/video_capture_device_factory_win.cc#newcode34 media/video/capture/win/video_capture_device_factory_win.cc:34: enum BlacklistedCameraNames{ Nit: Space before ...
6 years, 2 months ago (2014-10-14 15:18:45 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/649023002/400001
6 years, 2 months ago (2014-10-14 15:42:50 UTC) #18
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_swarming on tryserver.chromium.win (http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_swarming/builds/21973)
6 years, 2 months ago (2014-10-14 17:56:20 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/649023002/400001
6 years, 2 months ago (2014-10-14 19:32:21 UTC) #22
commit-bot: I haz the power
Committed patchset #4 (id:400001)
6 years, 2 months ago (2014-10-14 21:40:41 UTC) #23
commit-bot: I haz the power
Patchset 4 (id:??) landed as https://crrev.com/db1ccf962f7785f4c37edfce00ac3f5d685522d7 Cr-Commit-Position: refs/heads/master@{#299558}
6 years, 2 months ago (2014-10-14 21:51:35 UTC) #24
mcasas
https://codereview.chromium.org/649023002/diff/200001/media/video/capture/win/video_capture_device_factory_win.cc File media/video/capture/win/video_capture_device_factory_win.cc (right): https://codereview.chromium.org/649023002/diff/200001/media/video/capture/win/video_capture_device_factory_win.cc#newcode34 media/video/capture/win/video_capture_device_factory_win.cc:34: enum BlacklistedCameraNames{ On 2014/10/14 15:18:45, Alexei Svitkine wrote: > ...
6 years, 2 months ago (2014-10-15 07:25:09 UTC) #25
Alexei Svitkine (slow)
6 years, 2 months ago (2014-10-15 14:00:51 UTC) #26
Message was sent while issue was closed.
https://codereview.chromium.org/649023002/diff/200001/media/video/capture/win...
File media/video/capture/win/video_capture_device_factory_win.cc (right):

https://codereview.chromium.org/649023002/diff/200001/media/video/capture/win...
media/video/capture/win/video_capture_device_factory_win.cc:121: i,
BLACKLISTED_CAMERA_MAX + 1);
On 2014/10/15 07:25:09, mcasas wrote:
> On 2014/10/14 15:18:45, Alexei Svitkine wrote:
> > Remove "+ 1" from the last param, since it's already 1 greater than the
> maximum
> > value of |i|.
> 
> Presubmit.py complained:
> 
> ** Presubmit ERRORS **
> UMA_HISTOGRAM_ENUMERATION reports in src/media/ are expected to adhere
> to the following guidelines:
>  - The max value (3rd argument) should be an enum value equal to the
>    last valid value, e.g. FOO_MAX = LAST_VALID_FOO.
>  - 1 must be added to that max value.
> Contact mailto:rileya@chromium.org if you have questions.
> 
> So I followed its instructions.

Sigh, it's because media code expects the MAX value to be the last value, not +1
from the last value.

So if you follow the presubmit, you'd want BLACKLISTED_CAMERA_MAX =
BLACKLISTED_CAMERA_CYBERLINK_WEBCAM_SPLITTER

I guess it doesn't matter either way - just results in an extra unused bucket
being allocated, but no effect on data sent.

(FWIW, I'm not a fan of the media/ code having a different convention than the
rest of Chromium, but I guess it's hard to change at this point. :\)
  38   BLACKLISTED_CAMERA_MAX

Powered by Google App Engine
This is Rietveld 408576698