2
0
Эх сурвалжийг харах

Introduce 'visionos' platform derived from 'apple_embedded'

Ricardo Sanchez-Saez 2 сар өмнө
parent
commit
47971c0a27
70 өөрчлөгдсөн 2633 нэмэгдсэн , 47 устгасан
  1. 1 1
      core/os/os.cpp
  2. 2 2
      doc/classes/EditorExportPlatformAppleEmbedded.xml
  3. 8 0
      doc/classes/ProjectSettings.xml
  4. 3 3
      drivers/SCsub
  5. 4 0
      drivers/apple_embedded/app_delegate_service.mm
  6. 4 1
      drivers/apple_embedded/display_server_apple_embedded.mm
  7. 8 0
      drivers/apple_embedded/godot_view_apple_embedded.mm
  8. 2 0
      drivers/apple_embedded/view_controller.mm
  9. 15 3
      drivers/metal/metal_device_properties.mm
  10. 6 0
      drivers/metal/pixel_formats.mm
  11. 8 0
      drivers/metal/rendering_device_driver_metal.mm
  12. 32 25
      editor/export/editor_export_platform_apple_embedded.cpp
  13. 3 0
      editor/export/editor_export_platform_apple_embedded.h
  14. 2 0
      editor/export/macho.h
  15. 2 0
      main/main.cpp
  16. 8 0
      methods.py
  17. 10 0
      misc/dist/visionos_xcode/PrivacyInfo.xcprivacy
  18. 0 0
      misc/dist/visionos_xcode/data.pck
  19. 402 0
      misc/dist/visionos_xcode/godot_visionos.xcodeproj/project.pbxproj
  20. 7 0
      misc/dist/visionos_xcode/godot_visionos.xcodeproj/project.xcworkspace/contents.xcworkspacedata
  21. 93 0
      misc/dist/visionos_xcode/godot_visionos.xcodeproj/xcshareddata/xcschemes/godot_visionos.xcscheme
  22. 22 0
      misc/dist/visionos_xcode/godot_visionos/Images.xcassets/SplashImage.imageset/Contents.json
  23. BIN
      misc/dist/visionos_xcode/godot_visionos/Images.xcassets/SplashImage.imageset/[email protected]
  24. BIN
      misc/dist/visionos_xcode/godot_visionos/Images.xcassets/SplashImage.imageset/[email protected]
  25. 31 0
      misc/dist/visionos_xcode/godot_visionos/dummy.cpp
  26. 33 0
      misc/dist/visionos_xcode/godot_visionos/dummy.h
  27. 31 0
      misc/dist/visionos_xcode/godot_visionos/dummy.swift
  28. 1 0
      misc/dist/visionos_xcode/godot_visionos/dylibs/empty
  29. 1 0
      misc/dist/visionos_xcode/godot_visionos/en.lproj/InfoPlist.strings
  30. 20 0
      misc/dist/visionos_xcode/godot_visionos/export_options.plist
  31. 63 0
      misc/dist/visionos_xcode/godot_visionos/godot_visionos-Info.plist
  32. 7 0
      misc/dist/visionos_xcode/godot_visionos/godot_visionos.entitlements
  33. 39 0
      misc/dist/visionos_xcode/libgodot.visionos.debug.xcframework/Info.plist
  34. 1 0
      misc/dist/visionos_xcode/libgodot.visionos.debug.xcframework/xros-arm64-simulator/empty
  35. 1 0
      misc/dist/visionos_xcode/libgodot.visionos.debug.xcframework/xros-arm64/empty
  36. 39 0
      misc/dist/visionos_xcode/libgodot.visionos.release.xcframework/Info.plist
  37. 1 0
      misc/dist/visionos_xcode/libgodot.visionos.release.xcframework/xros-arm64-simulator/empty
  38. 1 0
      misc/dist/visionos_xcode/libgodot.visionos.release.xcframework/xros-arm64/empty
  39. 1 1
      platform/ios/export/export_plugin.cpp
  40. 4 0
      platform/ios/export/export_plugin.h
  41. 20 0
      platform/visionos/README.md
  42. 29 0
      platform/visionos/SCsub
  43. 48 0
      platform/visionos/api/api.cpp
  44. 39 0
      platform/visionos/api/api.h
  45. 160 0
      platform/visionos/detect.py
  46. 36 0
      platform/visionos/display_layer_visionos.h
  47. 47 0
      platform/visionos/display_layer_visionos.mm
  48. 54 0
      platform/visionos/display_server_visionos.h
  49. 67 0
      platform/visionos/display_server_visionos.mm
  50. 588 0
      platform/visionos/doc_classes/EditorExportPlatformVisionOS.xml
  51. 46 0
      platform/visionos/export/export.cpp
  52. 34 0
      platform/visionos/export/export.h
  53. 51 0
      platform/visionos/export/export_plugin.cpp
  54. 59 0
      platform/visionos/export/export_plugin.h
  55. 0 0
      platform/visionos/export/logo.svg
  56. 1 0
      platform/visionos/export/run_icon.svg
  57. 37 0
      platform/visionos/godot_view_visionos.h
  58. 80 0
      platform/visionos/godot_view_visionos.mm
  59. 89 0
      platform/visionos/main_visionos.mm
  60. 47 0
      platform/visionos/os_visionos.h
  61. 52 0
      platform/visionos/os_visionos.mm
  62. 33 0
      platform/visionos/platform_config.h
  63. 33 0
      platform/visionos/platform_thread.h
  64. 7 0
      platform/visionos/platform_visionos_builders.py
  65. 37 0
      platform/visionos/visionos.h
  66. 2 2
      servers/rendering/renderer_rd/cluster_builder_rd.h
  67. 8 0
      servers/rendering/renderer_rd/effects/metal_fx.h
  68. 4 0
      servers/rendering/renderer_rd/effects/metal_fx.mm
  69. 6 6
      servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.cpp
  70. 3 3
      servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.h

+ 1 - 1
core/os/os.cpp

@@ -585,7 +585,7 @@ bool OS::has_feature(const String &p_feature) {
 	}
 #endif
 
-#if defined(IOS_SIMULATOR)
+#if defined(IOS_SIMULATOR) || defined(VISIONOS_SIMULATOR)
 	if (p_feature == "simulator") {
 		return true;
 	}

+ 2 - 2
doc/classes/EditorExportPlatformAppleEmbedded.xml

@@ -1,10 +1,10 @@
 <?xml version="1.0" encoding="UTF-8" ?>
 <class name="EditorExportPlatformAppleEmbedded" inherits="EditorExportPlatform" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
 	<brief_description>
-		Base class for the Apple embedded platform exporters (iOS).
+		Base class for the Apple embedded platform exporters (iOS and visionOS).
 	</brief_description>
 	<description>
-		The base class for Apple embedded platform exporters. These include iOS, but not macOS. See the classes inheriting from this one for more details.
+		The base class for Apple embedded platform exporters. These include iOS and visionOS, but not macOS. See the classes inheriting from this one for more details.
 	</description>
 	<tutorials>
 		<link title="Exporting for iOS">$DOCS_URL/tutorials/export/exporting_for_ios.html</link>

+ 8 - 0
doc/classes/ProjectSettings.xml

@@ -900,6 +900,9 @@
 		<member name="display/display_server/driver.macos" type="String" setter="" getter="">
 			MacOS override for [member display/display_server/driver].
 		</member>
+		<member name="display/display_server/driver.visionos" type="String" setter="" getter="">
+			visionOS override for [member display/display_server/driver].
+		</member>
 		<member name="display/display_server/driver.windows" type="String" setter="" getter="">
 			Windows override for [member display/display_server/driver].
 		</member>
@@ -3163,6 +3166,11 @@
 			- [code]metal[/code] (default), Metal from native drivers, only supported on Apple Silicon Macs. On Intel Macs, it will automatically fall back to [code]vulkan[/code] as Metal support is not implemented.
 			- [code]vulkan[/code], Vulkan over Metal via MoltenVK, supported on both Apple Silicon and Intel Macs.
 		</member>
+		<member name="rendering/rendering_device/driver.visionos" type="String" setter="" getter="" default="&quot;metal&quot;">
+			visionOS override for [member rendering/rendering_device/driver].
+			Only one option is supported:
+			- [code]metal[/code] (default), Metal from native drivers.
+		</member>
 		<member name="rendering/rendering_device/driver.windows" type="String" setter="" getter="" default="&quot;vulkan&quot;">
 			Windows override for [member rendering/rendering_device/driver].
 			Two options are supported:

+ 3 - 3
drivers/SCsub

@@ -26,10 +26,10 @@ if env["xaudio2"]:
     SConscript("xaudio2/SCsub")
 
 # Shared Apple platform drivers
-if env["platform"] in ["macos", "ios"]:
+if env["platform"] in ["macos", "ios", "visionos"]:
     SConscript("apple/SCsub")
     SConscript("coreaudio/SCsub")
-if env["platform"] in ["ios"]:
+if env["platform"] in ["ios", "visionos"]:
     SConscript("apple_embedded/SCsub")
 
 # Accessibility
@@ -38,7 +38,7 @@ if env["accesskit"] and env["platform"] in ["macos", "windows", "linuxbsd"]:
 
 # Midi drivers
 SConscript("alsamidi/SCsub")
-if env["platform"] in ["macos", "ios"]:
+if env["platform"] in ["macos"]:
     SConscript("coremidi/SCsub")
 SConscript("winmidi/SCsub")
 

+ 4 - 0
drivers/apple_embedded/app_delegate_service.mm

@@ -71,9 +71,13 @@ static GDTViewController *mainViewController = nil;
 	// TODO: logo screen is not displayed while shaders are compiling
 	// DummyViewController(Splash/LoadingViewController) -> setup -> GodotViewController
 
+#if !defined(VISIONOS_ENABLED)
 	// Create a full-screen window
 	CGRect windowBounds = [[UIScreen mainScreen] bounds];
 	self.window = [[UIWindow alloc] initWithFrame:windowBounds];
+#else
+	self.window = [[UIWindow alloc] init];
+#endif
 
 	int err = apple_embedded_main(gargc, gargv);
 

+ 4 - 1
drivers/apple_embedded/display_server_apple_embedded.mm

@@ -643,9 +643,12 @@ void DisplayServerAppleEmbedded::screen_set_orientation(DisplayServer::ScreenOri
 	screen_orientation = p_orientation;
 	if (@available(iOS 16.0, *)) {
 		[GDTAppDelegateService.viewController setNeedsUpdateOfSupportedInterfaceOrientations];
-	} else {
+	}
+#if !defined(VISIONOS_ENABLED)
+	else {
 		[UIViewController attemptRotationToDeviceOrientation];
 	}
+#endif
 }
 
 DisplayServer::ScreenOrientation DisplayServerAppleEmbedded::screen_get_orientation(int p_screen) const {

+ 8 - 0
drivers/apple_embedded/godot_view_apple_embedded.mm

@@ -117,7 +117,9 @@ static const float earth_gravity = 9.80665;
 }
 
 - (void)godot_commonInit {
+#if !defined(VISIONOS_ENABLED)
 	self.contentScaleFactor = [UIScreen mainScreen].scale;
+#endif
 
 	if (@available(iOS 17.0, *)) {
 		[self registerForTraitChanges:@[ [UITraitUserInterfaceStyle class] ] withTarget:self action:@selector(traitCollectionDidChangeWithView:previousTraitCollection:)];
@@ -148,7 +150,9 @@ static const float earth_gravity = 9.80665;
 
 - (void)traitCollectionDidChange:(UITraitCollection *)previousTraitCollection {
 	if (@available(iOS 13.0, *)) {
+#if !defined(VISIONOS_ENABLED)
 		[super traitCollectionDidChange:previousTraitCollection];
+#endif
 		[self traitCollectionDidChangeWithView:self
 					   previousTraitCollection:previousTraitCollection];
 	}
@@ -419,6 +423,7 @@ static const float earth_gravity = 9.80665;
 
 	UIInterfaceOrientation interfaceOrientation = UIInterfaceOrientationUnknown;
 
+#if !defined(VISIONOS_ENABLED)
 #if __IPHONE_OS_VERSION_MAX_ALLOWED < 140000
 	interfaceOrientation = [[UIApplication sharedApplication] statusBarOrientation];
 #else
@@ -430,6 +435,9 @@ static const float earth_gravity = 9.80665;
 #endif
 	}
 #endif
+#else
+	interfaceOrientation = [UIApplication sharedApplication].delegate.window.windowScene.interfaceOrientation;
+#endif
 
 	switch (interfaceOrientation) {
 		case UIInterfaceOrientationLandscapeLeft: {

+ 2 - 0
drivers/apple_embedded/view_controller.mm

@@ -187,6 +187,7 @@
 }
 
 - (void)displayLoadingOverlay {
+#if !defined(VISIONOS_ENABLED)
 	NSBundle *bundle = [NSBundle mainBundle];
 	NSString *storyboardName = @"Launch Screen";
 
@@ -202,6 +203,7 @@
 	self.godotLoadingOverlay.autoresizingMask = UIViewAutoresizingFlexibleHeight | UIViewAutoresizingFlexibleWidth;
 
 	[self.view addSubview:self.godotLoadingOverlay];
+#endif
 }
 
 - (BOOL)godotViewFinishedSetup:(GDTView *)view {

+ 15 - 3
drivers/metal/metal_device_properties.mm

@@ -50,6 +50,8 @@
 
 #import "metal_device_properties.h"
 
+#include "servers/rendering/renderer_rd/effects/metal_fx.h"
+
 #import <Metal/Metal.h>
 #import <MetalFX/MetalFX.h>
 #import <spirv_cross.hpp>
@@ -63,7 +65,7 @@
 #define MTLGPUFamilyApple9 (MTLGPUFamily)1009
 #endif
 
-API_AVAILABLE(macos(11.0), ios(14.0), tvos(14.0))
+API_AVAILABLE(macos(11.0), ios(14.0), tvos(14.0), visionos(1.0))
 MTLGPUFamily &operator--(MTLGPUFamily &p_family) {
 	p_family = static_cast<MTLGPUFamily>(static_cast<int>(p_family) - 1);
 	if (p_family < MTLGPUFamilyApple1) {
@@ -126,7 +128,11 @@ void MetalDeviceProperties::init_features(id<MTLDevice> p_device) {
 
 	if (@available(macOS 13.0, iOS 16.0, tvOS 16.0, *)) {
 		features.metal_fx_spatial = [MTLFXSpatialScalerDescriptor supportsDevice:p_device];
+#ifdef METAL_MFXTEMPORAL_ENABLED
 		features.metal_fx_temporal = [MTLFXTemporalScalerDescriptor supportsDevice:p_device];
+#else
+		features.metal_fx_temporal = false;
+#endif
 	}
 
 	MTLCompileOptions *opts = [MTLCompileOptions new];
@@ -136,7 +142,7 @@ void MetalDeviceProperties::init_features(id<MTLDevice> p_device) {
 	features.mslVersion = SPIRV_CROSS_NAMESPACE::CompilerMSL::Options::make_msl_version(m_maj, m_min)
 
 	switch (features.mslVersionEnum) {
-#if __MAC_OS_X_VERSION_MAX_ALLOWED >= 150000 || __IPHONE_OS_VERSION_MAX_ALLOWED >= 180000 || __TV_OS_VERSION_MAX_ALLOWED >= 180000
+#if __MAC_OS_X_VERSION_MAX_ALLOWED >= 150000 || __IPHONE_OS_VERSION_MAX_ALLOWED >= 180000 || __TV_OS_VERSION_MAX_ALLOWED >= 180000 || __VISION_OS_VERSION_MAX_ALLOWED >= 20000
 		case MTLLanguageVersion3_2:
 			setMSLVersion(3, 2);
 			break;
@@ -170,7 +176,7 @@ void MetalDeviceProperties::init_features(id<MTLDevice> p_device) {
 		case MTLLanguageVersion1_1:
 			setMSLVersion(1, 1);
 			break;
-#if TARGET_OS_IPHONE && !TARGET_OS_MACCATALYST
+#if TARGET_OS_IPHONE && !TARGET_OS_MACCATALYST && !TARGET_OS_VISION
 		case MTLLanguageVersion1_0:
 			setMSLVersion(1, 0);
 			break;
@@ -324,6 +330,7 @@ void MetalDeviceProperties::init_limits(id<MTLDevice> p_device) {
 
 	limits.maxDrawIndexedIndexValue = std::numeric_limits<uint32_t>::max() - 1;
 
+#ifdef METAL_MFXTEMPORAL_ENABLED
 	if (@available(macOS 14.0, iOS 17.0, tvOS 17.0, *)) {
 		limits.temporalScalerInputContentMinScale = (double)[MTLFXTemporalScalerDescriptor supportedInputContentMinScaleForDevice:p_device];
 		limits.temporalScalerInputContentMaxScale = (double)[MTLFXTemporalScalerDescriptor supportedInputContentMaxScaleForDevice:p_device];
@@ -332,6 +339,11 @@ void MetalDeviceProperties::init_limits(id<MTLDevice> p_device) {
 		limits.temporalScalerInputContentMinScale = 1.0;
 		limits.temporalScalerInputContentMaxScale = 3.0;
 	}
+#else
+	// Defaults taken from macOS 14+
+	limits.temporalScalerInputContentMinScale = 1.0;
+	limits.temporalScalerInputContentMaxScale = 3.0;
+#endif
 }
 
 MetalDeviceProperties::MetalDeviceProperties(id<MTLDevice> p_device) {

+ 6 - 0
drivers/metal/pixel_formats.mm

@@ -114,6 +114,9 @@ bool PixelFormats::isSupportedOrSubstitutable(DataFormat p_format) {
 }
 
 bool PixelFormats::isPVRTCFormat(MTLPixelFormat p_format) {
+#if defined(VISIONOS_ENABLED)
+	return false;
+#else
 	switch (p_format) {
 		case MTLPixelFormatPVRTC_RGBA_2BPP:
 		case MTLPixelFormatPVRTC_RGBA_2BPP_sRGB:
@@ -127,6 +130,7 @@ bool PixelFormats::isPVRTCFormat(MTLPixelFormat p_format) {
 		default:
 			return false;
 	}
+#endif
 }
 
 MTLFormatType PixelFormats::getFormatType(DataFormat p_format) {
@@ -668,11 +672,13 @@ void PixelFormats::initMTLPixelFormatCapabilities() {
 	addMTLPixelFormatDesc(RGBA32Sint, Color128, RWC);
 	addMTLPixelFormatDesc(RGBA32Float, Color128, All);
 
+#if !defined(VISIONOS_ENABLED)
 	// Compressed pixel formats
 	addMTLPixelFormatDesc(PVRTC_RGBA_2BPP, PVRTC_RGBA_2BPP, RF);
 	addMTLPixelFormatDescSRGB(PVRTC_RGBA_2BPP_sRGB, PVRTC_RGBA_2BPP, RF, PVRTC_RGBA_2BPP);
 	addMTLPixelFormatDesc(PVRTC_RGBA_4BPP, PVRTC_RGBA_4BPP, RF);
 	addMTLPixelFormatDescSRGB(PVRTC_RGBA_4BPP_sRGB, PVRTC_RGBA_4BPP, RF, PVRTC_RGBA_4BPP);
+#endif
 
 	addMTLPixelFormatDesc(ETC2_RGB8, ETC2_RGB8, RF);
 	addMTLPixelFormatDescSRGB(ETC2_RGB8_sRGB, ETC2_RGB8, RF, ETC2_RGB8);

+ 8 - 0
drivers/metal/rendering_device_driver_metal.mm

@@ -290,7 +290,11 @@ RDD::TextureID RenderingDeviceDriverMetal::texture_create(const TextureFormat &p
 	// Usage.
 
 	MTLResourceOptions options = 0;
+#if defined(VISIONOS_ENABLED)
+	const bool supports_memoryless = true;
+#else
 	const bool supports_memoryless = (*device_properties).features.highestFamily >= MTLGPUFamilyApple2 && (*device_properties).features.highestFamily < MTLGPUFamilyMac1;
+#endif
 	if (supports_memoryless && p_format.usage_bits & TEXTURE_USAGE_TRANSIENT_BIT) {
 		options = MTLResourceStorageModeMemoryless | MTLResourceHazardTrackingModeTracked;
 		desc.storageMode = MTLStorageModeMemoryless;
@@ -2493,7 +2497,11 @@ RDD::ShaderID RenderingDeviceDriverMetal::shader_create_from_bytecode(const Vect
 		cd->name = binary_data.shader_name;
 		cd->stage = shader_data.stage;
 		options.preserveInvariance = shader_data.is_position_invariant;
+#if defined(VISIONOS_ENABLED)
+		options.mathMode = MTLMathModeFast;
+#else
 		options.fastMathEnabled = YES;
+#endif
 		MDLibrary *library = [MDLibrary newLibraryWithCacheEntry:cd
 														  device:device
 														  source:source

+ 32 - 25
editor/export/editor_export_platform_apple_embedded.cpp

@@ -1128,30 +1128,35 @@ Error EditorExportPlatformAppleEmbedded::_convert_to_framework(const String &p_s
 					lib_clean_name[i] = '-';
 				}
 			}
-			String info_plist_format = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
-									   "<!DOCTYPE plist PUBLIC \"-//Apple//DTD PLIST 1.0//EN\" \"http://www.apple.com/DTDs/PropertyList-1.0.dtd\">\n"
-									   "<plist version=\"1.0\">\n"
-									   "  <dict>\n"
-									   "    <key>CFBundleShortVersionString</key>\n"
-									   "    <string>1.0</string>\n"
-									   "    <key>CFBundleIdentifier</key>\n"
-									   "    <string>$id.framework.$cl_name</string>\n"
-									   "    <key>CFBundleName</key>\n"
-									   "    <string>$name</string>\n"
-									   "    <key>CFBundleExecutable</key>\n"
-									   "    <string>$name</string>\n"
-									   "    <key>DTPlatformName</key>\n"
-									   "    <string>iphoneos</string>\n"
-									   "    <key>CFBundleInfoDictionaryVersion</key>\n"
-									   "    <string>6.0</string>\n"
-									   "    <key>CFBundleVersion</key>\n"
-									   "    <string>1</string>\n"
-									   "    <key>CFBundlePackageType</key>\n"
-									   "    <string>FMWK</string>\n"
-									   "    <key>MinimumOSVersion</key>\n"
-									   "    <string>12.0</string>\n"
-									   "  </dict>\n"
-									   "</plist>";
+			String info_plist_format =
+					"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
+					"<!DOCTYPE plist PUBLIC \"-//Apple//DTD PLIST 1.0//EN\" \"http://www.apple.com/DTDs/PropertyList-1.0.dtd\">\n"
+					"<plist version=\"1.0\">\n"
+					"  <dict>\n"
+					"    <key>CFBundleShortVersionString</key>\n"
+					"    <string>1.0</string>\n"
+					"    <key>CFBundleIdentifier</key>\n"
+					"    <string>$id.framework.$cl_name</string>\n"
+					"    <key>CFBundleName</key>\n"
+					"    <string>$name</string>\n"
+					"    <key>CFBundleExecutable</key>\n"
+					"    <string>$name</string>\n"
+					"    <key>DTPlatformName</key>\n"
+					"    <string>" +
+					get_sdk_name() +
+					"</string>\n"
+					"    <key>CFBundleInfoDictionaryVersion</key>\n"
+					"    <string>6.0</string>\n"
+					"    <key>CFBundleVersion</key>\n"
+					"    <string>1</string>\n"
+					"    <key>CFBundlePackageType</key>\n"
+					"    <string>FMWK</string>\n"
+					"    <key>MinimumOSVersion</key>\n"
+					"    <string>" +
+					get_minimum_deployment_target() +
+					"</string>\n"
+					"  </dict>\n"
+					"</plist>";
 
 			String info_plist = info_plist_format.replace("$id", p_id).replace("$name", file_name).replace("$cl_name", lib_clean_name);
 
@@ -2124,6 +2129,8 @@ Error EditorExportPlatformAppleEmbedded::_export_project_helper(const Ref<Editor
 		return ERR_SKIP;
 	}
 
+	String platform_name = get_platform_name();
+
 	String archive_path = p_path.get_basename() + ".xcarchive";
 	List<String> archive_args;
 	archive_args.push_back("-project");
@@ -2131,7 +2138,7 @@ Error EditorExportPlatformAppleEmbedded::_export_project_helper(const Ref<Editor
 	archive_args.push_back("-scheme");
 	archive_args.push_back(binary_name);
 	archive_args.push_back("-sdk");
-	archive_args.push_back("iphoneos");
+	archive_args.push_back(get_sdk_name());
 	archive_args.push_back("-configuration");
 	archive_args.push_back(p_debug ? "Debug" : "Release");
 	archive_args.push_back("-destination");

+ 3 - 0
editor/export/editor_export_platform_apple_embedded.h

@@ -168,6 +168,9 @@ protected:
 	virtual Error _export_icons(const Ref<EditorExportPreset> &p_preset, const String &p_iconset_dir) { return OK; }
 
 	virtual String get_platform_name() const = 0;
+	virtual String get_sdk_name() const = 0;
+	virtual String get_minimum_deployment_target() const = 0;
+
 	virtual void get_preset_features(const Ref<EditorExportPreset> &p_preset, List<String> *r_features) const override;
 	virtual void get_export_options(List<ExportOption> *r_options) const override;
 	virtual bool get_export_option_visibility(const EditorExportPreset *p_preset, const String &p_option) const override;

+ 2 - 0
editor/export/macho.h

@@ -111,6 +111,8 @@ public:
 		PLATFORM_TVOSSIMULATOR = 8,
 		PLATFORM_WATCHOSSIMULATOR = 9,
 		PLATFORM_DRIVERKIT = 10,
+		PLATFORM_VISIONOS = 11,
+		PLATFORM_VISIONOSSIMULATOR = 12,
 	};
 
 	struct LoadCommandHeader {

+ 2 - 0
main/main.cpp

@@ -2191,6 +2191,7 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph
 		GLOBAL_DEF_RST(PropertyInfo(Variant::STRING, "rendering/rendering_device/driver.linuxbsd", PROPERTY_HINT_ENUM, "vulkan"), "vulkan");
 		GLOBAL_DEF_RST(PropertyInfo(Variant::STRING, "rendering/rendering_device/driver.android", PROPERTY_HINT_ENUM, "vulkan"), "vulkan");
 		GLOBAL_DEF_RST(PropertyInfo(Variant::STRING, "rendering/rendering_device/driver.ios", PROPERTY_HINT_ENUM, "metal,vulkan"), "metal");
+		GLOBAL_DEF_RST(PropertyInfo(Variant::STRING, "rendering/rendering_device/driver.visionos", PROPERTY_HINT_ENUM, "metal"), "metal");
 		GLOBAL_DEF_RST(PropertyInfo(Variant::STRING, "rendering/rendering_device/driver.macos", PROPERTY_HINT_ENUM, "metal,vulkan"), "metal");
 
 		GLOBAL_DEF_RST("rendering/rendering_device/fallback_to_vulkan", true);
@@ -2672,6 +2673,7 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph
 	GLOBAL_DEF_NOVAL(PropertyInfo(Variant::STRING, "display/display_server/driver.linuxbsd", PROPERTY_HINT_ENUM_SUGGESTION, "default,x11,wayland,headless"), "default");
 	GLOBAL_DEF_NOVAL(PropertyInfo(Variant::STRING, "display/display_server/driver.android", PROPERTY_HINT_ENUM_SUGGESTION, "default,android,headless"), "default");
 	GLOBAL_DEF_NOVAL(PropertyInfo(Variant::STRING, "display/display_server/driver.ios", PROPERTY_HINT_ENUM_SUGGESTION, "default,iOS,headless"), "default");
+	GLOBAL_DEF_NOVAL(PropertyInfo(Variant::STRING, "display/display_server/driver.visionos", PROPERTY_HINT_ENUM_SUGGESTION, "default,visionOS,headless"), "default");
 	GLOBAL_DEF_NOVAL(PropertyInfo(Variant::STRING, "display/display_server/driver.macos", PROPERTY_HINT_ENUM_SUGGESTION, "default,macos,headless"), "default");
 
 	GLOBAL_DEF_RST_NOVAL("audio/driver/driver", AudioDriverManager::get_driver(0)->get_name());

+ 8 - 0
methods.py

@@ -636,6 +636,14 @@ def detect_darwin_sdk_path(platform, env):
         sdk_name = "iphonesimulator"
         var_name = "IOS_SDK_PATH"
 
+    elif platform == "visionos":
+        sdk_name = "xros"
+        var_name = "VISIONOS_SDK_PATH"
+
+    elif platform == "visionossimulator":
+        sdk_name = "xrsimulator"
+        var_name = "VISIONOS_SDK_PATH"
+
     else:
         raise Exception("Invalid platform argument passed to detect_darwin_sdk_path")
 

+ 10 - 0
misc/dist/visionos_xcode/PrivacyInfo.xcprivacy

@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>NSPrivacyAccessedAPITypes</key>
+	$priv_api_types
+	$priv_tracking
+	$priv_collection
+</dict>
+</plist>

+ 0 - 0
misc/dist/visionos_xcode/data.pck


+ 402 - 0
misc/dist/visionos_xcode/godot_visionos.xcodeproj/project.pbxproj

@@ -0,0 +1,402 @@
+// !$*UTF8*$!
+{
+	archiveVersion = 1;
+	classes = {
+	};
+	objectVersion = 46;
+	objects = {
+
+/* Begin PBXBuildFile section */
+		1F1575721F582BE20003B888 /* dylibs in Resources */ = {isa = PBXBuildFile; fileRef = 1F1575711F582BE20003B888 /* dylibs */; };
+		DEADBEEF2F582BE20003B888 /* $binary.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = DEADBEEF1F582BE20003B888 /* $binary.xcframework */; };
+		$modules_buildfile
+		$swift_runtime_buildfile
+		1FF8DBB11FBA9DE1009DE660 /* dummy.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1FF8DBB01FBA9DE1009DE660 /* dummy.cpp */; };
+		D07CD44E1C5D589C00B7FB28 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = D07CD44D1C5D589C00B7FB28 /* Images.xcassets */; };
+		D0BCFE4618AEBDA2004A7AAE /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = D0BCFE4418AEBDA2004A7AAE /* InfoPlist.strings */; };
+		D0BCFE7818AEBFEB004A7AAE /* $binary.pck in Resources */ = {isa = PBXBuildFile; fileRef = D0BCFE7718AEBFEB004A7AAE /* $binary.pck */; };
+		F965960D2BC2C3A800579C7E /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = F965960C2BC2C3A800579C7E /* PrivacyInfo.xcprivacy */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXCopyFilesBuildPhase section */
+		90A13CD024AA68E500E8464F /* Embed Frameworks */ = {
+				isa = PBXCopyFilesBuildPhase;
+				buildActionMask = 2147483647;
+				dstPath = "";
+				dstSubfolderSpec = 10;
+				files = (
+					$pbx_embeded_frameworks
+				);
+				name = "Embed Frameworks";
+				runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXCopyFilesBuildPhase section */
+
+/* Begin PBXFileReference section */
+		1F1575711F582BE20003B888 /* dylibs */ = {isa = PBXFileReference; lastKnownFileType = folder; name = dylibs; path = "$binary/dylibs"; sourceTree = "<group>"; };
+		DEADBEEF1F582BE20003B888 /* $binary.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = godot; path = "$binary.xcframework"; sourceTree = "<group>"; };
+		$modules_fileref
+		$swift_runtime_fileref
+		1FF4C1881F584E6300A41E41 /* $binary.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = "$binary.entitlements"; sourceTree = "<group>"; };
+		1FF8DBB01FBA9DE1009DE660 /* dummy.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = dummy.cpp; sourceTree = "<group>"; };
+		D07CD44D1C5D589C00B7FB28 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = "<group>"; };
+		D0BCFE3418AEBDA2004A7AAE /* $binary.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "$binary.app"; sourceTree = BUILT_PRODUCTS_DIR; };
+		D0BCFE4318AEBDA2004A7AAE /* $binary-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "$binary-Info.plist"; sourceTree = "<group>"; };
+		D0BCFE4518AEBDA2004A7AAE /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
+		$pbx_locale_file_reference
+		D0BCFE7718AEBFEB004A7AAE /* $binary.pck */ = {isa = PBXFileReference; lastKnownFileType = file; path = "$binary.pck"; sourceTree = "<group>"; };
+		F965960C2BC2C3A800579C7E /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = PrivacyInfo.xcprivacy; sourceTree = "<group>"; };
+/* End PBXFileReference section */
+
+		$additional_pbx_files
+
+/* Begin PBXFrameworksBuildPhase section */
+		D0BCFE3118AEBDA2004A7AAE /* Frameworks */ = {
+			isa = PBXFrameworksBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				DEADBEEF2F582BE20003B888 /* $binary.xcframework */,
+				$modules_buildphase
+				$additional_pbx_frameworks_build
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+		D0BCFE2B18AEBDA2004A7AAE = {
+			isa = PBXGroup;
+			children = (
+				1F1575711F582BE20003B888 /* dylibs */,
+				D0BCFE7718AEBFEB004A7AAE /* $binary.pck */,
+				D0BCFE4118AEBDA2004A7AAE /* $binary */,
+				D0BCFE3618AEBDA2004A7AAE /* Frameworks */,
+				D0BCFE3518AEBDA2004A7AAE /* Products */,
+				F965960C2BC2C3A800579C7E /* PrivacyInfo.xcprivacy */,
+				$additional_pbx_resources_refs
+			);
+			sourceTree = "<group>";
+		};
+		D0BCFE3518AEBDA2004A7AAE /* Products */ = {
+			isa = PBXGroup;
+			children = (
+				D0BCFE3418AEBDA2004A7AAE /* $binary.app */,
+			);
+			name = Products;
+			sourceTree = "<group>";
+		};
+		D0BCFE3618AEBDA2004A7AAE /* Frameworks */ = {
+			isa = PBXGroup;
+			children = (
+				DEADBEEF1F582BE20003B888 /* $binary.xcframework */,
+				$modules_buildgrp
+				$additional_pbx_frameworks_refs
+			);
+			name = Frameworks;
+			sourceTree = "<group>";
+		};
+		D0BCFE4118AEBDA2004A7AAE /* $binary */ = {
+			isa = PBXGroup;
+			children = (
+				1FF4C1881F584E6300A41E41 /* $binary.entitlements */,
+				D07CD44D1C5D589C00B7FB28 /* Images.xcassets */,
+				D0BCFE4218AEBDA2004A7AAE /* Supporting Files */,
+				1FF8DBB01FBA9DE1009DE660 /* dummy.cpp */,
+				$swift_runtime_binary_files
+			);
+			path = "$binary";
+			sourceTree = "<group>";
+		};
+		D0BCFE4218AEBDA2004A7AAE /* Supporting Files */ = {
+			isa = PBXGroup;
+			children = (
+				D0BCFE4318AEBDA2004A7AAE /* $binary-Info.plist */,
+				D0BCFE4418AEBDA2004A7AAE /* InfoPlist.strings */,
+			);
+			name = "Supporting Files";
+			sourceTree = "<group>";
+		};
+/* End PBXGroup section */
+
+/* Begin PBXNativeTarget section */
+		D0BCFE3318AEBDA2004A7AAE /* $binary */ = {
+			isa = PBXNativeTarget;
+			buildConfigurationList = D0BCFE7118AEBDA3004A7AAE /* Build configuration list for PBXNativeTarget "$binary" */;
+			buildPhases = (
+				D0BCFE3018AEBDA2004A7AAE /* Sources */,
+				D0BCFE3118AEBDA2004A7AAE /* Frameworks */,
+				D0BCFE3218AEBDA2004A7AAE /* Resources */,
+				90A13CD024AA68E500E8464F /* Embed Frameworks */,
+			);
+			buildRules = (
+			);
+			dependencies = (
+			);
+			name = "$binary";
+			productName = "$name";
+			productReference = D0BCFE3418AEBDA2004A7AAE /* $binary.app */;
+			productType = "com.apple.product-type.application";
+		};
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+		D0BCFE2C18AEBDA2004A7AAE /* Project object */ = {
+			isa = PBXProject;
+			attributes = {
+				LastUpgradeCheck = 0500;
+				ORGANIZATIONNAME = GodotEngine;
+				TargetAttributes = {
+					D0BCFE3318AEBDA2004A7AAE = {
+						DevelopmentTeam = $team_id;
+						$swift_runtime_migration
+						ProvisioningStyle = Automatic;
+						SystemCapabilities = {
+						};
+					};
+				};
+			};
+			buildConfigurationList = D0BCFE2F18AEBDA2004A7AAE /* Build configuration list for PBXProject "$binary" */;
+			compatibilityVersion = "Xcode 3.2";
+			developmentRegion = en;
+			hasScannedForEncodings = 0;
+			knownRegions = (
+				en,
+				Base,
+			);
+			mainGroup = D0BCFE2B18AEBDA2004A7AAE;
+			productRefGroup = D0BCFE3518AEBDA2004A7AAE /* Products */;
+			projectDirPath = "";
+			projectRoot = "";
+			targets = (
+				D0BCFE3318AEBDA2004A7AAE /* $binary */,
+			);
+		};
+/* End PBXProject section */
+
+/* Begin PBXResourcesBuildPhase section */
+		D0BCFE3218AEBDA2004A7AAE /* Resources */ = {
+			isa = PBXResourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				D07CD44E1C5D589C00B7FB28 /* Images.xcassets in Resources */,
+				D0BCFE7818AEBFEB004A7AAE /* $binary.pck in Resources */,
+				D0BCFE4618AEBDA2004A7AAE /* InfoPlist.strings in Resources */,
+				F965960D2BC2C3A800579C7E /* PrivacyInfo.xcprivacy in Resources */,
+				$additional_pbx_resources_build
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXResourcesBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+		D0BCFE3018AEBDA2004A7AAE /* Sources */ = {
+			isa = PBXSourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				1FF8DBB11FBA9DE1009DE660 /* dummy.cpp in Sources */,
+				$swift_runtime_build_phase
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXVariantGroup section */
+		D0BCFE4418AEBDA2004A7AAE /* InfoPlist.strings */ = {
+			isa = PBXVariantGroup;
+			children = (
+				D0BCFE4518AEBDA2004A7AAE /* en */,
+				$pbx_locale_build_reference
+			);
+			name = InfoPlist.strings;
+			sourceTree = "<group>";
+		};
+/* End PBXVariantGroup section */
+
+/* Begin XCBuildConfiguration section */
+		D0BCFE6F18AEBDA3004A7AAE /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				ARCHS = "$godot_archs";
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+				CLANG_CXX_LIBRARY = "libc++";
+				CLANG_ENABLE_MODULES = YES;
+				CLANG_ENABLE_OBJC_ARC = YES;
+				CLANG_WARN_BOOL_CONVERSION = YES;
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
+				CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
+				CLANG_WARN_EMPTY_BODY = YES;
+				CLANG_WARN_ENUM_CONVERSION = YES;
+				CLANG_WARN_INT_CONVERSION = YES;
+				CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+				CODE_SIGN_IDENTITY = "$code_sign_identity_debug";
+				"CODE_SIGN_IDENTITY[sdk=xros*]" = "$code_sign_identity_debug";
+				COPY_PHASE_STRIP = NO;
+				ENABLE_BITCODE = NO;
+				"FRAMEWORK_SEARCH_PATHS[arch=*]" = (
+					"$(PROJECT_DIR)/**",
+				);
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_DYNAMIC_NO_PIC = NO;
+				GCC_OPTIMIZATION_LEVEL = 0;
+				GCC_PREPROCESSOR_DEFINITIONS = (
+					"$(inherited)",
+				);
+				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
+				GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
+				GCC_WARN_UNDECLARED_SELECTOR = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_FUNCTION = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				XROS_DEPLOYMENT_TARGET = $min_version;
+				"LD_CLASSIC_1500" = "-ld_classic";
+				"LD_CLASSIC_1501" = "-ld_classic";
+				"LD_CLASSIC_1510" = "-ld_classic";
+				OTHER_LDFLAGS = "$(LD_CLASSIC_$(XCODE_VERSION_ACTUAL)) $linker_flags";
+				SDKROOT = xros;
+				TARGETED_DEVICE_FAMILY = 7;
+			};
+			name = Debug;
+		};
+		D0BCFE7018AEBDA3004A7AAE /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				ARCHS = "$godot_archs";
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+				CLANG_CXX_LIBRARY = "libc++";
+				CLANG_ENABLE_MODULES = YES;
+				CLANG_ENABLE_OBJC_ARC = YES;
+				CLANG_WARN_BOOL_CONVERSION = YES;
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
+				CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
+				CLANG_WARN_EMPTY_BODY = YES;
+				CLANG_WARN_ENUM_CONVERSION = YES;
+				CLANG_WARN_INT_CONVERSION = YES;
+				CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+				CODE_SIGN_IDENTITY = "$code_sign_identity_release";
+				"CODE_SIGN_IDENTITY[sdk=xros*]" = "$code_sign_identity_release";
+				COPY_PHASE_STRIP = YES;
+				ENABLE_BITCODE = NO;
+				"FRAMEWORK_SEARCH_PATHS[arch=*]" = (
+					"$(PROJECT_DIR)/**",
+				);
+				ENABLE_NS_ASSERTIONS = NO;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
+				GCC_WARN_UNDECLARED_SELECTOR = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_FUNCTION = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				XROS_DEPLOYMENT_TARGET = $min_version;
+				"LD_CLASSIC_1500" = "-ld_classic";
+				"LD_CLASSIC_1501" = "-ld_classic";
+				"LD_CLASSIC_1510" = "-ld_classic";
+				OTHER_LDFLAGS = "$(LD_CLASSIC_$(XCODE_VERSION_ACTUAL)) $linker_flags";
+				SDKROOT = xros;
+				TARGETED_DEVICE_FAMILY = 7;
+				VALIDATE_PRODUCT = YES;
+			};
+			name = Release;
+		};
+		D0BCFE7218AEBDA3004A7AAE /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ARCHS = "$godot_archs";
+				ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
+				CODE_SIGN_ENTITLEMENTS = "$binary/$binary.entitlements";
+				CODE_SIGN_IDENTITY = "$code_sign_identity_debug";
+				"CODE_SIGN_IDENTITY[sdk=xros*]" = "$code_sign_identity_debug";
+				CODE_SIGN_STYLE = "$code_sign_style_debug";
+				CONFIGURATION_BUILD_DIR = "$(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)";
+				DEVELOPMENT_TEAM = $team_id;
+				INFOPLIST_FILE = "$binary/$binary-Info.plist";
+				XROS_DEPLOYMENT_TARGET = $min_version;
+				LD_RUNPATH_SEARCH_PATHS = (
+					"$(inherited)",
+					"@executable_path/Frameworks",
+				);
+				LIBRARY_SEARCH_PATHS = (
+					"$(inherited)",
+					"$(PROJECT_DIR)/**",
+				);
+				PRODUCT_BUNDLE_IDENTIFIER = $bundle_identifier;
+				INFOPLIST_KEY_CFBundleDisplayName = "$name";
+				PRODUCT_NAME = "$binary";
+				EXECUTABLE_NAME = "$binary";
+				MARKETING_VERSION = $short_version;
+				CURRENT_PROJECT_VERSION = $version;
+				PROVISIONING_PROFILE = "$provisioning_profile_uuid_debug";
+				PROVISIONING_PROFILE_SPECIFIER = "$provisioning_profile_specifier_debug";
+				TARGETED_DEVICE_FAMILY = 7;
+				VALID_ARCHS = "arm64 x86_64";
+				WRAPPER_EXTENSION = app;
+				$swift_runtime_build_settings
+			};
+			name = Debug;
+		};
+		D0BCFE7318AEBDA3004A7AAE /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ARCHS = "$godot_archs";
+				ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
+				CODE_SIGN_ENTITLEMENTS = "$binary/$binary.entitlements";
+				CODE_SIGN_IDENTITY = "$code_sign_identity_release";
+				"CODE_SIGN_IDENTITY[sdk=xros*]" = "$code_sign_identity_release";
+				CODE_SIGN_STYLE = "$code_sign_style_release";
+				CONFIGURATION_BUILD_DIR = "$(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)";
+				DEVELOPMENT_TEAM = $team_id;
+				INFOPLIST_FILE = "$binary/$binary-Info.plist";
+				XROS_DEPLOYMENT_TARGET = $min_version;
+				LD_RUNPATH_SEARCH_PATHS = (
+					"$(inherited)",
+					"@executable_path/Frameworks",
+				);
+				LIBRARY_SEARCH_PATHS = (
+					"$(inherited)",
+					"$(PROJECT_DIR)/**",
+				);
+				PRODUCT_BUNDLE_IDENTIFIER = $bundle_identifier;
+				INFOPLIST_KEY_CFBundleDisplayName = "$name";
+				PRODUCT_NAME = "$binary";
+				EXECUTABLE_NAME = "$binary";
+				MARKETING_VERSION = $short_version;
+				CURRENT_PROJECT_VERSION = $version;
+				PROVISIONING_PROFILE = "$provisioning_profile_uuid_release";
+				PROVISIONING_PROFILE_SPECIFIER = "$provisioning_profile_specifier_release";
+				TARGETED_DEVICE_FAMILY = 7;
+				VALID_ARCHS = "arm64";
+				WRAPPER_EXTENSION = app;
+				$swift_runtime_build_settings
+			};
+			name = Release;
+		};
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+		D0BCFE2F18AEBDA2004A7AAE /* Build configuration list for PBXProject "$binary" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				D0BCFE6F18AEBDA3004A7AAE /* Debug */,
+				D0BCFE7018AEBDA3004A7AAE /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Debug;
+		};
+		D0BCFE7118AEBDA3004A7AAE /* Build configuration list for PBXNativeTarget "$binary" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				D0BCFE7218AEBDA3004A7AAE /* Debug */,
+				D0BCFE7318AEBDA3004A7AAE /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Debug;
+		};
+/* End XCConfigurationList section */
+	};
+	rootObject = D0BCFE2C18AEBDA2004A7AAE /* Project object */;
+}

+ 7 - 0
misc/dist/visionos_xcode/godot_visionos.xcodeproj/project.xcworkspace/contents.xcworkspacedata

@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Workspace
+   version = "1.0">
+   <FileRef
+      location = "self:$binary.xcodeproj">
+   </FileRef>
+</Workspace>

+ 93 - 0
misc/dist/visionos_xcode/godot_visionos.xcodeproj/xcshareddata/xcschemes/godot_visionos.xcscheme

@@ -0,0 +1,93 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Scheme
+   LastUpgradeVersion = "0710"
+   version = "1.3">
+   <BuildAction
+      parallelizeBuildables = "YES"
+      buildImplicitDependencies = "YES">
+      <BuildActionEntries>
+         <BuildActionEntry
+            buildForTesting = "YES"
+            buildForRunning = "YES"
+            buildForProfiling = "YES"
+            buildForArchiving = "YES"
+            buildForAnalyzing = "YES">
+            <BuildableReference
+               BuildableIdentifier = "primary"
+               BlueprintIdentifier = "A340BDFEBCA49239A941883D"
+               BuildableName = "$binary.app"
+               BlueprintName = "$binary"
+               ReferencedContainer = "container:$binary.xcodeproj">
+            </BuildableReference>
+         </BuildActionEntry>
+      </BuildActionEntries>
+   </BuildAction>
+   <TestAction
+      buildConfiguration = "$default_build_config"
+      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
+      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
+      shouldUseLaunchSchemeArgsEnv = "YES">
+      <Testables>
+      </Testables>
+      <MacroExpansion>
+            <BuildableReference
+               BuildableIdentifier = "primary"
+               BlueprintIdentifier = "A340BDFEBCA49239A941883D"
+               BuildableName = "$binary.app"
+               BlueprintName = "$binary"
+               ReferencedContainer = "container:$binary.xcodeproj">
+            </BuildableReference>
+      </MacroExpansion>
+      <AdditionalOptions>
+      </AdditionalOptions>
+   </TestAction>
+   <LaunchAction
+      buildConfiguration = "$default_build_config"
+      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
+      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
+      launchStyle = "0"
+      useCustomWorkingDirectory = "NO"
+      ignoresPersistentStateOnLaunch = "NO"
+      debugDocumentVersioning = "YES"
+      debugServiceExtension = "internal"
+      allowLocationSimulation = "YES">
+      <BuildableProductRunnable
+         runnableDebuggingMode = "0">
+            <BuildableReference
+               BuildableIdentifier = "primary"
+               BlueprintIdentifier = "A340BDFEBCA49239A941883D"
+               BuildableName = "$binary.app"
+               BlueprintName = "$binary"
+               ReferencedContainer = "container:$binary.xcodeproj">
+            </BuildableReference>
+      </BuildableProductRunnable>
+      <CommandLineArguments>
+      </CommandLineArguments>
+      <AdditionalOptions>
+      </AdditionalOptions>
+   </LaunchAction>
+   <ProfileAction
+      buildConfiguration = "$default_build_config"
+      shouldUseLaunchSchemeArgsEnv = "YES"
+      savedToolIdentifier = ""
+      useCustomWorkingDirectory = "NO"
+      debugDocumentVersioning = "YES">
+      <BuildableProductRunnable
+         runnableDebuggingMode = "0">
+            <BuildableReference
+               BuildableIdentifier = "primary"
+               BlueprintIdentifier = "A340BDFEBCA49239A941883D"
+               BuildableName = "$binary.app"
+               BlueprintName = "$binary"
+               ReferencedContainer = "container:$binary.xcodeproj">
+            </BuildableReference>
+      </BuildableProductRunnable>
+   </ProfileAction>
+   <AnalyzeAction
+      buildConfiguration = "$default_build_config">
+   </AnalyzeAction>
+   <ArchiveAction
+      buildConfiguration = "$default_build_config"
+      revealArchiveInOrganizer = "YES">
+   </ArchiveAction>
+</Scheme>

+ 22 - 0
misc/dist/visionos_xcode/godot_visionos/Images.xcassets/SplashImage.imageset/Contents.json

@@ -0,0 +1,22 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "filename" : "[email protected]",
+      "idiom" : "universal",
+      "scale" : "2x"
+    },
+    {
+      "filename" : "[email protected]",
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "author" : "xcode",
+    "version" : 1
+  }
+}

BIN
misc/dist/visionos_xcode/godot_visionos/Images.xcassets/SplashImage.imageset/[email protected]


BIN
misc/dist/visionos_xcode/godot_visionos/Images.xcassets/SplashImage.imageset/[email protected]


+ 31 - 0
misc/dist/visionos_xcode/godot_visionos/dummy.cpp

@@ -0,0 +1,31 @@
+/**************************************************************************/
+/*  dummy.cpp                                                             */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+$cpp_code

+ 33 - 0
misc/dist/visionos_xcode/godot_visionos/dummy.h

@@ -0,0 +1,33 @@
+/**************************************************************************/
+/*  dummy.h                                                               */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+// #import <Foundation/Foundation.h>

+ 31 - 0
misc/dist/visionos_xcode/godot_visionos/dummy.swift

@@ -0,0 +1,31 @@
+/**************************************************************************/
+/*  dummy.swift                                                           */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+import Foundation

+ 1 - 0
misc/dist/visionos_xcode/godot_visionos/dylibs/empty

@@ -0,0 +1 @@
+Dummy file to make dylibs folder exported

+ 1 - 0
misc/dist/visionos_xcode/godot_visionos/en.lproj/InfoPlist.strings

@@ -0,0 +1 @@
+/* Localized versions of Info.plist keys */

+ 20 - 0
misc/dist/visionos_xcode/godot_visionos/export_options.plist

@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+    <key>method</key>
+    <string>$export_method</string>
+
+    <key>teamID</key>
+    <string>$team_id</string>
+
+    <key>provisioningProfiles</key>
+    <dict>
+        <key>$bundle_identifier</key>
+        <string>$provisioning_profile_uuid</string>
+    </dict>
+
+    <key>compileBitcode</key>
+    <false/>
+</dict>
+</plist>

+ 63 - 0
misc/dist/visionos_xcode/godot_visionos/godot_visionos-Info.plist

@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>en</string>
+	<key>CFBundleDisplayName</key>
+	<string>$(INFOPLIST_KEY_CFBundleDisplayName)</string>
+	<key>CFBundleExecutable</key>
+	<string>$(EXECUTABLE_NAME)</string>
+	<key>CFBundleIcons</key>
+	<dict/>
+	<key>CFBundleIcons~ipad</key>
+	<dict/>
+	<key>CFBundleIdentifier</key>
+	<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundleName</key>
+	<string>$(PRODUCT_NAME)</string>
+	<key>CFBundlePackageType</key>
+	<string>APPL</string>
+	<key>CFBundleShortVersionString</key>
+	<string>$(MARKETING_VERSION)</string>
+	<key>CFBundleSignature</key>
+	<string>$signature</string>
+	<key>CFBundleVersion</key>
+	<string>$(CURRENT_PROJECT_VERSION)</string>
+	<key>ITSAppUsesNonExemptEncryption</key>
+	<false />
+	<key>LSRequiresIPhoneOS</key>
+	<true/>
+	<key>LSSupportsOpeningDocumentsInPlace</key>
+	$docs_in_place
+	<key>UIFileSharingEnabled</key>
+	$docs_sharing
+	<key>UIRequiredDeviceCapabilities</key>
+	<array>
+		$required_device_capabilities
+	</array>
+	<key>NSCameraUsageDescription</key>
+	<string>$camera_usage_description</string>
+	<key>NSPhotoLibraryUsageDescription</key>
+	<string>$photolibrary_usage_description</string>
+	<key>NSMicrophoneUsageDescription</key>
+	<string>$microphone_usage_description</string>
+	<key>UIRequiresFullScreen</key>
+	<true/>
+	<key>UIStatusBarHidden</key>
+	<true/>
+	<key>UISupportedInterfaceOrientations</key>
+	<array>
+		$interface_orientations
+	</array>
+	<key>UISupportedInterfaceOrientations~ipad</key>
+	<array>
+		$ipad_interface_orientations
+	</array>
+	$additional_plist_content
+	$plist_launch_screen_name
+	<key>CADisableMinimumFrameDurationOnPhone</key><true/>
+</dict>
+</plist>

+ 7 - 0
misc/dist/visionos_xcode/godot_visionos/godot_visionos.entitlements

@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+$entitlements_full
+</dict>
+</plist>

+ 39 - 0
misc/dist/visionos_xcode/libgodot.visionos.debug.xcframework/Info.plist

@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>AvailableLibraries</key>
+	<array>
+		<dict>
+			<key>LibraryIdentifier</key>
+			<string>xros-arm64</string>
+			<key>LibraryPath</key>
+			<string>libgodot.a</string>
+			<key>SupportedArchitectures</key>
+			<array>
+				<string>arm64</string>
+			</array>
+			<key>SupportedPlatform</key>
+			<string>xros</string>
+		</dict>
+		<dict>
+			<key>LibraryIdentifier</key>
+			<string>xros-arm64-simulator</string>
+			<key>LibraryPath</key>
+			<string>libgodot.a</string>
+			<key>SupportedArchitectures</key>
+			<array>
+				<string>arm64</string>
+			</array>
+			<key>SupportedPlatform</key>
+			<string>xros</string>
+			<key>SupportedPlatformVariant</key>
+			<string>simulator</string>
+		</dict>
+	</array>
+	<key>CFBundlePackageType</key>
+	<string>XFWK</string>
+	<key>XCFrameworkFormatVersion</key>
+	<string>1.0</string>
+</dict>
+</plist>

+ 1 - 0
misc/dist/visionos_xcode/libgodot.visionos.debug.xcframework/xros-arm64-simulator/empty

@@ -0,0 +1 @@
+Dummy file to make dylibs folder exported

+ 1 - 0
misc/dist/visionos_xcode/libgodot.visionos.debug.xcframework/xros-arm64/empty

@@ -0,0 +1 @@
+Dummy file to make dylibs folder exported

+ 39 - 0
misc/dist/visionos_xcode/libgodot.visionos.release.xcframework/Info.plist

@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>AvailableLibraries</key>
+	<array>
+		<dict>
+			<key>LibraryIdentifier</key>
+			<string>xros-arm64</string>
+			<key>LibraryPath</key>
+			<string>libgodot.a</string>
+			<key>SupportedArchitectures</key>
+			<array>
+				<string>arm64</string>
+			</array>
+			<key>SupportedPlatform</key>
+			<string>xros</string>
+		</dict>
+		<dict>
+			<key>LibraryIdentifier</key>
+			<string>xros-arm64-simulator</string>
+			<key>LibraryPath</key>
+			<string>libgodot.a</string>
+			<key>SupportedArchitectures</key>
+			<array>
+				<string>arm64</string>
+			</array>
+			<key>SupportedPlatform</key>
+			<string>xros</string>
+			<key>SupportedPlatformVariant</key>
+			<string>simulator</string>
+		</dict>
+	</array>
+	<key>CFBundlePackageType</key>
+	<string>XFWK</string>
+	<key>XCFrameworkFormatVersion</key>
+	<string>1.0</string>
+</dict>
+</plist>

+ 1 - 0
misc/dist/visionos_xcode/libgodot.visionos.release.xcframework/xros-arm64-simulator/empty

@@ -0,0 +1 @@
+Dummy file to make dylibs folder exported

+ 1 - 0
misc/dist/visionos_xcode/libgodot.visionos.release.xcframework/xros-arm64/empty

@@ -0,0 +1 @@
+Dummy file to make dylibs folder exported

+ 1 - 1
platform/ios/export/export_plugin.cpp

@@ -44,7 +44,7 @@ void EditorExportPlatformIOS::get_export_options(List<ExportOption> *r_options)
 	EditorExportPlatformAppleEmbedded::get_export_options(r_options);
 
 	r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "application/targeted_device_family", PROPERTY_HINT_ENUM, "iPhone,iPad,iPhone & iPad"), 2));
-	r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/min_ios_version"), "14.0"));
+	r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/min_ios_version"), get_minimum_deployment_target()));
 
 	r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "storyboard/image_scale_mode", PROPERTY_HINT_ENUM, "Same as Logo,Center,Scale to Fit,Scale to Fill,Scale"), 0));
 	r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "storyboard/custom_image@2x", PROPERTY_HINT_FILE, "*.png,*.jpg,*.jpeg"), ""));

