Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to camera orientate landscape? #26

Open
vominhtri1049 opened this issue Aug 3, 2017 · 3 comments
Open

How to camera orientate landscape? #26

vominhtri1049 opened this issue Aug 3, 2017 · 3 comments

Comments

@vominhtri1049
Copy link

Hi guy,
I did not found any CGECameraDevice properties to config camera landscape. Please help me.
Thanks.

@wysaid
Copy link
Owner

wysaid commented Aug 3, 2017

Maybe you should do that by yourself.

@vominhtri1049
Copy link
Author

vominhtri1049 commented Aug 3, 2017

glView = GLKView(frame: UIScreen.main.bounds)
cameraView = CGECameraViewHandler(glkView: glView)
        
if (cameraView?.setupCamera(AVCaptureSessionPreset1920x1080, cameraPosition: .back, isFrontCameraMirrored: false, authorizationFailed: { 
            print("Not allowed to open camera and microphone, please choose allow in the 'settings' page!!!")
}))! {
      cameraView?.cameraDevice().videoCaptureConnection().videoOrientation = .landscapeRight
      cameraView?.cameraDevice().startCameraCapture()
} else {
      print("The Camera Is Not Allowed!")
}

I do not know why it work wrong. Please explain me?

@wysaid
Copy link
Owner

wysaid commented Aug 3, 2017

I've not do the landscape orientation before. So you may need to find a way to do that🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants