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

Unified Diff: media/capture/video/mac/video_capture_device_avfoundation_mac.mm

Issue 2595223003: Merge 56: Fix low frame rate problems in high resolution USB cameras using AVFoundation (Closed)
Patch Set: Created 4 years 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/capture/video/mac/video_capture_device_avfoundation_mac.mm
diff --git a/media/capture/video/mac/video_capture_device_avfoundation_mac.mm b/media/capture/video/mac/video_capture_device_avfoundation_mac.mm
index 623e9ef9bb50e0a4da5cdecae02689c8bd50cb4c..82549e3b40eeb455aa74891ccc7b22431703bd4b 100644
--- a/media/capture/video/mac/video_capture_device_avfoundation_mac.mm
+++ b/media/capture/video/mac/video_capture_device_avfoundation_mac.mm
@@ -266,6 +266,13 @@ void ExtractBaseAddressAndLength(
}
[captureSession_ addInput:captureDeviceInput_];
+ // Create and plug the still image capture output. This should happen in
+ // advance of the actual picture to allow for the 3A to stabilize.
+ stillImageOutput_.reset(
+ [[AVFoundationGlue::AVCaptureStillImageOutputClass() alloc] init]);
+ if (stillImageOutput_ && [captureSession_ canAddOutput:stillImageOutput_])
+ [captureSession_ addOutput:stillImageOutput_];
+
// Create a new data output for video. The data output is configured to
// discard late frames by default.
captureVideoDataOutput_.reset(
@@ -283,13 +290,6 @@ void ExtractBaseAddressAndLength(
DISPATCH_QUEUE_PRIORITY_DEFAULT, 0)];
[captureSession_ addOutput:captureVideoDataOutput_];
- // Create and plug the still image capture output. This should happen in
- // advance of the actual picture to allow for the 3A to stabilize.
- stillImageOutput_.reset(
- [[AVFoundationGlue::AVCaptureStillImageOutputClass() alloc] init]);
- if (stillImageOutput_ && [captureSession_ canAddOutput:stillImageOutput_])
- [captureSession_ addOutput:stillImageOutput_];
-
return YES;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698