<!--
{
  "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" : "ImageIO",
  "identifier" : "/documentation/ImageIO/CGImageSourceGetType(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Image I/O"
    ],
    "preciseIdentifier" : "c:@F@CGImageSourceGetType"
  },
  "title" : "CGImageSourceGetType(_:)"
}
-->

# CGImageSourceGetType(_:)

Returns the uniform type identifier of the source container.

```
func CGImageSourceGetType(_ isrc: CGImageSource) -> CFString?
```

## Parameters

`isrc`

The image source that contains the image data.

## Return Value

The uniform type identifier of the image source container.

## Discussion

The uniform type identifier of the source container can be different from the type of the images in the container. For example, the `.icns` format supports embedded `JPEG2000`. The type of the source container is `"com.apple.icns"`, but type of the images is `JPEG2000`.

For a list of system-declared and third-party identifiers, see <doc://com.apple.documentation/documentation/UniformTypeIdentifiers>.

---

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)