Realitykit asset loading

With Xcode 26, loading ressources with RealityKit is extremely slow.

Here my project takes almost 50 seconds to load. I also get multiple Hang detected messages in the console:

When I uncheck "Debug executable" in the schema, the same project loads in 2 seconds.

I'm using RealityKit asynchronous loading:

private static func loadFromRealityComposerPro(
        named entityName: String,
        fromSceneNamed sceneName: String
    ) async -> Entity? {
        var entity: Entity?
        do {
            let scene = try await Entity(
                named: sceneName,
                in: visionPetsContentBundle
            )
            entity = scene.findEntity(named: entityName)
        } catch {
            print(
                "Error loading \(entityName) from scene \(sceneName): \(error.localizedDescription)"
            )
        }
        return entity
    }

Anyone having the same problem?

Answered by DTS Engineer in 843081022

Hey @Gil,

Please file a bug report for this issue using Feedback Assistant, and include the scene you're loading if you can!

-- Greg

In case my message was not very clear, the issues occur when I run the app on the Vision Pro in Debug. In that case the app takes 50 seconds to load ressources versus 2 when I uncheck "Debug executable" in the scheme.

Hey @Gil,

Please file a bug report for this issue using Feedback Assistant, and include the scene you're loading if you can!

-- Greg

Realitykit asset loading
 
 
Q