<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "Accelerate",
  "identifier" : "/documentation/Accelerate/vImage_CGImageFormat",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Accelerate"
    ],
    "preciseIdentifier" : "c:@S@vImage_CGImageFormat"
  },
  "title" : "vImage_CGImageFormat"
}
-->

# vImage_CGImageFormat

The description of a Core Graphics image.

```
struct vImage_CGImageFormat
```

## Overview

This structure describes the ordering and number of the color channels, the size and type of the data in the color channels, and alpha information. This format mirrors the image format descriptors that Core Graphics uses to create objects, such as <doc://com.apple.documentation/documentation/CoreGraphics/CGImage> and <doc://com.apple.documentation/documentation/CoreGraphics/CGContext>.

## Topics

### Initializers

[`init(bitsPerComponent:bitsPerPixel:colorSpace:bitmapInfo:version:decode:renderingIntent:)`](/documentation/Accelerate/vImage_CGImageFormat/init(bitsPerComponent:bitsPerPixel:colorSpace:bitmapInfo:version:decode:renderingIntent:))

Creates a Core Graphics image format.

[`init(bitsPerComponent:bitsPerPixel:colorSpace:bitmapInfo:renderingIntent:)`](/documentation/Accelerate/vImage_CGImageFormat/init(bitsPerComponent:bitsPerPixel:colorSpace:bitmapInfo:renderingIntent:))

Creates a Core Graphics image format with a color space instance and default decode array.

[`init(cgImage:)`](/documentation/Accelerate/vImage_CGImageFormat/init(cgImage:))

Creates a Core Graphics image format of the specified image.

[`init()`](/documentation/Accelerate/vImage_CGImageFormat/init())

Creates an empty Core Graphics image format.

### Instance properties

[`bitsPerComponent`](/documentation/Accelerate/vImage_CGImageFormat/bitsPerComponent)

The number of bits that represents one channel of data in one pixel.

[`bitsPerPixel`](/documentation/Accelerate/vImage_CGImageFormat/bitsPerPixel)

The number of bits that represents one pixel.

[`colorSpace`](/documentation/Accelerate/vImage_CGImageFormat/colorSpace)

A description of the position of the pixel data in the image, relative to a reference XYZ color space.

[`bitmapInfo`](/documentation/Accelerate/vImage_CGImageFormat/bitmapInfo)

The component information that describes the color channels.

[`version`](/documentation/Accelerate/vImage_CGImageFormat/version)

The version number.

[`decode`](/documentation/Accelerate/vImage_CGImageFormat/decode)

The decode array for the image.

[`renderingIntent`](/documentation/Accelerate/vImage_CGImageFormat/renderingIntent)

A rendering intent constant that specifies how Core Graphics handles colors that aren’t within the destination color space gamut.

[`componentCount`](/documentation/Accelerate/vImage_CGImageFormat/componentCount)

The number of color and alpha channels.



---

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)