Post

Replies

Boosts

Views

Activity

Reply to Avoiding SKView Stretching During Layout Animations
Interested in a solution to this issue as well. override func didMove(to view: SKView) { scaleMode = .resizeFill view.contentMode = .center // This is the closest working solution indeed. But not quite there yet. } The documentation of setNeedsDisplay() method says: If your view is backed by a CAEAGLLayer object, this method has no effect. A CAEAGLLayer is "a layer that supports drawing OpenGL content." SpriteKit probably used that, then moved to Metal, and the same limitation still applies. But this is only speculation. Source: setNeedsDisplay() CAEAGLLayer
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Oct ’24
Reply to SF Symbols work with SpriteKit on iOS?
I also use SF Symbols with SpriteKit for quick UI and icon prototyping. I have an SKTexture extension to create SpriteKit textures from SF Symbol on iOS: extension SKTexture { convenience init?(systemName: String, pointSize: CGFloat, weight: UIImage.SymbolWeight = .regular) { let config = UIImage.SymbolConfiguration(pointSize: pointSize, weight: weight) guard let symbol = UIImage(systemName: systemName)?.applyingSymbolConfiguration(config) else { return nil } let rect = CGRect(origin: .zero, size: symbol.size) UIGraphicsBeginImageContextWithOptions(rect.size, false, 0) guard let context = UIGraphicsGetCurrentContext() else { return nil } /// Flip the coordinate system context.translateBy(x: 0, y: rect.size.height) context.scaleBy(x: 1, y: -1) /// Generate a white image UIColor.white.setFill() context.fill(rect) context.setBlendMode(.destinationIn) if let cgImage = symbol.cgImage { context.draw(cgImage, in: rect) } else { return nil } guard let result = UIGraphicsGetImageFromCurrentImageContext() else { return nil } self.init(image: result) } } Usage example: let iconTexture = SKTexture(systemName: "play.fill", pointSize: 17, weight: .bold) let sprite = SKSpriteNode(texture: iconTexture) sprite.colorBlendFactor = 1 sprite.color = .systemBlue addChild(sprite)
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Jul ’25
Reply to SpriteKit framerate drop on iOS 26.0
I installed iOS 26.1 Beta 4, hoping the SpriteKit issues were fixed. But alas, they're still there. You can try this additional test: on any SpriteKit scene with a running animation, place a SwiftUI Menu on top. Each time the menu is opened, SpriteKit drops frames. This makes SwiftUI unusable alongside SpriteKit when the scene is animated or live-recorded. SpriteKit used to run predictably and efficiently. iOS 26 has broken too much in terms of performance and usability. The current state of things isn’t reassuring at all.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Oct ’25
Reply to SpriteKit framerate drop on iOS 26.0
Apple sent this response on 18 November 2025: We believe this issue has been addressed. Please verify this matter is resolved after updating to iOS 26.2 beta 3. iOS 26.2 beta 3 (Build: 23C5044b) Posted Date: November 17, 2025 In my testing, the issue seems resolved indeed! Thank you! It is great and encouraging news for SpriteKit users. The issue FB20808104, where both SpriteKit and RealityKit drop frames under SwiftUI views, still holds. I will continue to look for updates on the Feedback Assistant.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Dec ’25
Reply to ARView ignores multi-touch events
I have submitted feedback FB21685578, titled "ARView does not support multi-touch". Currently, in order to access UIResponder's touch callbacks and respond to simultaneous touches on ARView, I have to either: Overlay an UIView on top of ARView and forward the touch events from the overlay to the ARView Attach a gesture recognizer to ARView, use the touch callbacks inside it to track touches, and handle the recognizer’s states Both workarounds add unnecessary debt and complexity.
Topic: Graphics & Games SubTopic: RealityKit Tags:
Jan ’26
Reply to RealityKit .Kinematic + collisions (visionOs)
In order to control physical entities within a physics simulation, you can explore the topic of proportional-derivative (PD) controllers. The principle: User input provides a target position Each frame (use the willSimulate event), a control system applies forces or impulses to drive the body toward that target This answer provides a sample implementation with SpriteKit. The same principles apply to RealityKit.
Topic: Graphics & Games SubTopic: RealityKit Tags:
Feb ’26
Reply to RealityKit crashes when rendering SpriteKit scene with SKShapeNode in postProcess callback
This reminds of an error I got while setting up SKRenderer for this project: SKRenderer Demo. See code and comment in SKOfflineRenderer.swift: // If I dont use a depth/stencil texture, rendering crashes on simulator, device, and Mac // Without it, rendering only works on Xcode Live Preview let depthStencilDesc = MTLTextureDescriptor() depthStencilDesc.pixelFormat = .depth32Float_stencil8 depthStencilDesc.width = pixelWidth depthStencilDesc.height = pixelHeight depthStencilDesc.usage = .renderTarget depthStencilDesc.storageMode = .private The code is inside the init, check how the depthStencilTexture is setup for SKRenderer, it may help you.
Topic: Graphics & Games SubTopic: RealityKit Tags:
Mar ’26
Reply to Avoiding SKView Stretching During Layout Animations
Interested in a solution to this issue as well. override func didMove(to view: SKView) { scaleMode = .resizeFill view.contentMode = .center // This is the closest working solution indeed. But not quite there yet. } The documentation of setNeedsDisplay() method says: If your view is backed by a CAEAGLLayer object, this method has no effect. A CAEAGLLayer is "a layer that supports drawing OpenGL content." SpriteKit probably used that, then moved to Metal, and the same limitation still applies. But this is only speculation. Source: setNeedsDisplay() CAEAGLLayer
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Replies
Boosts
Views
Activity
Oct ’24
Reply to Xcode 16.3 Doesn't Remember Preview Pane Width
I have a similar issue with Xcode 16.3. Readjusting the preview pane every time is not okay. I switched back to Xcode 16.2, which we can download separately from Apple or Xcodes app.
Replies
Boosts
Views
Activity
Apr ’25
Reply to SF Symbols work with SpriteKit on iOS?
I also use SF Symbols with SpriteKit for quick UI and icon prototyping. I have an SKTexture extension to create SpriteKit textures from SF Symbol on iOS: extension SKTexture { convenience init?(systemName: String, pointSize: CGFloat, weight: UIImage.SymbolWeight = .regular) { let config = UIImage.SymbolConfiguration(pointSize: pointSize, weight: weight) guard let symbol = UIImage(systemName: systemName)?.applyingSymbolConfiguration(config) else { return nil } let rect = CGRect(origin: .zero, size: symbol.size) UIGraphicsBeginImageContextWithOptions(rect.size, false, 0) guard let context = UIGraphicsGetCurrentContext() else { return nil } /// Flip the coordinate system context.translateBy(x: 0, y: rect.size.height) context.scaleBy(x: 1, y: -1) /// Generate a white image UIColor.white.setFill() context.fill(rect) context.setBlendMode(.destinationIn) if let cgImage = symbol.cgImage { context.draw(cgImage, in: rect) } else { return nil } guard let result = UIGraphicsGetImageFromCurrentImageContext() else { return nil } self.init(image: result) } } Usage example: let iconTexture = SKTexture(systemName: "play.fill", pointSize: 17, weight: .bold) let sprite = SKSpriteNode(texture: iconTexture) sprite.colorBlendFactor = 1 sprite.color = .systemBlue addChild(sprite)
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Replies
Boosts
Views
Activity
Jul ’25
Reply to SpriteKit framerate drop on iOS 26.0
Done, I have filed report FB20287404 as "SpriteKit performance regression on iOS 26". Long live SpriteKit.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Replies
Boosts
Views
Activity
Sep ’25
Reply to iPhone limited to 60hz frame rate
Hi, Try adding CADisableMinimumFrameDurationOnPhone to the project's property list, set its value to true, then use preferredFramesPerSecond.
Replies
Boosts
Views
Activity
Sep ’25
Reply to SpriteKit framerate drop on iOS 26.0
I installed iOS 26.1 Beta 4, hoping the SpriteKit issues were fixed. But alas, they're still there. You can try this additional test: on any SpriteKit scene with a running animation, place a SwiftUI Menu on top. Each time the menu is opened, SpriteKit drops frames. This makes SwiftUI unusable alongside SpriteKit when the scene is animated or live-recorded. SpriteKit used to run predictably and efficiently. iOS 26 has broken too much in terms of performance and usability. The current state of things isn’t reassuring at all.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Replies
Boosts
Views
Activity
Oct ’25
Reply to SpriteKit/RealityKit + SwiftUI Performance Regression on iOS 26
I filed report FB20808104 with the above information and code. Expected behavior: a native UI menu shouldn't impact the performance of underlying views, or use significant system resources.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Oct ’25
Reply to SpriteKit framerate drop on iOS 26.0
I'd like to bring attention to an issue that may or may not be related to the SpriteKit iOS 26 regression: SwiftUI makes both SKView and ARView (RealityKit scene) drop many frames. Full code and bug report here: https://developer.apple.com/forums/thread/804973
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Replies
Boosts
Views
Activity
Oct ’25
Reply to ARView ignores multi-touch events
Is this expected behavior or a bug? Is there a crucial piece missing from my setup to get multitouch working on ARView without the overlay view hack? Your input is much appreciated.
Topic: Graphics & Games SubTopic: RealityKit Tags:
Replies
Boosts
Views
Activity
Nov ’25
Reply to SpriteKit framerate drop on iOS 26.0
Apple sent this response on 18 November 2025: We believe this issue has been addressed. Please verify this matter is resolved after updating to iOS 26.2 beta 3. iOS 26.2 beta 3 (Build: 23C5044b) Posted Date: November 17, 2025 In my testing, the issue seems resolved indeed! Thank you! It is great and encouraging news for SpriteKit users. The issue FB20808104, where both SpriteKit and RealityKit drop frames under SwiftUI views, still holds. I will continue to look for updates on the Feedback Assistant.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Replies
Boosts
Views
Activity
Dec ’25
Reply to ARView ignores multi-touch events
I have submitted feedback FB21685578, titled "ARView does not support multi-touch". Currently, in order to access UIResponder's touch callbacks and respond to simultaneous touches on ARView, I have to either: Overlay an UIView on top of ARView and forward the touch events from the overlay to the ARView Attach a gesture recognizer to ARView, use the touch callbacks inside it to track touches, and handle the recognizer’s states Both workarounds add unnecessary debt and complexity.
Topic: Graphics & Games SubTopic: RealityKit Tags:
Replies
Boosts
Views
Activity
Jan ’26
Reply to RealityKit .Kinematic + collisions (visionOs)
In order to control physical entities within a physics simulation, you can explore the topic of proportional-derivative (PD) controllers. The principle: User input provides a target position Each frame (use the willSimulate event), a control system applies forces or impulses to drive the body toward that target This answer provides a sample implementation with SpriteKit. The same principles apply to RealityKit.
Topic: Graphics & Games SubTopic: RealityKit Tags:
Replies
Boosts
Views
Activity
Feb ’26
Reply to Xcode 26.3 - Revert to variable editor tab width
I have filed report FB22117916, titled "Reduced tab density in Xcode 26.3".
Replies
Boosts
Views
Activity
Mar ’26
Reply to RealityKit crashes when rendering SpriteKit scene with SKShapeNode in postProcess callback
This reminds of an error I got while setting up SKRenderer for this project: SKRenderer Demo. See code and comment in SKOfflineRenderer.swift: // If I dont use a depth/stencil texture, rendering crashes on simulator, device, and Mac // Without it, rendering only works on Xcode Live Preview let depthStencilDesc = MTLTextureDescriptor() depthStencilDesc.pixelFormat = .depth32Float_stencil8 depthStencilDesc.width = pixelWidth depthStencilDesc.height = pixelHeight depthStencilDesc.usage = .renderTarget depthStencilDesc.storageMode = .private The code is inside the init, check how the depthStencilTexture is setup for SKRenderer, it may help you.
Topic: Graphics & Games SubTopic: RealityKit Tags:
Replies
Boosts
Views
Activity
Mar ’26
Reply to Does VisionOS have the equivalent of ARView.physicsOrigin?
I have the same question, but for RealityRenderer: how to set a different physics origin entity than an ancestor, using RealityRenderer?
Topic: Graphics & Games SubTopic: RealityKit Tags:
Replies
Boosts
Views
Activity
Mar ’26