OLD | NEW |
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 #import "media/base/mac/avfoundation_glue.h" | 5 #import "media/base/mac/avfoundation_glue.h" |
6 | 6 |
7 #import <AVFoundation/AVFoundation.h> | 7 #import <AVFoundation/AVFoundation.h> |
8 #include <dlfcn.h> | 8 #include <dlfcn.h> |
9 #include <stddef.h> | 9 #include <stddef.h> |
10 | 10 |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
160 } | 160 } |
161 | 161 |
162 Class AVFoundationGlue::AVCaptureSessionClass() { | 162 Class AVFoundationGlue::AVCaptureSessionClass() { |
163 return [AVFoundationBundle() classNamed:@"AVCaptureSession"]; | 163 return [AVFoundationBundle() classNamed:@"AVCaptureSession"]; |
164 } | 164 } |
165 | 165 |
166 Class AVFoundationGlue::AVCaptureVideoDataOutputClass() { | 166 Class AVFoundationGlue::AVCaptureVideoDataOutputClass() { |
167 return [AVFoundationBundle() classNamed:@"AVCaptureVideoDataOutput"]; | 167 return [AVFoundationBundle() classNamed:@"AVCaptureVideoDataOutput"]; |
168 } | 168 } |
169 | 169 |
170 Class AVFoundationGlue::AVCaptureStillImageOutputClass() { | |
171 return [AVFoundationBundle() classNamed:@"AVCaptureStillImageOutput"]; | |
172 } | |
173 | |
174 @implementation AVCaptureDeviceGlue | 170 @implementation AVCaptureDeviceGlue |
175 | 171 |
176 + (NSArray*)devices { | 172 + (NSArray*)devices { |
177 Class avcClass = | 173 Class avcClass = |
178 [AVFoundationGlue::AVFoundationBundle() classNamed:@"AVCaptureDevice"]; | 174 [AVFoundationGlue::AVFoundationBundle() classNamed:@"AVCaptureDevice"]; |
179 if ([avcClass respondsToSelector:@selector(devices)]) { | 175 if ([avcClass respondsToSelector:@selector(devices)]) { |
180 return [avcClass performSelector:@selector(devices)]; | 176 return [avcClass performSelector:@selector(devices)]; |
181 } | 177 } |
182 return nil; | 178 return nil; |
183 } | 179 } |
(...skipping 10 matching lines...) Expand all Loading... |
194 @implementation AVCaptureDeviceInputGlue | 190 @implementation AVCaptureDeviceInputGlue |
195 | 191 |
196 + (CrAVCaptureDeviceInput*)deviceInputWithDevice:(CrAVCaptureDevice*)device | 192 + (CrAVCaptureDeviceInput*)deviceInputWithDevice:(CrAVCaptureDevice*)device |
197 error:(NSError**)outError { | 193 error:(NSError**)outError { |
198 return [[AVFoundationGlue::AVFoundationBundle() | 194 return [[AVFoundationGlue::AVFoundationBundle() |
199 classNamed:@"AVCaptureDeviceInput"] deviceInputWithDevice:device | 195 classNamed:@"AVCaptureDeviceInput"] deviceInputWithDevice:device |
200 error:outError]; | 196 error:outError]; |
201 } | 197 } |
202 | 198 |
203 @end // @implementation AVCaptureDeviceInputGlue | 199 @end // @implementation AVCaptureDeviceInputGlue |
OLD | NEW |