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

Viewports are misplaced when using Vulkan on Android #487

Open
2 of 6 tasks
Schmerique opened this issue Dec 15, 2024 · 0 comments
Open
2 of 6 tasks

Viewports are misplaced when using Vulkan on Android #487

Schmerique opened this issue Dec 15, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@Schmerique
Copy link

Schmerique commented Dec 15, 2024

SPECIFIC ISSUE ENCOUNTERED

When using a viewer profile that uses top or bottom as the screen vertical alignment type, the viewports are displayed from the opposite edge when using Vulkan. So if your viewer profile says the tray to lens distance is 18mm from the bottom edge, it's instead drawn 18mm from the top.

SMARTPHONE:

  • Device: Google Pixel 9 Pro XL
  • OS
    • Android
    • iOS
  • OS version: 15

STEPS TO REPRODUCE THE ISSUE

  1. Follow the instructions on https://developers.google.com/cardboard/develop/unity/quickstart for setting up a blank project, skipping the iOS part (I chose Android API Level 34 as Target API Level because the build would finish with an error, when using the suggested API Level)
  2. Choose Vulkan as the Graphics API
  3. Build and run the project

EXPECTED BEHAVIOR

The viewports are placed as they should, according to the Cardboard Viewer Profile

VERSIONS USED

Google Cardboard XR Plugin for Unity v1.27.0, also present in v1.26.0
Unity 6000.0.26f1.8540.1615

  • Select in which graphics API you can reproduce the bug.
    • OpenGL ES2
    • OpenGL ES3
    • Metal
    • Vulkan

LINK TO A REPOSITORY WITH CODE TO REPRODUCE THE BUG

https://github.com/Schmerique/unity-cardboard-xr-plugin-placement-bug.git

SCREENSHOTS

Viewer Profile Settings and the resulting QR code

viewer_profile_settings
qr_viewer_profile

Placement the Viewer Profile Generator's live preview shows

viewer_profile_generator_preview

Result on a Pixel 9 Pro XL

result_vulkan
result_opengles3

@Schmerique Schmerique added the bug Something isn't working label Dec 15, 2024
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

No branches or pull requests

1 participant