Unity-Technologies / arfoundation-samples

Example content for Unity projects based on AR Foundation
Other
3.07k stars 1.15k forks source link

[Bug] Camera feed is upside down #589

Closed angecroft closed 4 years ago

angecroft commented 4 years ago

Unity bug report case number 1273490

Describe the bug The camera is upside down when switching orientation from landscape left to landscape right directly or from portrait to portrait upside down.

To Reproduce Steps to reproduce the behavior:

  1. Create an AR project or start from the ARFoundation sample project

  2. Set the default orientation to Portrait in Project Settings

  3. Add the following code in Awake() or Start() of any script

    Screen.orientation = ScreenOrientation.AutoRotation;
    Screen.autorotateToLandscapeLeft = true;
    Screen.autorotateToLandscapeRight = true;
    Screen.autorotateToPortraitUpsideDown = true;
  4. Build and launch the app on the device

  5. Switch orientation from landscape left to landscape right directly or from portrait to portrait upside down quickly.

  6. See that the camera is upside down

Expected behavior The camera should update it's orientation like the rest of the app (the UI does)

Actual behavior The camera is upside down when switching orientation from landscape left to landscape right directly or from portrait to portrait upside down.

Smartphone (please complete the following information):

mdurand42 commented 4 years ago

This is a bug in non-AR code as we have reproduced this without AR Foundation and associated packages. We have opened a bug internally for the mobile team to investigate.

tdmowrer commented 4 years ago

You can track the issue here.

angecroft commented 4 years ago

Thank you for the update