我正在使用 SwiftUI 和 Combine 开发一个应用程序。当我尝试打开/关闭几次暗模式时,我正面临崩溃。控制台打印的日志说:
precondition failure: attribute failed to set an initial value: 78
Run Code Online (Sandbox Code Playgroud)
堆栈跟踪中没有与崩溃起源相关的有价值的信息。
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT
frame #0: 0x00000001ba5d9ec4 libsystem_kernel.dylib`__pthread_kill + 8
frame #1: 0x00000001ba4f9c00 libsystem_pthread.dylib`pthread_kill$VARIANT$armv81 + 192
frame #2: 0x00000001ba449844 libsystem_c.dylib`abort + 100
frame #3: 0x00000001e4eae548 AttributeGraph`AG::precondition_failure(char const*, ...) + 188
frame #4: 0x00000001e4e80194 AttributeGraph`AG::Graph::UpdateStack::update() + 1320
frame #5: 0x00000001e4e80308 AttributeGraph`AG::Graph::update_attribute(unsigned int, bool) + 372
frame #6: 0x00000001e4e83874 AttributeGraph`AG::Graph::input_value_ref_slow(unsigned int, unsigned int, AGTypeID, bool*) + 212
frame #7: …Run Code Online (Sandbox Code Playgroud) 蓝牙设备断开连接时,应用崩溃。我见过一些相关主题,他们说
“通知委托未重置为nil。已在版本10.3.79中应用了修复程序。”
以下是崩溃日志:
Triggered by Thread: 0
Thread 0 name:
Thread 0 Crashed:
0 libobjc.A.dylib 0x000000018544c430 objc_msgSend + 16
1 ExternalAccessory 0x000000019c07c4dc -[EAAccessoryManager _notifyObserversThatAccessoryDisconnectedWithUserInfo:] + 104 (EAAccessoryManager.m:909)
2 ExternalAccessory 0x000000019c07eddc -[EAAccessoryManager _externalAccessoryDisconnected:] + 928 (EAAccessoryManager.m:1537)
3 CoreAccessories 0x00000001a7892ccc __54-[ACCExternalAccessoryProvider ExternalAccessoryLeft:]_block_invoke + 316 (ACCExternalAccessoryProvider.m:453)
4 libdispatch.dylib 0x0000000185b6d088 _dispatch_call_block_and_release + 24 (init.c:994)
5 libdispatch.dylib 0x0000000185b6d048 _dispatch_client_callout + 16 (object.m:502)
6 libdispatch.dylib 0x0000000185b79b74 _dispatch_main_queue_callback_4CF$VARIANT$mp + 1016 (inline_internal.h:2500)
7 CoreFoundation 0x0000000186191eb0 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 12 (CFRunLoop.c:1815)
8 CoreFoundation 0x000000018618fa8c __CFRunLoopRun + 2012 (CFRunLoop.c:3111)
9 CoreFoundation …Run Code Online (Sandbox Code Playgroud) 我的应用程序在扫描对象后生成 ply 文件。ios 14 更新后,我的 3d 模型的颜色无法正确加载。另外我无法在 xcode 中查看 ply 文件(在预览中工作正常)。
有人知道这个问题的解决方法吗?
我厌倦了阅读层文件内容并在场景几何图形中显示顶点和面,但加载文件需要很长时间。
显然,创建 mdlAsset() 会引发一些 Metal 警告,并且网格颜色无法正确显示。
以下是sceneKit 中ios 13 和14 预览的示例图像。
