<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "Accelerate",
  "identifier" : "/documentation/Accelerate/vImage_CGImageFormat/init(bitsPerComponent:bitsPerPixel:colorSpace:bitmapInfo:version:decode:renderingIntent:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "Accelerate"
    ],
    "preciseIdentifier" : "s:So20vImage_CGImageFormatV16bitsPerComponent0dE5Pixel10colorSpace10bitmapInfo7version6decode15renderingIntentABs6UInt32V_AKs9UnmanagedVySo07CGColorI3RefaGSgSo08CGBitmapK0VAKSPy14CoreFoundation7CGFloatVGSgSo0r9RenderingO0Vtcfc"
  },
  "title" : "init(bitsPerComponent:bitsPerPixel:colorSpace:bitmapInfo:version:decode:renderingIntent:)"
}
-->

# init(bitsPerComponent:bitsPerPixel:colorSpace:bitmapInfo:version:decode:renderingIntent:)

Creates a Core Graphics image format.

```
init(bitsPerComponent: UInt32, bitsPerPixel: UInt32, colorSpace: Unmanaged<CGColorSpace>!, bitmapInfo: CGBitmapInfo, version: UInt32, decode: UnsafePointer<CGFloat>!, renderingIntent: CGColorRenderingIntent)
```

## Parameters

`bitsPerComponent`

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

`bitsPerPixel`

The number of bits that represents one pixel.

`colorSpace`

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

`bitmapInfo`

The component information that describes the color channels.

`version`

Reserved for future expansion — pass `0` here.

`decode`

The decode array for the image. See [`decode`](/documentation/Accelerate/vImage_CGImageFormat/decode) for more information.

`renderingIntent`

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

## Discussion

---

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)