<!--
{
  "availability" : [
    "DriverKit: 21.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AudioDriverKit",
  "identifier" : "/documentation/AudioDriverKit/IOUserAudioDriver/AddObject",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AudioDriverKit"
    ],
    "preciseIdentifier" : "c:@S@IOUserAudioDriver@F@AddObject#*$@S@IOUserAudioObject#"
  },
  "title" : "AddObject"
}
-->

# AddObject

Adds an audio object to the driver.

```
kern_return_t AddObject(IOUserAudioObject *in_object);
```

## Parameters

`in_object`

The [`IOUserAudioObjectID`](/documentation/AudioDriverKit/AudioDriverKit/IOUserAudioObjectID) to add to the driver.

## Return Value

<doc://com.apple.documentation/documentation/DriverKit/kIOReturnSuccess> on success, or another value if an error occurs. For a list of error codes, see <doc://com.apple.documentation/documentation/DriverKit/error-codes>.

## Discussion

Use this method to add to the driver any objects that require management by the host. If the add succeeds, the object’s reference count increments by one. The caller should also call [`PropertiesChanged`](/documentation/AudioDriverKit/IOUserAudioDriver/PropertiesChanged) to notify the host of any changes.

---

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)