Error when adding usdz to rcproject

I am using the template Augmented Reality App and I have imported Apple's toy_robot_vintage.usdz into the Experience.rcproject file using Reality Composer. When I run the app, I have the following error:

_validateTextureView:557: failed assertion `Texture View Validation texture usage (0x01) doesn't specify MTLTextureUsagePixelFormatView (0x10)' warning: could not find Objective-C class data in the process. This may reduce the quality of type information available. (lldb)

There is a Thread1: signal SIGABRT error in the generated code for Experience.swift on the line: let anchorEntity = try Experience.Box.loadAnchor(contentsOf: realityFileSceneURL)

Any ideas on how I can approach this? Thanks in advance.    

Replies

Having had the same problem, I've found one (unsatisfying) workaround: unplugging the iPhone before starting the app works.

Since that does not seem to be very sensible behaviour, it is likely a bug and will (slightly less likely) be solved by some future update.

  • Thanks KarlKemp, 

    Unfortunately this didn’t work for me. I’ll raise a feedback item for this. 

Add a Comment

Hi, we are aware of this issue. You should be able to work around it by turning off Metal Validation in Scheme -> Edit Scheme -> Run -> Diagnostics -> Metal API Validation. Also @AlfieLeFeuvre I see your feedback item, let me know if the workaround works for you.

  • Yes, this works, thank you.

  • Encountered same problem running in simulator only. Did not get error running on real iPhone 12 Pro Max (ios 16.1.2) building with Xcode Version 14.1 (14B47b). Continues to run fine in real iPhone, or by starting installed app on simulator after crash when first built and started on simulator. Behavior in real iPhone (never get this error) unchanged regardless of whether "Metal API Validation" clicked on or off. Thank you very much for this fix.

Add a Comment