<!--
{
  "availability" : [
    "iOS: 4.0.0 - 15.0.0",
    "iPadOS: 4.0.0 - 15.0.0",
    "macCatalyst: 13.1.0 - 15.0.0",
    "macOS: 10.4.0 - 12.0.0",
    "tvOS: 9.0.0 - 15.0.0",
    "visionOS: 1.0.0 - 1.0.0",
    "watchOS: 4.0.0 - 8.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "CoreVideo",
  "identifier" : "/documentation/CoreVideo/CVBufferGetAttachments(_:_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Core Video"
    ],
    "preciseIdentifier" : "c:@F@CVBufferGetAttachments"
  },
  "title" : "CVBufferGetAttachments(_:_:)"
}
-->

# CVBufferGetAttachments(_:_:)

Retrieves all attachments of a Core Video buffer.

```
func CVBufferGetAttachments(_ buffer: CVBuffer, _ attachmentMode: CVAttachmentMode) -> CFDictionary?
```

## Parameters

`buffer`

The buffer whose attachments you want to retrieve.

`attachmentMode`

The mode of the attachments you want to retrieve. See [`CVAttachmentMode`](/documentation/CoreVideo/CVAttachmentMode) for possible values.

## Return Value

A Core Foundation dictionary with all attachments identified by keys, or <doc://com.apple.documentation/documentation/ObjectiveC/nil-227m0> if the attachment mode is invalid. The dictionary is empty if the buffer has no attachments.

---

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)