<!--
{
  "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/SCNProgramDelegate",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "SceneKit"
    ],
    "preciseIdentifier" : "c:objc(pl)SCNProgramDelegate"
  },
  "title" : "SCNProgramDelegate"
}
-->

# SCNProgramDelegate

The interface for tracking errors that occur when compiling shader source code.

```
protocol SCNProgramDelegate : NSObjectProtocol
```

## Overview

You create and use custom shader programs with the  [`SCNProgram`](/documentation/SceneKit/SCNProgram) class.

## Topics

### Handling Shader Compilation Errors

[`program(_:handleError:)`](/documentation/SceneKit/SCNProgramDelegate/program(_:handleError:))

Tells the delegate that an error occurred when compiling GLSL source code.

[`SCNErrorDomain`](/documentation/SceneKit/SCNErrorDomain)

Identifies an error type defined by the SceneKit framework.

[SceneKit Error Codes](/documentation/SceneKit/1409723-scenekit-error-codes)

### Finding Fragment Opaqueness

[`programIsOpaque(_:)`](/documentation/SceneKit/SCNProgramDelegate/programIsOpaque(_:))

Asks the delegate whether fragments rendered by a program are opaque.

### Binding and Unbinding Values

[`program(_:bindValueForSymbol:atLocation:programID:renderer:)`](/documentation/SceneKit/SCNProgramDelegate/program(_:bindValueForSymbol:atLocation:programID:renderer:))

Invoked on the delegate to let it bind program values and/or associated graphics resources (such as textures) for symbols.

[`program(_:unbindValueForSymbol:atLocation:programID:renderer:)`](/documentation/SceneKit/SCNProgramDelegate/program(_:unbindValueForSymbol:atLocation:programID:renderer:))

Invoked on the delegate to let it unbind program values and/or also unbind associated graphic resources (such as textures).



---

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)