---
title: "AudioUnitAddRenderNotify(_:_:_:)"
framework: audiotoolbox
role: symbol
role_heading: Function
path: "audiotoolbox/audiounitaddrendernotify(_:_:_:)"
---

# AudioUnitAddRenderNotify(_:_:_:)

Registers a callback to receive audio unit render notifications.

## Declaration

```swift
func AudioUnitAddRenderNotify(_ inUnit: AudioUnit, _ inProc: AURenderCallback, _ inProcUserData: UnsafeMutableRawPointer?) -> OSStatus
```

## Parameters

- `inUnit`: The audio unit that you want to receive render notifications from.
- `inProc`: The callback that you are registering.
- `inProcUserData`: Custom data that you want to be sent to your callback. Use this, for example, to identify the render listener.

## Return Value

Return Value A result code.

## Discussion

Discussion The registered callback function is called both before the audio unit performs its render operations (when the render flag’s pre-render bit is set) and after the audio unit has completed its render operation (the render flag’s post-render bit is set). The inProc and inProcUserData parameters are treated as a two-part identifier. To remove a render listener, you must pass both these values to the AudioUnitRemoveRenderNotify(_:_:_:) function.

## See Also

### Rendering the Audio

- [AudioUnitRender(_:_:_:_:_:_:)](audiotoolbox/audiounitrender(_:_:_:_:_:_:).md)
- [AudioUnitRemoveRenderNotify(_:_:_:)](audiotoolbox/audiounitremoverendernotify(_:_:_:).md)
- [AURenderCallback](audiotoolbox/aurendercallback.md)
- [AudioUnitRenderActionFlags](audiotoolbox/audiounitrenderactionflags.md)
