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

OpenXR: Add support for retrieving play area #85163

Merged
merged 1 commit into from
Dec 16, 2023

Conversation

BastiaanOlij
Copy link
Contributor

@BastiaanOlij BastiaanOlij commented Nov 21, 2023

This PR implements the get_play_area feature on OpenXRInterface. This allows the user to retrieve the are within which they can safely move before encountering the guardian boundary.

This re-introduces the get_play_space feature in Godot 3s OpenXR support.

Closes: #85049

@BastiaanOlij BastiaanOlij added this to the 4.3 milestone Nov 21, 2023
@BastiaanOlij BastiaanOlij self-assigned this Nov 21, 2023
modules/openxr/openxr_interface.cpp Outdated Show resolved Hide resolved
@@ -690,6 +690,47 @@ bool OpenXRInterface::set_play_area_mode(XRInterface::PlayAreaMode p_mode) {
return false;
}

PackedVector3Array OpenXRInterface::get_play_area() const {
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this be exposed to gdscript?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It is through the XRInterface, it's a virtual method

Copy link
Member

@AThousandShips AThousandShips left a comment

Choose a reason for hiding this comment

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

Looks good otherwise for style

modules/openxr/openxr_interface.cpp Outdated Show resolved Hide resolved
modules/openxr/openxr_interface.cpp Outdated Show resolved Hide resolved
modules/openxr/openxr_api.cpp Outdated Show resolved Hide resolved
modules/openxr/openxr_interface.cpp Outdated Show resolved Hide resolved
modules/openxr/openxr_interface.cpp Outdated Show resolved Hide resolved
@YuriSizov YuriSizov merged commit abe1949 into godotengine:master Dec 16, 2023
15 checks passed
@YuriSizov
Copy link
Contributor

Thanks!

@BastiaanOlij BastiaanOlij deleted the openxr_play_area branch July 10, 2024 09:45
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.

OpenXR missing Boundary/Guardian API
4 participants