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

Side by Side Diff: media/capture/video/video_capture_device.cc

Issue 1952463002: Media Stream Image Capture (4): wire takePhoto and implement in FakeVCDevice (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: forgotten "!" and rebase Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "media/capture/video/video_capture_device.h" 5 #include "media/capture/video/video_capture_device.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/i18n/timezone.h" 8 #include "base/i18n/timezone.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 } 134 }
135 } 135 }
136 #endif 136 #endif
137 137
138 VideoCaptureDevice::Client::Buffer::~Buffer() { 138 VideoCaptureDevice::Client::Buffer::~Buffer() {
139 } 139 }
140 140
141 VideoCaptureDevice::~VideoCaptureDevice() { 141 VideoCaptureDevice::~VideoCaptureDevice() {
142 } 142 }
143 143
144 bool VideoCaptureDevice::TakePhoto(
145 const TakePhotoCallback& /* photo_callback */) {
tommi (sloooow) - chröme 2016/05/09 11:17:33 since we generally don't use /* */ comment style,
mcasas 2016/05/09 16:48:41 Done.
146 NOTIMPLEMENTED();
147 return false;
148 }
149
144 PowerLineFrequency VideoCaptureDevice::GetPowerLineFrequencyForLocation() 150 PowerLineFrequency VideoCaptureDevice::GetPowerLineFrequencyForLocation()
145 const { 151 const {
146 const std::string current_country = base::CountryCodeForCurrentTimezone(); 152 const std::string current_country = base::CountryCodeForCurrentTimezone();
147 if (current_country.empty()) 153 if (current_country.empty())
148 return PowerLineFrequency::FREQUENCY_DEFAULT; 154 return PowerLineFrequency::FREQUENCY_DEFAULT;
149 // Sorted out list of countries with 60Hz power line frequency, from 155 // Sorted out list of countries with 60Hz power line frequency, from
150 // http://en.wikipedia.org/wiki/Mains_electricity_by_country 156 // http://en.wikipedia.org/wiki/Mains_electricity_by_country
151 const char* countries_using_60Hz[] = { 157 const char* countries_using_60Hz[] = {
152 "AI", "AO", "AS", "AW", "AZ", "BM", "BR", "BS", "BZ", "CA", "CO", 158 "AI", "AO", "AS", "AW", "AZ", "BM", "BR", "BS", "BZ", "CA", "CO",
153 "CR", "CU", "DO", "EC", "FM", "GT", "GU", "GY", "HN", "HT", "JP", 159 "CR", "CU", "DO", "EC", "FM", "GT", "GU", "GY", "HN", "HT", "JP",
(...skipping 13 matching lines...) Expand all
167 switch (params.power_line_frequency) { 173 switch (params.power_line_frequency) {
168 case media::PowerLineFrequency::FREQUENCY_50HZ: // fall through 174 case media::PowerLineFrequency::FREQUENCY_50HZ: // fall through
169 case media::PowerLineFrequency::FREQUENCY_60HZ: 175 case media::PowerLineFrequency::FREQUENCY_60HZ:
170 return params.power_line_frequency; 176 return params.power_line_frequency;
171 default: 177 default:
172 return GetPowerLineFrequencyForLocation(); 178 return GetPowerLineFrequencyForLocation();
173 } 179 }
174 } 180 }
175 181
176 } // namespace media 182 } // namespace media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698