In my VisionPro app, I'm facing a problem with loading USDZ models from a RealityKitBundle package, created using Reality Composer Pro.
It was working fine until I added more models to the package. As I added more models with large textures in the project, the app started to show them with texturing problems.
So, when I load the models from the RealityView using Entity(named:in)
, the mesh loads correctly, but all black, with no textures, as below:
However, when I load the same USDZ directly from the main bundle, using ModelEntity(named:in)
, it loads fine.
I know that large textures can cause memory issues, but when talking about one single model, I know that it's not enough to cause a memory overflow in the VisionPro. This USDZ model is about 40MB with something around 800MB of texture memory (from the RealityComposerPro Statistic tab).
I've built experiences in VisionPro with much heavier models, and they do present the same texture issues, but only after there's more than 3 huge models enabled in the Reality scene. But that's not the case. The un-textured model appears right from the beginning, so it seems to me that's not a runtime issue in the device, but rather some issue in the packaging process from RealityComposerPro to XCode to the Device, am I correct?
I'm also using a simple Mac Mini with M2 but only 8MB of RAM. Maybe that's the issue?
As I still want to use RealityComposerPro to build more dev-friendly and interesting applications, I'd really appreciate some guidance here!
Thanks in advance!