You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-07 12:30:27 +00:00
OpenXR: Make it possible to implement vendor extensions to hand tracking from GDExtension
This commit is contained in:
@@ -38,6 +38,7 @@ void OpenXRExtensionWrapperExtension::_bind_methods() {
|
||||
GDVIRTUAL_BIND(_set_instance_create_info_and_get_next_pointer, "next_pointer");
|
||||
GDVIRTUAL_BIND(_set_session_create_and_get_next_pointer, "next_pointer");
|
||||
GDVIRTUAL_BIND(_set_swapchain_create_info_and_get_next_pointer, "next_pointer");
|
||||
GDVIRTUAL_BIND(_set_hand_joint_locations_and_get_next_pointer, "hand_index", "next_pointer");
|
||||
GDVIRTUAL_BIND(_on_register_metadata);
|
||||
GDVIRTUAL_BIND(_on_before_instance_created);
|
||||
GDVIRTUAL_BIND(_on_instance_created, "instance");
|
||||
@@ -117,6 +118,16 @@ void *OpenXRExtensionWrapperExtension::set_swapchain_create_info_and_get_next_po
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void *OpenXRExtensionWrapperExtension::set_hand_joint_locations_and_get_next_pointer(int p_hand_index, void *p_next_pointer) {
|
||||
uint64_t pointer;
|
||||
|
||||
if (GDVIRTUAL_CALL(_set_hand_joint_locations_and_get_next_pointer, p_hand_index, GDExtensionPtr<void>(p_next_pointer), pointer)) {
|
||||
return reinterpret_cast<void *>(pointer);
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void OpenXRExtensionWrapperExtension::on_register_metadata() {
|
||||
GDVIRTUAL_CALL(_on_register_metadata);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user