Whenever I load my SpriteKit app, it logs this error: <CAMetalLayer: 0x15f57fa70>: calling -display has no effect.
, and it doesn't properly display many objects. I have tried recreating the scene and removing my code, both of which have done nothing. For a while I thought this might have been a bug with the new Xcode 7 and iOS 9 beta, but now that I have tried it with the GM version of both and the problem persists, that probably isn't the case.
相关问题
- CALayer - backgroundColor flipped?
- Core Data lightweight migration crashes after App
- Core Data lightweight migration crashes after App
- How can I implement password recovery in an iPhone
- State preservation and restoration strategies with
相关文章
- 现在使用swift开发ios应用好还是swift?
- UITableView dragging distance with UIRefreshContro
- Could I create “Call” button in HTML 5 IPhone appl
- Using if let syntax in switch statement
- TCC __TCCAccessRequest_block_invoke
- Where does a host app handle NSExtensionContext#co
- Unable to process app at this time due to a genera
- Enum with associated value conforming to CaseItera
Check the
zPosition
of all yourSKNodes
. As it turns out, something changed in SpriteKit's implementation, andSKNode
objects are no longer always rendered in the order they were added to their parent nodes. After I made sure all mySKNodes
had the correctzPosition
, everything went back to normal.If that doesn't help, check this post from the dev forums.
As someone suggested in this Apple Developer thread, adding the following key/value pair to your app's Info.plist seems to solve this issue for now.
Make sure you choose Editor > Show Raw Keys & Values before entering the key name above.
As "MacMacMac" says in the forum post, this isn't an ideal fix, since using Metal is presumably better than using OpenGL, but at least OpenGL works.