sceneform-android icon indicating copy to clipboard operation
sceneform-android copied to clipboard

how to get a image in portrait mode

Open Maplelw opened this issue 1 year ago • 1 comments

I use arFragment.getArSceneView().getArFrame() to get a frame and save the image. However, I use my phone in portrait mode, but image is in landscape mode, it seems rotate.

Maplelw avatar Apr 16 '24 07:04 Maplelw

If I remember correctly, the frame/image will match whatever the hardware camera sensor orientation is. On Android devices, this could be portrait or landscape depending. So it's up to the developer to figure out which way is up and rotate it or not.

Someone suggested using a different method here: https://stackoverflow.com/questions/52873233/arcore-image-from-arfragment-is-different-from-the-fragments-display So that might be worth looking at.

Mehequanna avatar Jun 25 '24 23:06 Mehequanna