<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.10.0 -",
    "tvOS: 8.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Accelerate",
  "identifier" : "/documentation/Accelerate/vImageCVImageFormat_GetChannelDescription(_:_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Accelerate"
    ],
    "preciseIdentifier" : "c:@F@vImageCVImageFormat_GetChannelDescription"
  },
  "title" : "vImageCVImageFormat_GetChannelDescription(_:_:)"
}
-->

# vImageCVImageFormat_GetChannelDescription(_:_:)

Returns the channel description for a particular channel type.

```
func vImageCVImageFormat_GetChannelDescription(_ format: vImageConstCVImageFormat, _ type: vImageBufferTypeCode) -> UnsafePointer<vImageChannelDescription>!
```

## Parameters

`format`

The Core Video image format to query.

`type`

The type of the channel that you want information about. For example, [`kvImageBufferTypeCode_Luminance`](/documentation/Accelerate/kvImageBufferTypeCode_Luminance).

## Return Value

A pointer to a [`vImageChannelDescription`](/documentation/Accelerate/vImageChannelDescription) structure that contains the channel description.

## Discussion

The functions that create Core Video image formats, such as [`vImageCVImageFormat_CreateWithCVPixelBuffer(_:)`](/documentation/Accelerate/vImageCVImageFormat_CreateWithCVPixelBuffer(_:)), return a [`vImageCVImageFormat`](/documentation/Accelerate/vImageCVImageFormat). The following code shows how you create a [`vImageConstCVImageFormat`](/documentation/Accelerate/vImageConstCVImageFormat) representation of a [`vImageCVImageFormat`](/documentation/Accelerate/vImageCVImageFormat) instance to pass to [`vImageCVImageFormat_GetChannelDescription(_:_:)`](/documentation/Accelerate/vImageCVImageFormat_GetChannelDescription(_:_:)):

```swift
let channelDescription = withUnsafeBytes(of: cvImageFormat) { bytes in
    let format = bytes.assumingMemoryBound(
        to: vImageConstCVImageFormat.self).first!
    
    return vImageCVImageFormat_GetChannelDescription(format,
                                                     vImageBufferTypeCode(kvImageBufferTypeCode_Luminance))
}
```

## See Also

[`channelDescription(bufferType:)`](/documentation/Accelerate/vImageCVImageFormat/channelDescription(bufferType:))

Returns the range and clamp limits for a specified channel in a Core Video image format.



---

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)