<!--
{
  "documentType" : "article",
  "framework" : "CoreGraphics",
  "identifier" : "/documentation/CoreGraphics/cgpdfstream",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "CGPDFStream"
}
-->

# CGPDFStream

A stream or sequence of data bytes in a PDF document.

## Discussion

A PDF stream  consists  of a dictionary that describes a sequence of bytes. Streams typically represent objects with potentially large amounts of data, such as images and page descriptions.

This object is not derived from CFType and therefore there are no functions for retaining and releasing it.

## Topics

### Getting Data from a PDF Stream

[`CGPDFStreamCopyData(_:_:)`](/documentation/CoreGraphics/CGPDFStreamCopyData(_:_:))

Returns the data associated with a PDF stream.

[`CGPDFStreamGetDictionary(_:)`](/documentation/CoreGraphics/CGPDFStreamGetDictionary(_:))

Returns the dictionary associated with a PDF stream.

### Data Types

[`CGPDFStreamRef`](/documentation/CoreGraphics/CGPDFStreamRef)

A type that represents a PDF stream.

### Constants

[`CGPDFDataFormat`](/documentation/CoreGraphics/CGPDFDataFormat)

The encoding format of PDF data.

## See Also

  [Quartz 2D Programming Guide](https://developer.apple.com/library/archive/documentation/GraphicsImaging/Conceptual/drawingwithquartz2d/Introduction/Introduction.html#//apple_ref/doc/uid/TP30001066)



---

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)