Skip to content

Rename OpenXRInterface.OpenXrSessionState to OpenXRInterface.SessionState #107710

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

Merged

Conversation

dsnopek
Copy link
Contributor

@dsnopek dsnopek commented Jun 19, 2025

This is a follow-up to #107619 which was merged before we finished debating the name of this enum :-)

I'm not a fan of the existing name for a few reasons:

  1. It uses a lower-case r in OpenXr, which we don't use anywhere else (except in the C# version of some things that are called OpenXR* on the C++ and GDScript side)
  2. It's redundant - we don't need to say "OpenXR" again, because this is part of OpenXRInterface
  3. It's inconsistent with the rest of the enums on OpenXRInterface, some of which also mirror enums from the OpenXR API (for example, OpenXRInterface.HandTrackedSource), but none of the other enums include the OpenXR* prefix

Perhaps if we started with this convention originally it could make sense, but adding this now doesn't fit in with what we already have

Copy link
Member

@Mickeon Mickeon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For clarity, I removed the documentation label as the changes to the docs are merely a consequence of the enum being changed.

Either way, I do approve the names being less redundant.

Copy link
Member

@akien-mga akien-mga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me. Maybe you can add the doc nitpicks from #107619 which were also missed before merging?

@dsnopek dsnopek force-pushed the openxr-interface-rename-session-state branch from 2a0e223 to 00f30b4 Compare June 19, 2025 15:24
@dsnopek
Copy link
Contributor Author

dsnopek commented Jun 19, 2025

Maybe you can add the doc nitpicks from #107619 which were also missed before merging?

Sure! In my latest push, I've fixed the remaining docs notes from @AThousandShips on #107619

Copy link
Contributor

@devloglogan devloglogan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing gained with the redundant naming, LGTM! 🙂

@BastiaanOlij
Copy link
Contributor

As the one introducing the redundant naming, it was an attempt to set apart enums that are ours, and those we mirror from the OpenXR spec.

But since we haven't done so consistently, and there isn't much value in it one way or the other, it's not a hill I'm willing to die on.

Seeing most seem happy with just leaving the prefix out, I'm happy for this to be merged and I'll make similar changes to the spatial entities PR as suggested by David.

@Repiteo Repiteo merged commit 48f361a into godotengine:master Jun 20, 2025
20 checks passed
@Repiteo
Copy link
Contributor

Repiteo commented Jun 20, 2025

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants