PhysX
PhysX copied to clipboard
iOS platform support
What's new?
- Added iOS platform support to PhysX 5.1.
- New build preset
ios64
added. Initial support focused on 64-bit arm8 architecture with NEON SIMD instructions. - Support for generating PhysX as either static libraries or iOS frameworks.
- New iOS platform readme.
Out of Scope
The following points are considered out of scope, they can be added in the future:
- Support for PhysX Snippets.
- Support for Omniverse Visual Debugger (OmniPVD) .
- Support for other architectures: 32-bit arm7
Known Errors/Limitations
- The name of the bin folder for iOS will appear as
bin\UNKNOWN
. To fix this nVidia has to modify the CMakeModules package it's downloaded from packman when building PhysX. The file that needs to be modified isGetCompilerAndPlatform.cmake
, adding the following lines to theif
condition insideGetPlatformBinName
function:
ELSEIF(TARGET_BUILD_PLATFORM STREQUAL "ios")
SET(RETVAL "ios.arm_${LIBPATH_SUFFIX}")
- Python package used by packman is based on x86_64 architecture and generates the error
dyld[number]: missing symbol called
when run on an arm-based Mac. To fix this nVidia has to add an ARM python package for mac into the packman scripts. As a temporary solution, use your system's python adding the environment variablePM_PYTHON_EXT
before building (for example by addingexport PM_PYTHON_EXT="python3"
into your.bash_profile
file). - PhysX Systems that require a CUDA capable GPU are not supported in iOS, for example particle system or cloth simulation.
Testing
- Built PhysX 5.1 successfully on iOS in debug, checked, profile and release using
PX_GENERATE_STATIC_LIBRARIES
set to both true and false. The right output binaries were generated inbin/ios.arm_64
- Built cmake
install
target successfully. It generated the correct output for iOS underinstall/ios64
folder, only including necessary headers for iOS. - Runtime tested using
Open 3D Engine (O3DE)
with an early integration branch. The following video shows O3DE running PhysX 5.1 on iOS. https://user-images.githubusercontent.com/27999040/204574141-2e00c7bf-86b5-4e14-981f-6b80665a3ef7.mp4
Signed-off-by: moraaar [email protected]
iOS platform support has been submitted to the following PhysX fork where it will be maintained: https://github.com/o3de/PhysX
For more details see the following discussion: https://github.com/NVIDIA-Omniverse/PhysX/discussions/58