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

Unified Diff: media/capture/video/video_capture_device.h

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: unittests 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 side-by-side diff with in-line comments
Download patch
Index: media/capture/video/video_capture_device.h
diff --git a/media/capture/video/video_capture_device.h b/media/capture/video/video_capture_device.h
index ed40a9a178be281e6757b0398bca7cc6e2e5a761..7a1f9cdeb89321ede10d57899ad009df93bb8ed1 100644
--- a/media/capture/video/video_capture_device.h
+++ b/media/capture/video/video_capture_device.h
@@ -299,6 +299,14 @@ class MEDIA_EXPORT VideoCaptureDevice {
// happens first.
virtual void StopAndDeAllocate() = 0;
+ // Asynchronously takes a photo, possibly reconfiguring the capture objects
+ // and/or interrupting the capture flow. Returns false if taking the picture
+ // could not be scheduled at all, or else runs |photo_callback| (on the thread
+ // where TakePhoto() is run).
+ using TakePhotoCallback =
+ base::Callback<void(const std::string&, std::unique_ptr<std::string>)>;
+ virtual bool TakePhoto(const TakePhotoCallback& photo_callback);
miu 2016/05/04 23:45:50 Consider adding WARN_UNUSED_RESULT (just before th
mcasas 2016/05/05 00:57:12 Done.
+
// Gets the power line frequency, either from the params if specified by the
// user or from the current system time zone.
PowerLineFrequency GetPowerLineFrequency(

Powered by Google App Engine
This is Rietveld 408576698