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

# CVImageBufferGetColorSpace(_:)

Returns the color space of a Core Video image buffer.

```
func CVImageBufferGetColorSpace(_ imageBuffer: CVImageBuffer) -> Unmanaged<CGColorSpace>?
```

## Parameters

`imageBuffer`

The image buffer containing the color space to retrieve.

## Return Value

The color space of the image buffer, or <doc://com.apple.documentation/documentation/ObjectiveC/nil-227m0> if you pass a value for the image buffer that isn’t a [`CVImageBuffer`](/documentation/CoreVideo/CVImageBuffer) type.

---

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)