<!--
{
  "availability" : [
    "iOS: 8.0.0 - 26.0.0",
    "iPadOS: 8.0.0 - 26.0.0",
    "macCatalyst: 13.1.0 - 26.0.0",
    "macOS: 10.8.0 - 26.0.0",
    "tvOS: 9.0.0 - 26.0.0",
    "visionOS: 1.0.0 - 26.0.0",
    "watchOS: 3.0.0 - 26.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "SceneKit",
  "identifier" : "/documentation/SceneKit/SCNSceneRendererDelegate",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "SceneKit"
    ],
    "preciseIdentifier" : "c:objc(pl)SCNSceneRendererDelegate"
  },
  "title" : "SCNSceneRendererDelegate"
}
-->

# SCNSceneRendererDelegate

Methods your app can implement to participate in SceneKit’s animation loop or perform additional rendering.

```
protocol SCNSceneRendererDelegate : NSObjectProtocol
```

## Overview

To build an app or game with SceneKit, you use an [`SCNView`](/documentation/SceneKit/SCNView) object (or other object conforming the [`SCNSceneRenderer`](/documentation/SceneKit/SCNSceneRenderer) protocol) to display your scene. Then, to add per-frame game logic, or to perform custom Metal or OpenGL rendering before or after SceneKit renders the scene, specify your own custom object that implements the [`SCNSceneRendererDelegate`](/documentation/SceneKit/SCNSceneRendererDelegate) protocol for the view’s [`delegate`](/documentation/SceneKit/SCNSceneRenderer/delegate) property.

When rendering your scene, an [`SCNView`](/documentation/SceneKit/SCNView) object (or other SceneKit renderer) runs a rendering loop that processes and then draws the scene. [`SCNSceneRendererDelegate`](/documentation/SceneKit/SCNSceneRendererDelegate) shows the steps in this loop.

![](images/com.apple.scenekit/media-2929793@2x.png)

Each time through the rendering loop, a SceneKit view (or renderer) executes the following actions in order:

1. The view calls its delegate’s [`renderer(_:updateAtTime:)`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:updateAtTime:)) method.
2. SceneKit executes actions and performs animations attached to the scene graph. (See the [`SCNAction`](/documentation/SceneKit/SCNAction) class and [`SCNAnimatable`](/documentation/SceneKit/SCNAnimatable) protocol.)
3. The view calls its delegate’s [`renderer(_:didApplyAnimationsAtTime:)`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:didApplyAnimationsAtTime:)) method.
4. SceneKit applies its physics simulation to any physics bodies in the scene. (See [`SCNPhysicsWorld`](/documentation/SceneKit/SCNPhysicsWorld), [`SCNPhysicsBody`](/documentation/SceneKit/SCNPhysicsBody), and related classes.)
5. The view calls its delegate’s [`renderer(_:didSimulatePhysicsAtTime:)`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:didSimulatePhysicsAtTime:)) method.
6. The view calls its delegate’s [`renderer(_:willRenderScene:atTime:)`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:willRenderScene:atTime:)) method.
7. SceneKit renders the scene graph in the view.
8. The view calls its delegate’s [`renderer(_:didRenderScene:atTime:)`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:didRenderScene:atTime:)) method.

### Working With the Rendering Loop

When building a game, you typically need to run logic relating to gameplay before each frame of animation. Game logic may include input handling, artificial intelligence, game scripting, or other tasks. Often, the results of this logic involve making changes to nodes or running actions on nodes.

The methods listed in [`SCNSceneRendererDelegate`](/documentation/SceneKit/SCNSceneRendererDelegate) provide places to implement your game logic. Which of these methods you implement for which tasks depends on your game design. For example, if your game uses physics, you might implement the [`renderer(_:didSimulatePhysicsAtTime:)`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:didSimulatePhysicsAtTime:)) method to decide whether the player has won the game based on the state of physics bodies in the scene. If your gameplay isn’t based on the physics simulation, you might make such decisions in the [`renderer(_:updateAtTime:)`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:updateAtTime:)) method instead.

### Custom Rendering

If you want to perform custom rendering before or after SceneKit renders the contents of the scene, implement one or both methods listed in [`SCNSceneRendererDelegate`](/documentation/SceneKit/SCNSceneRendererDelegate). These methods are appropriate for custom Metal or OpenGL drawing that does not depend on the structure or content of the scene graph. If you instead want to render a special effect that is attached to a specific location in the scene, see [`SCNNodeRendererDelegate`](/documentation/SceneKit/SCNNodeRendererDelegate). Or if you want to use GPU shader programs to customize SceneKit’s rendering of scene content, see [`SCNShadable`](/documentation/SceneKit/SCNShadable).

## Topics

### Adding Custom Logic to the Rendering Loop

[`-  renderer:updateAtTime:`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:updateAtTime:))

Tells the delegate to perform any updates that need to occur before actions, animations, and physics are evaluated.

[`-  renderer:didApplyAnimationsAtTime:`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:didApplyAnimationsAtTime:))

Tells the delegate to perform any updates that need to occur after actions and animations are evaluated.

[`-  renderer:didSimulatePhysicsAtTime:`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:didSimulatePhysicsAtTime:))

Tells the delegate to perform any updates that need to occur after physics simulations are performed.

### Rendering Custom Scene Content

[`-  renderer:willRenderScene:atTime:`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:willRenderScene:atTime:))

Tells the delegate that the renderer has cleared the viewport and is about to render the scene.

[`-  renderer:didRenderScene:atTime:`](/documentation/SceneKit/SCNSceneRendererDelegate/renderer(_:didRenderScene:atTime:))

Tells the delegate that the renderer has rendered the scene.

## Relationships

### Inherits From

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)