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

Landscape Left and Right Orientation Issue #255

Open
tikamsingh opened this issue Aug 6, 2021 · 5 comments
Open

Landscape Left and Right Orientation Issue #255

tikamsingh opened this issue Aug 6, 2021 · 5 comments

Comments

@tikamsingh
Copy link

Please help to support orientation perfectlly. I am getting issue in orientations

@daliborristic883
Copy link

I can see same issue.

@yangfan1233
Copy link

@daliborristic883 How to solve the issue?

@joopvanduin
Copy link

Same here the preview layer is halved and the view rotates.

Any solution?

@hiteshcmarix
Copy link

hiteshcmarix commented Jul 18, 2022

I am facing same issue but found the solution after so many days.
The main issue of the orientation is in the CameraManager.swift file (Custom or cocoapod file), and you have to do changes in this file.
If you are using cocoapod of the CameraManager then you have to unlock this file to do changes.
Here is the solution of the landscape left and landscape right orientation issue :

In CameraManager.swift file, there is one function named "_videoOrientation", you will see switch case of deviceOrientation and in
case .landscapeLeft: it will return .landscapeRight and also
case .landscapeRight: it will return .landscapeLeft

So, the issue is here, you need to do below changes in those cases, and the changes are :
case .landscapeLeft:
return .landscapeLeft
case .landscapeRight:
return .landscapeRight

after you done with changes, you will check the orientation issue is fixed.

Guys, hope you will get the solution from this. 👍
Happy coding.. 😊

@manuels-bts
Copy link

Thanks @hiteshcmarix !

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

6 participants