-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathUUCameraView.h
More file actions
46 lines (32 loc) · 1.04 KB
/
UUCameraView.h
File metadata and controls
46 lines (32 loc) · 1.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
//
// UUCameraView.h
// Useful Utilities - UUCameraView custom camera drop in view
//
// License:
// You are free to use this code for whatever purposes you desire. The only requirement is that you smile everytime you use it.
//
// Contact: @cheesemaker or jon@threejacks.com
#import <UIKit/UIKit.h>
#import <UIKit/UIKit.h>
#import <AVFoundation/AVFoundation.h>
#define kUUFlashOff 0
#define kUUFlashOn 1
#define kUUFlashAuto 2
@protocol UUCameraDelegate
@optional
- (void) photoReady:(NSDate*)imageData;
@end
@interface UUCameraView : UIView<AVCaptureVideoDataOutputSampleBufferDelegate>
- (void) startSession;
- (void) stopSession;
- (void) setFocusPoint:(CGPoint)focalPoint;
- (void) setZoomValue:(CGFloat)zoom;
- (void) setToBackFacingCamera;
- (void) setToFrontFacingCamera;
- (void) takePicture;
- (void) setCameraFrame:(CGRect)frame;
- (void) setCameraOrientation:(UIInterfaceOrientation)orientation;
@property (assign) bool torchOn;
@property (assign) int flashMode;
@property (nonatomic, assign) NSObject<UUCameraDelegate>* delegate;
@end