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

Side by Side Diff: media/video/capture/mac/video_capture_device_mac_qtkit.h

Issue 8177008: Adding VideoCaptureDevice for Mac. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 9 years, 2 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
(Empty)
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // VideoCaptureDeviceMacQTKit implements all QTKit related code for
6 // communicating with a QTKit capture device.
7
8 #ifndef MEDIA_VIDEO_CAPTURE_MAC_VIDEO_CAPTURE_DEVICE_MAC_QTKIT_H_
9 #define MEDIA_VIDEO_CAPTURE_MAC_VIDEO_CAPTURE_DEVICE_MAC_QTKIT_H_
10
dmac 2011/10/06 23:42:04 do you need all these imports, or can you forward
mflodman_chromium_OOO 2011/10/07 13:03:51 Done.
11 #import <QTKit/QTKit.h>
12
13 #include "media/video/capture/mac/video_capture_device_mac.h"
14 #include "media/video/capture/video_capture_device.h"
15
16 @interface VideoCaptureDeviceMacQTKit : NSObject{
dmac 2011/10/06 23:42:04 space between NSObject and {
mflodman_chromium_OOO 2011/10/07 13:03:51 Done.
17 @private
18 // Settings.
19 int frameRate_;
20 int frameWidth_;
21 int frameHeight_;
22
23 media::VideoCaptureDeviceMac* frameReceiver_;
24
25 // QTKit variables.
26 QTCaptureSession* captureSession_;
27 QTCaptureDeviceInput* captureDeviceInput_;
28 QTCaptureDecompressedVideoOutput* captureDecompressedOutput_;
29
30 NSAutoreleasePool* pool_;
31 }
32
33 // Gets available devices.
dmac 2011/10/06 23:42:04 Normally you would return an autoreleased NSArray.
mflodman_chromium_OOO 2011/10/07 13:03:51 Done. I'll also look at changing this one to remov
34 + (void)deviceNames:(NSArray*)deviceNames;
35
36 // Registers a receiver for the captured frames.
37 - (void)registerReceiver:(media::VideoCaptureDeviceMac*)frameReceiver;
38
39 // Sets which capture device to use. Returns YES on sucess, NO otherwise.
40 - (BOOL)setCaptureDevice:(const char*)name;
dmac 2011/10/06 23:42:04 why a const char* instaed of an NSString? Also, I
mflodman_chromium_OOO 2011/10/07 13:03:51 Changed to NSString*, nil will remove the device a
41
42 // Removes the set capture device.
43 - (void)removeCaptureDevice;
44
45 // Configures the capture properties.
46 - (BOOL)setCaptureHeight:(int)height
47 AndWidth:(int)width
dmac 2011/10/06 23:42:04 lowercase in objc param names, and we don't use "a
mflodman_chromium_OOO 2011/10/07 13:03:51 Changed. Not used to this, so I hope the change is
48 AndFrameRate:(int)frameRate;
49
50 // Start video capturing. Returns YES on sucess, NO otherwise.
51 - (BOOL)startCapture;
52
53 // Stops video capturing.
54 - (void)stopCapture;
55
56 @end
57
58 #endif // MEDIA_VIDEO_CAPTURE_MAC_VIDEO_CAPTURE_DEVICE_MAC_QTKIT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698