+ 4 - 0
platform/ios/export/export_plugin.h

@@ -37,6 +37,10 @@ class EditorExportPlatformIOS : public EditorExportPlatformAppleEmbedded {
 
 	virtual String get_platform_name() const override { return "ios"; }
 
+	virtual String get_sdk_name() const override { return "iphoneos"; }
+
+	virtual String get_minimum_deployment_target() const override { return "14.0"; }
+
 	virtual Vector<IconInfo> get_icon_infos() const override;
 
 	virtual void get_export_options(List<ExportOption> *r_options) const override;

+ 20 - 0
platform/visionos/README.md

@@ -0,0 +1,20 @@
+# visionOS platform port
+
+This folder contains the C++, Objective-C and Objective-C++ code for the visionOS
+platform port.
+
+This platform derives from the Apple Embedded abstract platform ([`drivers/apple_embedded`](drivers/apple_embedded)).
+
+This platform uses shared Apple code ([`drivers/apple`](drivers/apple)).
+
+See also [`misc/dist/ios_xcode`](/misc/dist/ios_xcode) folder for the Xcode
+project template used for packaging the iOS export templates.
+
+## Documentation
+
+The compiling and exporting process is the same as on iOS, but replacing the `ios` parameter by `visionos`.
+
+- [Compiling for iOS](https://docs.godotengine.org/en/latest/contributing/development/compiling/compiling_for_ios.html)
+  - Instructions on building this platform port from source.
+- [Exporting for iOS](https://docs.godotengine.org/en/latest/tutorials/export/exporting_for_ios.html)
+  - Instructions on using the compiled export templates to export a project.

+ 29 - 0
platform/visionos/SCsub

@@ -0,0 +1,29 @@
+#!/usr/bin/env python
+from misc.utility.scons_hints import *
+
+from platform_visionos_builders import generate_bundle
+
+from platform_methods import combine_libs_apple_embedded
+
+Import("env")
+
+visionos_lib = [
+    "display_layer_visionos.mm",
+    "display_server_visionos.mm",
+    "godot_view_visionos.mm",
+    "main_visionos.mm",
+    "os_visionos.mm",
+]
+
+env_visionos = env.Clone()
+visionos_lib = env_visionos.add_library("visionos", visionos_lib)
+
+# Enable module support
+env_visionos.Append(CCFLAGS=["-fmodules", "-fcxx-modules"])
+
+combine_command = env_visionos.Command(
+    "#bin/libgodot" + env_visionos["LIBSUFFIX"], [visionos_lib] + env_visionos["LIBS"], combine_libs_apple_embedded
+)
+
+if env["generate_bundle"]:
+    env.AlwaysBuild(env.CommandNoCache("generate_bundle", combine_command, env.Run(generate_bundle)))

+ 48 - 0
platform/visionos/api/api.cpp

@@ -0,0 +1,48 @@
+/**************************************************************************/
+/*  api.cpp                                                               */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#include "api.h"
+
+#if defined(VISIONOS_ENABLED)
+
+void register_visionos_api() {
+	godot_apple_embedded_plugins_initialize();
+}
+
+void unregister_visionos_api() {
+	godot_apple_embedded_plugins_deinitialize();
+}
+
+#else
+
+void register_visionos_api() {}
+void unregister_visionos_api() {}
+
+#endif // VISIONOS_ENABLED

+ 39 - 0
platform/visionos/api/api.h

@@ -0,0 +1,39 @@
+/**************************************************************************/
+/*  api.h                                                                 */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#if defined(VISIONOS_ENABLED)
+extern void godot_apple_embedded_plugins_initialize();
+extern void godot_apple_embedded_plugins_deinitialize();
+#endif
+
+void register_visionos_api();
+void unregister_visionos_api();

+ 160 - 0
platform/visionos/detect.py

@@ -0,0 +1,160 @@
+import os
+import sys
+from typing import TYPE_CHECKING
+
+from methods import detect_darwin_sdk_path, detect_darwin_toolchain_path, print_warning
+from platform_methods import validate_arch
+
+if TYPE_CHECKING:
+    from SCons.Script.SConscript import SConsEnvironment
+
+
+def get_name():
+    return "visionOS"
+
+
+def can_build():
+    if sys.platform == "darwin" or ("OSXCROSS_VISIONOS" in os.environ):
+        return True
+
+    return False
+
+
+def get_opts():
+    from SCons.Variables import BoolVariable
+
+    return [
+        # APPLE_TOOLCHAIN_PATH Example: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain
+        (("APPLE_TOOLCHAIN_PATH", "IOS_TOOLCHAIN_PATH"), "Path to the Apple toolchain", ""),
+        ("VISIONOS_SDK_PATH", "Path to the visionOS SDK", ""),
+        ("apple_target_triple", "Triple for corresponding target Apple platform toolchain", ""),
+        BoolVariable("simulator", "Build for Simulator", False),
+        BoolVariable("generate_bundle", "Generate an APP bundle after building visionOS/macOS binaries", False),
+    ]
+
+
+def get_doc_classes():
+    return [
+        "EditorExportPlatformVisionOS",
+    ]
+
+
+def get_doc_path():
+    return "doc_classes"
+
+
+def get_flags():
+    return {
+        "arch": "arm64",
+        "target": "template_debug",
+        "use_volk": False,
+        "metal": True,
+        "supported": ["metal", "mono"],
+        "builtin_pcre2_with_jit": False,
+        "vulkan": False,
+        "opengl3": False,
+    }
+
+
+def configure(env: "SConsEnvironment"):
+    # Validate arch.
+    supported_arches = ["x86_64", "arm64"]
+    validate_arch(env["arch"], get_name(), supported_arches)
+    detect_darwin_toolchain_path(env)
+
+    ## LTO
+
+    if env["lto"] == "auto":  # Disable by default as it makes linking in Xcode very slow.
+        env["lto"] = "none"
+
+    if env["lto"] != "none":
+        if env["lto"] == "thin":
+            env.Append(CCFLAGS=["-flto=thin"])
+            env.Append(LINKFLAGS=["-flto=thin"])
+        else:
+            env.Append(CCFLAGS=["-flto"])
+            env.Append(LINKFLAGS=["-flto"])
+
+    ## Compiler configuration
+
+    # Save this in environment for use by other modules
+    if "OSXCROSS_VISIONOS" in os.environ:
+        env["osxcross"] = True
+
+    env["ENV"]["PATH"] = env["APPLE_TOOLCHAIN_PATH"] + "/Developer/usr/bin/:" + env["ENV"]["PATH"]
+
+    compiler_path = "$APPLE_TOOLCHAIN_PATH/usr/bin/${apple_target_triple}"
+
+    ccache_path = os.environ.get("CCACHE")
+    if ccache_path is None:
+        env["CC"] = compiler_path + "clang"
+        env["CXX"] = compiler_path + "clang++"
+        env["S_compiler"] = compiler_path + "clang"
+    else:
+        # there aren't any ccache wrappers available for visionOS,
+        # to enable caching we need to prepend the path to the ccache binary
+        env["CC"] = ccache_path + " " + compiler_path + "clang"
+        env["CXX"] = ccache_path + " " + compiler_path + "clang++"
+        env["S_compiler"] = ccache_path + " " + compiler_path + "clang"
+    env["AR"] = compiler_path + "ar"
+    env["RANLIB"] = compiler_path + "ranlib"
+
+    ## Compile flags
+
+    if env["simulator"]:
+        detect_darwin_sdk_path("visionossimulator", env)
+        env.Append(ASFLAGS=["-mtargetos=xros2.0-simulator"])
+        env.Append(CCFLAGS=["-mtargetos=xros2.0-simulator"])
+        env.Append(CPPDEFINES=["VISIONOS_SIMULATOR"])
+        env.extra_suffix = ".simulator" + env.extra_suffix
+    else:
+        detect_darwin_sdk_path("visionos", env)
+        env.Append(ASFLAGS=["-mtargetos=xros2.0"])
+        env.Append(CCFLAGS=["-mtargetos=xros2.0"])
+
+    if env["arch"] == "arm64":
+        env.Append(
+            CCFLAGS=(
+                "-fobjc-arc -arch arm64 -fmessage-length=0"
+                " -fdiagnostics-print-source-range-info -fdiagnostics-show-category=id -fdiagnostics-parseable-fixits"
+                " -fpascal-strings -fblocks -fvisibility=hidden -MMD -MT dependencies"
+                " -isysroot $VISIONOS_SDK_PATH".split()
+            )
+        )
+        env.Append(ASFLAGS=["-arch", "arm64"])
+
+    # Temp fix for ABS/MAX/MIN macros in visionOS SDK blocking compilation
+    env.Append(CCFLAGS=["-Wno-ambiguous-macro"])
+
+    env.Prepend(
+        CPPPATH=[
+            "$VISIONOS_SDK_PATH/usr/include",
+            "$VISIONOS_SDK_PATH/System/Library/Frameworks/AudioUnit.framework/Headers",
+        ]
+    )
+
+    env.Prepend(CPPPATH=["#platform/visionos"])
+    env.Append(CPPDEFINES=["VISIONOS_ENABLED", "APPLE_EMBEDDED_ENABLED", "UNIX_ENABLED", "COREAUDIO_ENABLED"])
+
+    if env["vulkan"]:
+        print_warning("The visionOS platform does not support the Vulkan rendering driver")
+        env["vulkan"] = False
+
+    if env["metal"] and env["simulator"]:
+        print_warning("visionOS Simulator does not support the Metal rendering driver")
+        env["metal"] = False
+
+    if env["metal"]:
+        env.AppendUnique(CPPDEFINES=["METAL_ENABLED", "RD_ENABLED"])
+        env.Prepend(
+            CPPPATH=[
+                "$VISIONOS_SDK_PATH/System/Library/Frameworks/Metal.framework/Headers",
+                "$VISIONOS_SDK_PATH/System/Library/Frameworks/MetalFX.framework/Headers",
+                "$VISIONOS_SDK_PATH/System/Library/Frameworks/QuartzCore.framework/Headers",
+            ]
+        )
+        env.Prepend(CPPPATH=["#thirdparty/spirv-cross"])
+
+    if env["opengl3"]:
+        print_warning("The visionOS platform does not support the OpenGL rendering driver")
+        env["opengl3"] = False

+ 36 - 0
platform/visionos/display_layer_visionos.h

@@ -0,0 +1,36 @@
+/**************************************************************************/
+/*  display_layer_visionos.h                                              */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#include "drivers/apple_embedded/display_layer_apple_embedded.h"
+
+@interface GDTMetalLayer : CAMetalLayer <GDTDisplayLayer>
+@end

+ 47 - 0
platform/visionos/display_layer_visionos.mm

@@ -0,0 +1,47 @@
+/**************************************************************************/
+/*  display_layer_visionos.mm                                             */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#import "display_layer_visionos.h"
+
+@implementation GDTMetalLayer
+
+- (void)initializeDisplayLayer {
+}
+
+- (void)layoutDisplayLayer {
+}
+
+- (void)startRenderDisplayLayer {
+}
+
+- (void)stopRenderDisplayLayer {
+}
+
+@end

+ 54 - 0
platform/visionos/display_server_visionos.h

@@ -0,0 +1,54 @@
+/**************************************************************************/
+/*  display_server_visionos.h                                             */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#include "drivers/apple_embedded/display_server_apple_embedded.h"
+
+class DisplayServerVisionOS : public DisplayServerAppleEmbedded {
+	GDSOFTCLASS(DisplayServerVisionOS, DisplayServerAppleEmbedded);
+
+	_THREAD_SAFE_CLASS_
+
+	DisplayServerVisionOS(const String &p_rendering_driver, DisplayServer::WindowMode p_mode, DisplayServer::VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i *p_position, const Vector2i &p_resolution, int p_screen, Context p_context, int64_t p_parent_window, Error &r_error);
+	~DisplayServerVisionOS();
+
+public:
+	static DisplayServerVisionOS *get_singleton();
+
+	static void register_visionos_driver();
+	static DisplayServer *create_func(const String &p_rendering_driver, WindowMode p_mode, DisplayServer::VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i *p_position, const Vector2i &p_resolution, int p_screen, Context p_context, int64_t p_parent_window, Error &r_error);
+
+	virtual String get_name() const override;
+
+	virtual int screen_get_dpi(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
+	virtual float screen_get_scale(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
+	virtual float screen_get_refresh_rate(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
+};

+ 67 - 0
platform/visionos/display_server_visionos.mm

@@ -0,0 +1,67 @@
+/**************************************************************************/
+/*  display_server_visionos.mm                                            */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#import "display_server_visionos.h"
+
+DisplayServerVisionOS *DisplayServerVisionOS::get_singleton() {
+	return (DisplayServerVisionOS *)DisplayServerAppleEmbedded::get_singleton();
+}
+
+DisplayServerVisionOS::DisplayServerVisionOS(const String &p_rendering_driver, WindowMode p_mode, DisplayServer::VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i *p_position, const Vector2i &p_resolution, int p_screen, Context p_context, int64_t p_parent_window, Error &r_error) :
+		DisplayServerAppleEmbedded(p_rendering_driver, p_mode, p_vsync_mode, p_flags, p_position, p_resolution, p_screen, p_context, p_parent_window, r_error) {
+}
+
+DisplayServerVisionOS::~DisplayServerVisionOS() {
+}
+
+DisplayServer *DisplayServerVisionOS::create_func(const String &p_rendering_driver, WindowMode p_mode, DisplayServer::VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i *p_position, const Vector2i &p_resolution, int p_screen, Context p_context, int64_t p_parent_window, Error &r_error) {
+	return memnew(DisplayServerVisionOS(p_rendering_driver, p_mode, p_vsync_mode, p_flags, p_position, p_resolution, p_screen, p_context, p_parent_window, r_error));
+}
+
+void DisplayServerVisionOS::register_visionos_driver() {
+	register_create_function("visionOS", create_func, get_rendering_drivers_func);
+}
+
+String DisplayServerVisionOS::get_name() const {
+	return "visionOS";
+}
+
+int DisplayServerVisionOS::screen_get_dpi(int p_screen) const {
+	// TODO(Apple): Compute this properly from SwiftUI Metric APIs
+	return 72;
+}
+
+float DisplayServerVisionOS::screen_get_refresh_rate(int p_screen) const {
+	return 90;
+}
+
+float DisplayServerVisionOS::screen_get_scale(int p_screen) const {
+	return 1;
+}

+ 588 - 0
platform/visionos/doc_classes/EditorExportPlatformVisionOS.xml

@@ -0,0 +1,588 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="EditorExportPlatformVisionOS" inherits="EditorExportPlatformAppleEmbedded" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+	<brief_description>
+		Exporter for visionOS.
+	</brief_description>
+	<description>
+	</description>
+	<tutorials>
+		<link title="Exporting for iOS">$DOCS_URL/tutorials/export/exporting_for_ios.html</link>
+		<link title="iOS plugins documentation index">$DOCS_URL/tutorials/platform/ios/index.html</link>
+	</tutorials>
+	<members>
+		<member name="application/additional_plist_content" type="String" setter="" getter="">
+			Additional data added to the root [code]&lt;dict&gt;[/code] section of the [url=https://developer.apple.com/documentation/bundleresources/information_property_list]Info.plist[/url] file. The value should be an XML section with pairs of key-value elements, e.g.:
+			[codeblock lang=text]
+			&lt;key&gt;key_name&lt;/key&gt;
+			&lt;string&gt;value&lt;/string&gt;
+			[/codeblock]
+		</member>
+		<member name="application/app_store_team_id" type="String" setter="" getter="">
+			Apple Team ID, unique 10-character string. To locate your Team ID check "Membership details" section in your Apple developer account dashboard, or "Organizational Unit" of your code signing certificate. See [url=https://developer.apple.com/help/account/manage-your-team/locate-your-team-id]Locate your Team ID[/url].
+		</member>
+		<member name="application/bundle_identifier" type="String" setter="" getter="">
+			Unique application identifier in a reverse-DNS format, can only contain alphanumeric characters ([code]A-Z[/code], [code]a-z[/code], and [code]0-9[/code]), hyphens ([code]-[/code]), and periods ([code].[/code]).
+		</member>
+		<member name="application/code_sign_identity_debug" type="String" setter="" getter="">
+			The "Full Name", "Common Name" or SHA-1 hash of the signing identity used for debug export.
+		</member>
+		<member name="application/code_sign_identity_release" type="String" setter="" getter="">
+			The "Full Name", "Common Name" or SHA-1 hash of the signing identity used for release export.
+		</member>
+		<member name="application/delete_old_export_files_unconditionally" type="bool" setter="" getter="">
+			If [code]true[/code], existing "project name" and "project name.xcodeproj" in the export destination directory will be unconditionally deleted during export.
+		</member>
+		<member name="application/export_method_debug" type="int" setter="" getter="">
+			Application distribution target (debug export).
+		</member>
+		<member name="application/export_method_release" type="int" setter="" getter="">
+			Application distribution target (release export).
+		</member>
+		<member name="application/export_project_only" type="bool" setter="" getter="">
+			If [code]true[/code], exports iOS project files without building an XCArchive or [code].ipa[/code] file. If [code]false[/code], exports iOS project files and builds an XCArchive and [code].ipa[/code] file at the same time. When combining Godot with Fastlane or other build pipelines, you may want to set this to [code]true[/code].
+		</member>
+		<member name="application/icon_interpolation" type="int" setter="" getter="">
+			Interpolation method used to resize application icon.
+		</member>
+		<member name="application/min_visionos_version" type="String" setter="" getter="">
+		</member>
+		<member name="application/provisioning_profile_specifier_debug" type="String" setter="" getter="">
+			Name of the provisioning profile. Sets XCode PROVISIONING_PROFILE_SPECIFIER for debug. [url=https://developer.apple.com/documentation/xcode/build-settings-reference#Provisioning-Profile]Used for manual provisioning[/url].
+			Can be overridden with the environment variable [code]GODOT_APPLE_PLATFORM_PROFILE_SPECIFIER_DEBUG[/code].
+		</member>
+		<member name="application/provisioning_profile_specifier_release" type="String" setter="" getter="">
+			Name of the provisioning profile. Sets XCode PROVISIONING_PROFILE_SPECIFIER for release. [url=https://developer.apple.com/documentation/xcode/build-settings-reference#Provisioning-Profile]Used for manual provisioning[/url].
+			Can be overridden with the environment variable [code]GODOT_APPLE_PLATFORM_PROFILE_SPECIFIER_RELEASE[/code].
+		</member>
+		<member name="application/provisioning_profile_uuid_debug" type="String" setter="" getter="">
+			UUID of the provisioning profile. If left empty, Xcode will download or create a provisioning profile automatically. See [url=https://developer.apple.com/help/account/manage-profiles/edit-download-or-delete-profiles]Edit, download, or delete provisioning profiles[/url].
+			Can be overridden with the environment variable [code]GODOT_APPLE_PLATFORM_PROVISIONING_PROFILE_UUID_DEBUG[/code].
+		</member>
+		<member name="application/provisioning_profile_uuid_release" type="String" setter="" getter="">
+			UUID of the provisioning profile. If left empty, Xcode will download or create a provisioning profile automatically. See [url=https://developer.apple.com/help/account/manage-profiles/edit-download-or-delete-profiles]Edit, download, or delete provisioning profiles[/url].
+			Can be overridden with the environment variable [code]GODOT_APPLE_PLATFORM_PROVISIONING_PROFILE_UUID_RELEASE[/code].
+		</member>
+		<member name="application/short_version" type="String" setter="" getter="">
+			Application version visible to the user, can only contain numeric characters ([code]0-9[/code]) and periods ([code].[/code]). Falls back to [member ProjectSettings.application/config/version] if left empty.
+		</member>
+		<member name="application/signature" type="String" setter="" getter="">
+			A four-character creator code that is specific to the bundle. Optional.
+		</member>
+		<member name="application/version" type="String" setter="" getter="">
+			Machine-readable application version, in the [code]major.minor.patch[/code] format, can only contain numeric characters ([code]0-9[/code]) and periods ([code].[/code]). This must be incremented on every new release pushed to the App Store.
+		</member>
+		<member name="architectures/arm64" type="bool" setter="" getter="">
+			If [code]true[/code], [code]arm64[/code] binaries are included into exported project.
+		</member>
+		<member name="capabilities/access_wifi" type="bool" setter="" getter="">
+			If [code]true[/code], networking features related to Wi-Fi access are enabled. See [url=https://developer.apple.com/support/required-device-capabilities/]Required Device Capabilities[/url].
+		</member>
+		<member name="capabilities/additional" type="PackedStringArray" setter="" getter="">
+			Additional data added to the [code]UIRequiredDeviceCapabilities[/code] array of the [code]Info.plist[/code] file.
+		</member>
+		<member name="capabilities/performance_a12" type="bool" setter="" getter="">
+			Requires the graphics performance and features of the A12 Bionic and later chips (devices supporting all Vulkan renderer features).
+			Enabling this option limits supported devices to: iPhone XS, iPhone XR, iPad Mini (5th gen.), iPad Air (3rd gen.), iPad (8th gen) and newer.
+		</member>
+		<member name="capabilities/performance_gaming_tier" type="bool" setter="" getter="">
+			Requires the graphics performance and features of the A17 Pro and later chips.
+			Enabling this option limits supported devices to: iPhone 15 Pro and newer.
+		</member>
+		<member name="custom_template/debug" type="String" setter="" getter="">
+			Path to the custom export template. If left empty, default template is used.
+		</member>
+		<member name="custom_template/release" type="String" setter="" getter="">
+			Path to the custom export template. If left empty, default template is used.
+		</member>
+		<member name="entitlements/additional" type="String" setter="" getter="">
+			Additional data added to the root [code]&lt;dict&gt;[/code] section of the [url=https://developer.apple.com/documentation/bundleresources/entitlements].entitlements[/url] file. The value should be an XML section with pairs of key-value elements, for example:
+			[codeblock lang=text]
+			&lt;key&gt;key_name&lt;/key&gt;
+			&lt;string&gt;value&lt;/string&gt;
+			[/codeblock]
+		</member>
+		<member name="entitlements/game_center" type="bool" setter="" getter="">
+			If [code]true[/code], allows access to Game Center features. See [url=https://developer.apple.com/documentation/bundleresources/entitlements/com_apple_developer_game-center]com.apple.developer.game-center[/url].
+		</member>
+		<member name="entitlements/increased_memory_limit" type="bool" setter="" getter="">
+			If [code]true[/code], hints that the app might perform better with a higher memory limit. See [url=https://developer.apple.com/documentation/bundleresources/entitlements/com_apple_developer_kernel_increased-memory-limit]com.apple.developer.kernel.increased-memory-limit[/url].
+		</member>
+		<member name="entitlements/push_notifications" type="String" setter="" getter="">
+			Environment for Apple Push Notification service. See [url=https://developer.apple.com/documentation/bundleresources/entitlements/aps-environment]aps-environment[/url].
+		</member>
+		<member name="icons/icon_1024x1024" type="String" setter="" getter="">
+			Base application icon used to generate other icons. If left empty, it will fallback to [member ProjectSettings.application/config/icon]. See [url=https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons]App icons[/url].
+		</member>
+		<member name="icons/icon_1024x1024_dark" type="String" setter="" getter="">
+			Base application icon used to generate other icons, dark version. See [url=https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons]App icons[/url].
+		</member>
+		<member name="icons/icon_1024x1024_tinted" type="String" setter="" getter="">
+			Base application icon used to generate other icons, tinted version. See [url=https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons]App icons[/url].
+		</member>
+		<member name="privacy/active_keyboard_access_reasons" type="int" setter="" getter="">
+			The reasons your app use active keyboard API. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api]Describing use of required reason API[/url].
+		</member>
+		<member name="privacy/camera_usage_description" type="String" setter="" getter="">
+			A message displayed when requesting access to the device's camera (in English).
+		</member>
+		<member name="privacy/camera_usage_description_localized" type="Dictionary" setter="" getter="">
+			A message displayed when requesting access to the device's camera (localized).
+		</member>
+		<member name="privacy/collected_data/advertising_data/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects advertising data.
+		</member>
+		<member name="privacy/collected_data/advertising_data/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects advertising data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/advertising_data/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links advertising data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/advertising_data/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses advertising data for tracking.
+		</member>
+		<member name="privacy/collected_data/audio_data/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects audio data.
+		</member>
+		<member name="privacy/collected_data/audio_data/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects audio data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/audio_data/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links audio data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/audio_data/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses audio data for tracking.
+		</member>
+		<member name="privacy/collected_data/browsing_history/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects browsing history.
+		</member>
+		<member name="privacy/collected_data/browsing_history/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects browsing history. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/browsing_history/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links browsing history to the user's identity.
+		</member>
+		<member name="privacy/collected_data/browsing_history/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses browsing history for tracking.
+		</member>
+		<member name="privacy/collected_data/coarse_location/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects coarse location data.
+		</member>
+		<member name="privacy/collected_data/coarse_location/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects coarse location data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/coarse_location/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links coarse location data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/coarse_location/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses coarse location data for tracking.
+		</member>
+		<member name="privacy/collected_data/contacts/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects contacts.
+		</member>
+		<member name="privacy/collected_data/contacts/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects contacts. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/contacts/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links contacts to the user's identity.
+		</member>
+		<member name="privacy/collected_data/contacts/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses contacts for tracking.
+		</member>
+		<member name="privacy/collected_data/crash_data/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects crash data.
+		</member>
+		<member name="privacy/collected_data/crash_data/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects crash data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/crash_data/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links crash data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/crash_data/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses crash data for tracking.
+		</member>
+		<member name="privacy/collected_data/credit_info/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects credit information.
+		</member>
+		<member name="privacy/collected_data/credit_info/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects credit information. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/credit_info/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links credit information to the user's identity.
+		</member>
+		<member name="privacy/collected_data/credit_info/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses credit information for tracking.
+		</member>
+		<member name="privacy/collected_data/customer_support/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects customer support data.
+		</member>
+		<member name="privacy/collected_data/customer_support/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects customer support data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/customer_support/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links customer support data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/customer_support/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses customer support data for tracking.
+		</member>
+		<member name="privacy/collected_data/device_id/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects device IDs.
+		</member>
+		<member name="privacy/collected_data/device_id/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects device IDs. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/device_id/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links device IDs to the user's identity.
+		</member>
+		<member name="privacy/collected_data/device_id/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses device IDs for tracking.
+		</member>
+		<member name="privacy/collected_data/email_address/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects email address.
+		</member>
+		<member name="privacy/collected_data/email_address/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects email address. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/email_address/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links email address to the user's identity.
+		</member>
+		<member name="privacy/collected_data/email_address/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses email address for tracking.
+		</member>
+		<member name="privacy/collected_data/emails_or_text_messages/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects emails or text messages.
+		</member>
+		<member name="privacy/collected_data/emails_or_text_messages/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects emails or text messages. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/emails_or_text_messages/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links emails or text messages to the user's identity.
+		</member>
+		<member name="privacy/collected_data/emails_or_text_messages/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses emails or text messages for tracking.
+		</member>
+		<member name="privacy/collected_data/environment_scanning/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects environment scanning data.
+		</member>
+		<member name="privacy/collected_data/environment_scanning/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects environment scanning data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/environment_scanning/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links environment scanning data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/environment_scanning/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses environment scanning data for tracking.
+		</member>
+		<member name="privacy/collected_data/fitness/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects fitness and exercise data.
+		</member>
+		<member name="privacy/collected_data/fitness/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects fitness and exercise data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/fitness/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links fitness and exercise data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/fitness/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses fitness and exercise data for tracking.
+		</member>
+		<member name="privacy/collected_data/gameplay_content/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects gameplay content.
+		</member>
+		<member name="privacy/collected_data/gameplay_content/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects gameplay content. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/gameplay_content/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links gameplay content to the user's identity.
+		</member>
+		<member name="privacy/collected_data/gameplay_content/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses gameplay content for tracking.
+		</member>
+		<member name="privacy/collected_data/hands/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects user's hand structure and hand movements.
+		</member>
+		<member name="privacy/collected_data/hands/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects user's hand structure and hand movements. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/hands/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links user's hand structure and hand movements to the user's identity.
+		</member>
+		<member name="privacy/collected_data/hands/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses user's hand structure and hand movements for tracking.
+		</member>
+		<member name="privacy/collected_data/head/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects user's head movement.
+		</member>
+		<member name="privacy/collected_data/head/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects user's head movement. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/head/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links user's head movement to the user's identity.
+		</member>
+		<member name="privacy/collected_data/head/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses user's head movement for tracking.
+		</member>
+		<member name="privacy/collected_data/health/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects health and medical data.
+		</member>
+		<member name="privacy/collected_data/health/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects health and medical data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/health/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links health and medical data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/health/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses health and medical data for tracking.
+		</member>
+		<member name="privacy/collected_data/name/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects user's name.
+		</member>
+		<member name="privacy/collected_data/name/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects user's name. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/name/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links user's name to the user's identity.
+		</member>
+		<member name="privacy/collected_data/name/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses user's name for tracking.
+		</member>
+		<member name="privacy/collected_data/other_contact_info/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects any other contact information.
+		</member>
+		<member name="privacy/collected_data/other_contact_info/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects any other contact information. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/other_contact_info/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links any other contact information to the user's identity.
+		</member>
+		<member name="privacy/collected_data/other_contact_info/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses any other contact information for tracking.
+		</member>
+		<member name="privacy/collected_data/other_data_types/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects any other data.
+		</member>
+		<member name="privacy/collected_data/other_data_types/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects any other data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/other_data_types/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links any other data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/other_data_types/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses any other data for tracking.
+		</member>
+		<member name="privacy/collected_data/other_diagnostic_data/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects any other diagnostic data.
+		</member>
+		<member name="privacy/collected_data/other_diagnostic_data/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects any other diagnostic data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/other_diagnostic_data/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links any other diagnostic data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/other_diagnostic_data/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses any other diagnostic data for tracking.
+		</member>
+		<member name="privacy/collected_data/other_financial_info/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects any other financial information.
+		</member>
+		<member name="privacy/collected_data/other_financial_info/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects any other financial information. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/other_financial_info/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links any other financial information to the user's identity.
+		</member>
+		<member name="privacy/collected_data/other_financial_info/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses any other financial information for tracking.
+		</member>
+		<member name="privacy/collected_data/other_usage_data/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects any other usage data.
+		</member>
+		<member name="privacy/collected_data/other_usage_data/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects any other usage data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/other_usage_data/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links any other usage data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/other_usage_data/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses any other usage data for tracking.
+		</member>
+		<member name="privacy/collected_data/other_user_content/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects any other user generated content.
+		</member>
+		<member name="privacy/collected_data/other_user_content/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects any other user generated content. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/other_user_content/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links any other user generated content to the user's identity.
+		</member>
+		<member name="privacy/collected_data/other_user_content/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses any other user generated content for tracking.
+		</member>
+		<member name="privacy/collected_data/payment_info/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects payment information.
+		</member>
+		<member name="privacy/collected_data/payment_info/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects payment information. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/payment_info/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links payment information to the user's identity.
+		</member>
+		<member name="privacy/collected_data/payment_info/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses payment information for tracking.
+		</member>
+		<member name="privacy/collected_data/performance_data/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects performance data.
+		</member>
+		<member name="privacy/collected_data/performance_data/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects performance data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/performance_data/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links performance data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/performance_data/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses performance data for tracking.
+		</member>
+		<member name="privacy/collected_data/phone_number/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects phone number.
+		</member>
+		<member name="privacy/collected_data/phone_number/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects phone number. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/phone_number/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links phone number to the user's identity.
+		</member>
+		<member name="privacy/collected_data/phone_number/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses phone number for tracking.
+		</member>
+		<member name="privacy/collected_data/photos_or_videos/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects photos or videos.
+		</member>
+		<member name="privacy/collected_data/photos_or_videos/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects photos or videos. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/photos_or_videos/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links photos or videos to the user's identity.
+		</member>
+		<member name="privacy/collected_data/photos_or_videos/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses photos or videos for tracking.
+		</member>
+		<member name="privacy/collected_data/physical_address/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects physical address.
+		</member>
+		<member name="privacy/collected_data/physical_address/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects physical address. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/physical_address/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links physical address to the user's identity.
+		</member>
+		<member name="privacy/collected_data/physical_address/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses physical address for tracking.
+		</member>
+		<member name="privacy/collected_data/precise_location/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects precise location data.
+		</member>
+		<member name="privacy/collected_data/precise_location/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects precise location data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/precise_location/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links precise location data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/precise_location/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses precise location data for tracking.
+		</member>
+		<member name="privacy/collected_data/product_interaction/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects product interaction data.
+		</member>
+		<member name="privacy/collected_data/product_interaction/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects product interaction data. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/product_interaction/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links product interaction data to the user's identity.
+		</member>
+		<member name="privacy/collected_data/product_interaction/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses product interaction data for tracking.
+		</member>
+		<member name="privacy/collected_data/purchase_history/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects purchase history.
+		</member>
+		<member name="privacy/collected_data/purchase_history/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects purchase history. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/purchase_history/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links purchase history to the user's identity.
+		</member>
+		<member name="privacy/collected_data/purchase_history/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses purchase history for tracking.
+		</member>
+		<member name="privacy/collected_data/search_hhistory/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects search history.
+		</member>
+		<member name="privacy/collected_data/search_hhistory/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects search history. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/search_hhistory/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links search history to the user's identity.
+		</member>
+		<member name="privacy/collected_data/search_hhistory/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses search history for tracking.
+		</member>
+		<member name="privacy/collected_data/sensitive_info/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects sensitive user information.
+		</member>
+		<member name="privacy/collected_data/sensitive_info/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects sensitive user information. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/sensitive_info/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links sensitive user information to the user's identity.
+		</member>
+		<member name="privacy/collected_data/sensitive_info/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses sensitive user information for tracking.
+		</member>
+		<member name="privacy/collected_data/user_id/collected" type="bool" setter="" getter="">
+			Indicates whether your app collects user IDs.
+		</member>
+		<member name="privacy/collected_data/user_id/collection_purposes" type="int" setter="" getter="">
+			The reasons your app collects user IDs. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests]Describing data use in privacy manifests[/url].
+		</member>
+		<member name="privacy/collected_data/user_id/linked_to_user" type="bool" setter="" getter="">
+			Indicates whether your app links user IDs to the user's identity.
+		</member>
+		<member name="privacy/collected_data/user_id/used_for_tracking" type="bool" setter="" getter="">
+			Indicates whether your app uses user IDs for tracking.
+		</member>
+		<member name="privacy/disk_space_access_reasons" type="int" setter="" getter="">
+			The reasons your app use free disk space API. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api]Describing use of required reason API[/url].
+		</member>
+		<member name="privacy/file_timestamp_access_reasons" type="int" setter="" getter="">
+			The reasons your app use file timestamp/metadata API. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api]Describing use of required reason API[/url].
+		</member>
+		<member name="privacy/microphone_usage_description" type="String" setter="" getter="">
+			A message displayed when requesting access to the device's microphone (in English).
+		</member>
+		<member name="privacy/microphone_usage_description_localized" type="Dictionary" setter="" getter="">
+			A message displayed when requesting access to the device's microphone (localized).
+		</member>
+		<member name="privacy/photolibrary_usage_description" type="String" setter="" getter="">
+			A message displayed when requesting access to the user's photo library (in English).
+		</member>
+		<member name="privacy/photolibrary_usage_description_localized" type="Dictionary" setter="" getter="">
+			A message displayed when requesting access to the user's photo library (localized).
+		</member>
+		<member name="privacy/system_boot_time_access_reasons" type="int" setter="" getter="">
+			The reasons your app use system boot time / absolute time API. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api]Describing use of required reason API[/url].
+		</member>
+		<member name="privacy/tracking_domains" type="PackedStringArray" setter="" getter="">
+			The list of internet domains your app connects to that engage in tracking. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files]Privacy manifest files[/url].
+		</member>
+		<member name="privacy/tracking_enabled" type="bool" setter="" getter="">
+			Indicates whether your app uses data for tracking. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files]Privacy manifest files[/url].
+		</member>
+		<member name="privacy/user_defaults_access_reasons" type="int" setter="" getter="">
+			The reasons your app use user defaults API. See [url=https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api]Describing use of required reason API[/url].
+		</member>
+		<member name="user_data/accessible_from_files_app" type="bool" setter="" getter="">
+			If [code]true[/code], the app "Documents" folder can be accessed via "Files" app. See [url=https://developer.apple.com/documentation/bundleresources/information_property_list/lssupportsopeningdocumentsinplace]LSSupportsOpeningDocumentsInPlace[/url].
+		</member>
+		<member name="user_data/accessible_from_itunes_sharing" type="bool" setter="" getter="">
+			If [code]true[/code], the app "Documents" folder can be accessed via iTunes file sharing. See [url=https://developer.apple.com/documentation/bundleresources/information_property_list/uifilesharingenabled]UIFileSharingEnabled[/url].
+		</member>
+	</members>
+</class>

+ 46 - 0
platform/visionos/export/export.cpp

@@ -0,0 +1,46 @@
+/**************************************************************************/
+/*  export.cpp                                                            */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#include "export.h"
+
+#include "export_plugin.h"
+
+#include "editor/export/editor_export.h"
+
+void register_visionos_exporter_types() {
+	GDREGISTER_VIRTUAL_CLASS(EditorExportPlatformVisionOS);
+}
+
+void register_visionos_exporter() {
+	Ref<EditorExportPlatformVisionOS> platform;
+	platform.instantiate();
+
+	EditorExport::get_singleton()->add_export_platform(platform);
+}

+ 34 - 0
platform/visionos/export/export.h

@@ -0,0 +1,34 @@
+/**************************************************************************/
+/*  export.h                                                              */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+void register_visionos_exporter_types();
+void register_visionos_exporter();

+ 51 - 0
platform/visionos/export/export_plugin.cpp

@@ -0,0 +1,51 @@
+/**************************************************************************/
+/*  export_plugin.cpp                                                     */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#include "export_plugin.h"
+
+#include "logo_svg.gen.h"
+#include "run_icon_svg.gen.h"
+
+EditorExportPlatformVisionOS::EditorExportPlatformVisionOS() :
+		EditorExportPlatformAppleEmbedded(_visionos_logo_svg, _visionos_run_icon_svg) {
+}
+
+EditorExportPlatformVisionOS::~EditorExportPlatformVisionOS() {
+}
+
+void EditorExportPlatformVisionOS::get_export_options(List<ExportOption> *r_options) const {
+	EditorExportPlatformAppleEmbedded::get_export_options(r_options);
+
+	r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/min_visionos_version"), get_minimum_deployment_target()));
+}
+
+Vector<EditorExportPlatformAppleEmbedded::IconInfo> EditorExportPlatformVisionOS::get_icon_infos() const {
+	return Vector<EditorExportPlatformAppleEmbedded::IconInfo>();
+}

+ 59 - 0
platform/visionos/export/export_plugin.h

@@ -0,0 +1,59 @@
+/**************************************************************************/
+/*  export_plugin.h                                                       */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#include "editor/export/editor_export_platform_apple_embedded.h"
+
+class EditorExportPlatformVisionOS : public EditorExportPlatformAppleEmbedded {
+	GDCLASS(EditorExportPlatformVisionOS, EditorExportPlatformAppleEmbedded);
+
+	virtual String get_platform_name() const override { return "visionos"; }
+
+	virtual String get_sdk_name() const override { return "xros"; }
+
+	virtual String get_minimum_deployment_target() const override { return "2.0"; }
+
+	virtual Vector<EditorExportPlatformAppleEmbedded::IconInfo> get_icon_infos() const override;
+
+	virtual void get_export_options(List<ExportOption> *r_options) const override;
+
+public:
+	virtual String get_name() const override { return "visionOS"; }
+	virtual String get_os_name() const override { return "visionOS"; }
+
+	virtual void get_platform_features(List<String> *r_features) const override {
+		EditorExportPlatformAppleEmbedded::get_platform_features(r_features);
+		r_features->push_back("visionos");
+	}
+
+	EditorExportPlatformVisionOS();
+	~EditorExportPlatformVisionOS();
+};

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 0
platform/visionos/export/logo.svg


+ 1 - 0
platform/visionos/export/run_icon.svg

@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16"><path fill="#fff" d="M.462 11.653H1.72V6.296H.462Zm.627-6.059a.687.687 0 0 0 .702-.682.688.688 0 0 0-.702-.687.687.687 0 0 0-.698.687c0 .38.309.682.698.682zM5.91 4.24c-2.127 0-3.461 1.45-3.461 3.77 0 2.32 1.333 3.765 3.461 3.765 2.123 0 3.457-1.445 3.457-3.765 0-2.32-1.334-3.77-3.457-3.77zm0 1.112c1.299 0 2.128 1.03 2.128 2.658 0 1.622-.829 2.653-2.128 2.653-1.304 0-2.127-1.03-2.127-2.653 0-1.627.823-2.658 2.127-2.658zm3.988 4.25c.055 1.344 1.157 2.173 2.835 2.173 1.764 0 2.876-.87 2.876-2.254 0-1.086-.627-1.698-2.108-2.037l-.839-.192c-.895-.212-1.263-.495-1.263-.98 0-.607.556-1.01 1.38-1.01.834 0 1.405.408 1.465 1.09h1.244c-.03-1.283-1.092-2.152-2.699-2.152-1.587 0-2.714.874-2.714 2.168 0 1.041.637 1.688 1.981 1.997l.945.222c.92.217 1.294.52 1.294 1.046 0 .606-.611 1.041-1.49 1.041-.89 0-1.562-.44-1.643-1.112H9.899Z"/></svg>

+ 37 - 0
platform/visionos/godot_view_visionos.h

@@ -0,0 +1,37 @@
+/**************************************************************************/
+/*  godot_view_visionos.mm                                                */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#include "drivers/apple_embedded/godot_view_apple_embedded.h"
+
+@interface GDTViewVisionOS : GDTView
+
+@end

+ 80 - 0
platform/visionos/godot_view_visionos.mm

@@ -0,0 +1,80 @@
+/**************************************************************************/
+/*  godot_view.mm                                                         */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#include "godot_view_visionos.h"
+
+#include "display_layer_visionos.h"
+
+#include "core/error/error_macros.h"
+
+#import <GameController/GameController.h>
+
+@interface GDTViewVisionOS ()
+
+GODOT_CLANG_WARNING_PUSH_AND_IGNORE("-Wobjc-property-synthesis")
+@property(strong, nonatomic) CALayer<GDTDisplayLayer> *renderingLayer;
+GODOT_CLANG_WARNING_POP
+
+@end
+
+@implementation GDTViewVisionOS
+
+- (void)godot_commonInit {
+	[super godot_commonInit];
+
+	// Enable GamePad handler
+	GCEventInteraction *gamepadInteraction = [[GCEventInteraction alloc] init];
+	gamepadInteraction.handledEventTypes = GCUIEventTypeGamepad;
+	[self addInteraction:gamepadInteraction];
+}
+
+- (CALayer<GDTDisplayLayer> *)initializeRenderingForDriver:(NSString *)driverName {
+	if (self.renderingLayer) {
+		return self.renderingLayer;
+	}
+
+	CALayer<GDTDisplayLayer> *layer = [GDTMetalLayer layer];
+
+	layer.frame = self.bounds;
+	layer.contentsScale = self.contentScaleFactor;
+
+	[self.layer addSublayer:layer];
+	self.renderingLayer = layer;
+
+	[layer initializeDisplayLayer];
+
+	return self.renderingLayer;
+}
+
+@end
+
+GDTView *GDTViewCreate() {
+	return [GDTViewVisionOS new];
+}

+ 89 - 0
platform/visionos/main_visionos.mm

@@ -0,0 +1,89 @@
+/**************************************************************************/
+/*  main.mm                                                               */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#import "os_visionos.h"
+
+#import "drivers/apple_embedded/godot_app_delegate.h"
+#import "drivers/apple_embedded/main_utilities.h"
+#include "main/main.h"
+
+#import <UIKit/UIKit.h>
+#include <cstdio>
+
+int gargc;
+char **gargv;
+
+static OS_VisionOS *os = nullptr;
+
+int main(int argc, char *argv[]) {
+#if defined(VULKAN_ENABLED)
+	//MoltenVK - enable full component swizzling support
+	setenv("MVK_CONFIG_FULL_IMAGE_VIEW_SWIZZLE", "1", 1);
+#endif
+
+	gargc = argc;
+	gargv = argv;
+
+	@autoreleasepool {
+		NSString *className = NSStringFromClass([GDTApplicationDelegate class]);
+		UIApplicationMain(argc, argv, nil, className);
+	}
+	return 0;
+}
+
+int apple_embedded_main(int argc, char **argv) {
+	change_to_launch_dir(argv);
+
+	os = new OS_VisionOS();
+
+	// We must override main when testing is enabled
+	TEST_MAIN_OVERRIDE
+
+	char *fargv[64];
+	argc = process_args(argc, argv, fargv);
+
+	Error err = Main::setup(fargv[0], argc - 1, &fargv[1], false);
+
+	if (err != OK) {
+		if (err == ERR_HELP) { // Returned by --help and --version, so success.
+			return EXIT_SUCCESS;
+		}
+		return EXIT_FAILURE;
+	}
+
+	os->initialize_modules();
+
+	return os->get_exit_code();
+}
+
+void apple_embedded_finish() {
+	Main::cleanup();
+	delete os;
+}

+ 47 - 0
platform/visionos/os_visionos.h

@@ -0,0 +1,47 @@
+/**************************************************************************/
+/*  os_visions.h                                                          */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#ifdef VISIONOS_ENABLED
+
+#import "drivers/apple_embedded/os_apple_embedded.h"
+
+class OS_VisionOS : public OS_AppleEmbedded {
+public:
+	static OS_VisionOS *get_singleton();
+
+	OS_VisionOS();
+	~OS_VisionOS();
+
+	virtual String get_name() const override;
+};
+
+#endif // VISIONOS_ENABLED

+ 52 - 0
platform/visionos/os_visionos.mm

@@ -0,0 +1,52 @@
+/**************************************************************************/
+/*  os_visionos.mm                                                        */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#import "os_visionos.h"
+
+#import "display_server_visionos.h"
+
+#ifdef VISIONOS_ENABLED
+
+OS_VisionOS *OS_VisionOS::get_singleton() {
+	return (OS_VisionOS *)OS_AppleEmbedded::get_singleton();
+}
+
+OS_VisionOS::OS_VisionOS() :
+		OS_AppleEmbedded() {
+	DisplayServerVisionOS::register_visionos_driver();
+}
+
+OS_VisionOS::~OS_VisionOS() {}
+
+String OS_VisionOS::get_name() const {
+	return "visionOS";
+}
+
+#endif // VISIONOS_ENABLED

+ 33 - 0
platform/visionos/platform_config.h

@@ -0,0 +1,33 @@
+/**************************************************************************/
+/*  platform_config.h                                                     */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#import "drivers/apple_embedded/platform_config.h"

+ 33 - 0
platform/visionos/platform_thread.h

@@ -0,0 +1,33 @@
+/**************************************************************************/
+/*  platform_thread.h                                                     */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#include "drivers/apple/thread_apple.h"

+ 7 - 0
platform/visionos/platform_visionos_builders.py

@@ -0,0 +1,7 @@
+"""Functions used to generate source files during build time"""
+
+from platform_methods import generate_bundle_apple_embedded
+
+
+def generate_bundle(target, source, env):
+    generate_bundle_apple_embedded("visionos", "xros-arm64", "xros-arm64-simulator", False, target, source, env)

+ 37 - 0
platform/visionos/visionos.h

@@ -0,0 +1,37 @@
+/**************************************************************************/
+/*  visionos.h                                                            */
+/**************************************************************************/
+/*                         This file is part of:                          */
+/*                             GODOT ENGINE                               */
+/*                        https://godotengine.org                         */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
+/*                                                                        */
+/* Permission is hereby granted, free of charge, to any person obtaining  */
+/* a copy of this software and associated documentation files (the        */
+/* "Software"), to deal in the Software without restriction, including    */
+/* without limitation the rights to use, copy, modify, merge, publish,    */
+/* distribute, sublicense, and/or sell copies of the Software, and to     */
+/* permit persons to whom the Software is furnished to do so, subject to  */
+/* the following conditions:                                              */
+/*                                                                        */
+/* The above copyright notice and this permission notice shall be         */
+/* included in all copies or substantial portions of the Software.        */
+/*                                                                        */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
+/**************************************************************************/
+
+#pragma once
+
+#include "drivers/apple_embedded/apple_embedded.h"
+
+class visionOS : public AppleEmbedded {
+	GDCLASS(visionOS, AppleEmbedded);
+};

+ 2 - 2
servers/rendering/renderer_rd/cluster_builder_rd.h

@@ -184,8 +184,8 @@ private:
 	};
 
 	uint32_t cluster_size = 32;
-#if defined(MACOS_ENABLED) || defined(IOS_ENABLED)
-	// Results in visual artifacts on macOS and iOS when using MSAA and subgroups.
+#if defined(MACOS_ENABLED) || defined(APPLE_EMBEDDED_ENABLED)
+	// Results in visual artifacts on macOS and iOS/visionOS when using MSAA and subgroups.
 	// Using subgroups and disabling MSAA is the optimal solution for now and also works
 	// with MoltenVK.
 	bool use_msaa = false;

+ 8 - 0
servers/rendering/renderer_rd/effects/metal_fx.h

@@ -30,6 +30,10 @@
 
 #pragma once
 
+#if defined(METAL_ENABLED) && !defined(VISIONOS_ENABLED)
+#define METAL_MFXTEMPORAL_ENABLED
+#endif
+
 #ifdef METAL_ENABLED
 
 #include "spatial_upscaler.h"
@@ -92,6 +96,8 @@ public:
 	~MFXSpatialEffect();
 };
 
+#ifdef METAL_MFXTEMPORAL_ENABLED
+
 struct MFXTemporalContext {
 #ifdef __OBJC__
 	id<MTLFXTemporalScaler> scaler = nullptr;
@@ -174,6 +180,8 @@ public:
 	void process(MFXTemporalContext *p_ctx, Params p_params);
 };
 
+#endif
+
 } //namespace RendererRD
 
 #endif // METAL_ENABLED

+ 4 - 0
servers/rendering/renderer_rd/effects/metal_fx.mm

@@ -123,6 +123,8 @@ MFXSpatialContext *MFXSpatialEffect::create_context(CreateParams p_params) const
 	return context;
 }
 
+#ifdef METAL_MFXTEMPORAL_ENABLED
+
 #pragma mark - Temporal Scaler
 
 MFXTemporalContext::~MFXTemporalContext() {}
@@ -219,3 +221,5 @@ void MFXTemporalEffect::callback(RDD *p_driver, RDD::CommandBufferID p_command_b
 
 	GODOT_CLANG_WARNING_POP
 }
+
+#endif

+ 6 - 6
servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.cpp

@@ -88,7 +88,7 @@ void RenderForwardClustered::RenderBufferDataForwardClustered::ensure_fsr2(Rende
 	}
 }
 
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 bool RenderForwardClustered::RenderBufferDataForwardClustered::ensure_mfx_temporal(RendererRD::MFXTemporalEffect *p_effect) {
 	if (mfx_temporal_context == nullptr) {
 		RendererRD::MFXTemporalEffect::CreateParams params;
@@ -127,7 +127,7 @@ void RenderForwardClustered::RenderBufferDataForwardClustered::free_data() {
 		fsr2_context = nullptr;
 	}
 
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 	if (mfx_temporal_context) {
 		memdelete(mfx_temporal_context);
 		mfx_temporal_context = nullptr;
@@ -1730,7 +1730,7 @@ void RenderForwardClustered::_render_scene(RenderDataRD *p_render_data, const Co
 			scale_type = SCALE_FSR2;
 			break;
 		case RS::VIEWPORT_SCALING_3D_MODE_METALFX_TEMPORAL:
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 			scale_type = SCALE_MFX;
 #else
 			scale_type = SCALE_NONE;
@@ -2444,7 +2444,7 @@ void RenderForwardClustered::_render_scene(RenderDataRD *p_render_data, const Co
 
 			RD::get_singleton()->draw_command_end_label();
 		} else if (scale_type == SCALE_MFX) {
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 			bool reset = rb_data->ensure_mfx_temporal(mfx_temporal_effect);
 
 			RID exposure;
@@ -5005,7 +5005,7 @@ RenderForwardClustered::RenderForwardClustered() {
 	taa = memnew(RendererRD::TAA);
 	fsr2_effect = memnew(RendererRD::FSR2Effect);
 	ss_effects = memnew(RendererRD::SSEffects);
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 	motion_vectors_store = memnew(RendererRD::MotionVectorsStore);
 	mfx_temporal_effect = memnew(RendererRD::MFXTemporalEffect);
 #endif
@@ -5027,7 +5027,7 @@ RenderForwardClustered::~RenderForwardClustered() {
 		fsr2_effect = nullptr;
 	}
 
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 	if (mfx_temporal_effect) {
 		memdelete(mfx_temporal_effect);
 		mfx_temporal_effect = nullptr;

+ 3 - 3
servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.h

@@ -95,7 +95,7 @@ public:
 	private:
 		RenderSceneBuffersRD *render_buffers = nullptr;
 		RendererRD::FSR2Context *fsr2_context = nullptr;
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 		RendererRD::MFXTemporalContext *mfx_temporal_context = nullptr;
 #endif
 
@@ -141,7 +141,7 @@ public:
 		void ensure_fsr2(RendererRD::FSR2Effect *p_effect);
 		RendererRD::FSR2Context *get_fsr2_context() const { return fsr2_context; }
 
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 		bool ensure_mfx_temporal(RendererRD::MFXTemporalEffect *p_effect);
 		RendererRD::MFXTemporalContext *get_mfx_temporal_context() const { return mfx_temporal_context; }
 #endif
@@ -719,7 +719,7 @@ private:
 	RendererRD::FSR2Effect *fsr2_effect = nullptr;
 	RendererRD::SSEffects *ss_effects = nullptr;
 
-#ifdef METAL_ENABLED
+#ifdef METAL_MFXTEMPORAL_ENABLED
 	RendererRD::MFXTemporalEffect *mfx_temporal_effect = nullptr;
 #endif
 	RendererRD::MotionVectorsStore *motion_vectors_store = nullptr;

Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно