TechnologiesGraphics, Imaging & Compositing

IOSurface

iOSmacOStvOSwatchOSvisionOS

IOSurface provides shareable, hardware-accelerated image buffers that pass pixel data efficiently between processes and the GPU. You work with an IOSurface (or IOSurfaceRef) to allocate a surface and describe its pixel layout through types such as IOSurfaceComponentName, IOSurfaceComponentType, IOSurfaceComponentRange, and IOSurfaceSubsampling. To read or write the surface's contents, you lock it using IOSurfaceLockOptions and configure its properties with keys defined by IOSurfacePropertyKey. The framework also exposes memory management facilities, including IOSurfacePurgeabilityState and memory-ledger tagging through IOSurfaceMemoryLedgerTags and IOSurfaceMemoryLedgerFlags.

Surfaces 2

The core buffer objects that hold shareable, hardware-accelerated pixel data.

  • Cl
    IOSurfaceiOS 11.0+
    A shareable, hardware-accelerated image buffer that passes pixel data efficiently between processes and the GPU.
  • Cl
    IOSurfaceRef
    A reference to a Core Foundation surface object that holds shareable, hardware-accelerated pixel data.

Pixel Component Layout 4

Types that describe how color and alpha components are arranged within a surface.

  • En
    IOSurfaceComponentName
    Constants that identify the named color or alpha components stored in a surface.
  • En
    IOSurfaceComponentType
    Constants that specify the data type used to represent a surface's pixel components.
  • En
    IOSurfaceComponentRange
    Constants that specify the value range, such as full or video, of a surface's components.
  • En
    IOSurfaceSubsampling
    Constants that describe the chroma subsampling scheme applied to a surface's pixel data.

Accessing Surface Contents 2

Options and property keys for locking a surface and configuring its attributes.

  • St
    IOSurfaceLockOptions
    Options that control how a surface is locked when reading or writing its contents.
  • St
    IOSurfacePropertyKey
    Keys that identify the properties used to allocate and configure a surface.

Memory Management 3

Facilities for controlling a surface's purgeability and tagging its memory in the system ledger.

  • St
    IOSurfacePurgeabilityState
    Constants that specify whether a surface's memory may be reclaimed by the system.
  • En
    IOSurfaceMemoryLedgerTags
    Constants that tag a surface's memory for accounting in the system memory ledger.
  • St
    IOSurfaceMemoryLedgerFlags
    Flags that configure how a surface's memory is reported in the system memory ledger.

Type Aliases 1

  • Ty
    IOSurfaceID
← Graphics, Imaging & Compositing