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

🐛 Orientation is always 0 #793

Closed
3 of 4 tasks
vvusts opened this issue Feb 2, 2022 · 5 comments · Fixed by #1466
Closed
3 of 4 tasks

🐛 Orientation is always 0 #793

vvusts opened this issue Feb 2, 2022 · 5 comments · Fixed by #1466
Labels
🐛 bug Something isn't working

Comments

@vvusts
Copy link

vvusts commented Feb 2, 2022

What were you trying to do?

Tested on android 8 device (huawei p10 Lite).
I tried to take photos in portrait or landscape but in response object
metadata.Orientation is always zero.
Reason for this is if user take photo in landscape we check orientation and based on that set different UI elements.
Or we need to make sure that photo is taken in desired orientation.

Reproduceable Code

<Camera
        ref={camera}
        style={{position: 'absolute', top: 0, left: 0, bottom: 0, right: 0}}
        device={device}
        isActive={isCameraActive}
        photo={true}
/>

What happened instead?

metadata.Orientatio is always 0

Relevant log output

No response

Device

huawei p10 lite

VisionCamera Version

2.12.0

Additional information

@vvusts vvusts added the 🐛 bug Something isn't working label Feb 2, 2022
@mrousavy
Copy link
Owner

mrousavy commented Feb 2, 2022

Does this work on an iPhone?

@vvusts
Copy link
Author

vvusts commented Feb 2, 2022

I will test and inform you as soon as possible.

@vvusts
Copy link
Author

vvusts commented Feb 2, 2022

Probably will not test soon I am having some:
/Users/.../.../.../ios/Pods/Headers/Public/ReactCommon/ReactCommon/TurboModuleUtils.h:13:10: 'folly/Optional.h' file not found
Issue and can't build for ios.

@mrousavy
Copy link
Owner

Hey! I've rewritten the entire Android codebase of VisionCamera from CameraX to Camera2 in the efforts of ✨ VisionCamera V3.

I just now completed the Camera2 rewrite and I believe the core structure is running, but there might be some edge cases to iron out. Can you try and test the PR #1674 for me to see if you can still reproduce this issue here?

Here's an instruction on how you can test that: #1674 (comment)

If the issue cannot be reproduced with that version/PR anymore, then hoorayy, I fixed it! 🎉
Otherwise please let me know and I'll keep this issue open to keep track of it.

Thank you!

@mrousavy
Copy link
Owner

Hey - I'm tracking Orientation in this feature request/issue now: #1891

Make sure to upvote or sponsor to support this feature, and leave a comment if you have any additional thoughts/ideas.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants