提交 d1492eef 编写于 作者: A Alexander Alekhin

Merge pull request #7181 from valeriyvan:ioscleanup

......@@ -41,27 +41,9 @@
@interface CvAbstractCamera : NSObject
{
AVCaptureSession* captureSession;
AVCaptureConnection* videoCaptureConnection;
AVCaptureVideoPreviewLayer *captureVideoPreviewLayer;
UIDeviceOrientation currentDeviceOrientation;
BOOL cameraAvailable;
BOOL captureSessionLoaded;
BOOL running;
BOOL useAVCaptureVideoPreviewLayer;
AVCaptureDevicePosition defaultAVCaptureDevicePosition;
AVCaptureVideoOrientation defaultAVCaptureVideoOrientation;
NSString *const defaultAVCaptureSessionPreset;
int defaultFPS;
UIView* parentView;
int imageWidth;
int imageHeight;
}
@property (nonatomic, strong) AVCaptureSession* captureSession;
......@@ -121,14 +103,6 @@
dispatch_queue_t videoDataOutputQueue;
CALayer *customPreviewLayer;
BOOL grayscaleMode;
BOOL recordVideo;
BOOL rotateVideo;
AVAssetWriterInput* recordAssetWriterInput;
AVAssetWriterInputPixelBufferAdaptor* recordPixelBufferAdaptor;
AVAssetWriter* recordAssetWriter;
CMTime lastSampleTime;
}
......
......@@ -190,7 +190,7 @@ static CGFloat DegreesToRadians(CGFloat degrees) {return degrees * M_PI / 180;}
break; // leave the layer in its last known orientation
}
switch (defaultAVCaptureVideoOrientation) {
switch (self.defaultAVCaptureVideoOrientation) {
case AVCaptureVideoOrientationLandscapeRight:
rotation_angle += 180;
break;
......@@ -256,7 +256,7 @@ static CGFloat DegreesToRadians(CGFloat degrees) {return degrees * M_PI / 180;}
break; // leave the layer in its last known orientation
}
switch (defaultAVCaptureVideoOrientation) {
switch (self.defaultAVCaptureVideoOrientation) {
case AVCaptureVideoOrientationLandscapeRight:
rotation_angle += 180;
break;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册