Contents

AUGraphUpdate(_:_:)

Updates the state of a running audio processing graph.

Declaration

func AUGraphUpdate(_ inGraph: AUGraph, _ outIsUpdated: UnsafeMutablePointer<DarwinBoolean>?) -> OSStatus

Parameters

  • inGraph:

  • outIsUpdated:

    In input, pass NULL for synchronous (blocking) behavior, or non-NULL to have this function return immediately. On output, true if all of the edits were applied to the audio processing graph at the time of function return.

Return Value

A result code.

Discussion

Call this function to finalize changes to an audio processing graph’s state after making calls such as AUGraphConnectNodeInput(_:_:_:_:_:).

Node connections and disconnections can be completely processed in the render notification callback of a graph, finalized by calling this function from within the callback. You can also remove nodes (apart from the head node) from within the render notification callback.

If this function returns the kAUGraphErr_CannotDoInCurrentContext result code, another thread was calling a function dependent on the graph’s existing state. When the competing thread completes its call, call this function again.

Audio processing graph updates are all or none. If this function encounters any errors while attempting to finalize graph events, then no pending changes are finalized.

See Also

Audio Unit Processing Graph Services Functions