Closed BastiaanOlij closed 6 months ago
From the XR meeting on 01/11, the decision was made to only unify the GDExtension library used for the editor. Since that version only includes stubs which are used by developers in the editor to augment their game logic, there should not be any risk of vendor specific dependencies conflicts.
The current logic already generates separate GDExtension libraries, a set specific to a vendor platform that's used during export, and another set that's used by the editor. As such, the logic to generate the editor set needs to be updated to generate a single GDExtension library instead of one per vendor as is being done now.
This has been discussed before but I'm raising it here so we can document the discussion and come to a consensus.
Right now we're creating a GDExtension per vendor. The problem with this approach is that any API that is adopted by multiple vendors, needs to be duplicated. From a deployment POV this is not a big issue, but from an IDE POV, where we need to register each extension class in order to actually develop against these extension classes, we'll end up registering the same class multiple times.
Combining them into a single GDExtension library that is deployed to all platforms also ensures that vendors that adopt other vendor APIs in the future automatically gain support from Godot.
Finally this also opens the door to including the vendor GDExtension for non Android platforms as also PCVR runtimes may implement various vendor extensions, including those of other vendors.
Unsupported extensions are already filtered out by OpenXR checking for available extensions, and while each Android platform registers a new export plugin, these are uniquely named.
This does mean rejigging our folder structure so the GDExtension source is separately compiled, but the same Android binaries can then be included in the AAR for each Android platform.