<!--
{
  "availability" : [
    "iOS: 11.0.0 -",
    "iPadOS: 11.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.7.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "IOSurface",
  "identifier" : "/documentation/IOSurface/IOSurfaceCreateXPCObject(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "IOSurface"
    ],
    "preciseIdentifier" : "c:@F@IOSurfaceCreateXPCObject"
  },
  "title" : "IOSurfaceCreateXPCObject(_:)"
}
-->

# IOSurfaceCreateXPCObject(_:)

Returns an xpc_object_t that holds a reference to the IOSurface.

```
func IOSurfaceCreateXPCObject(_ aSurface: IOSurfaceRef) -> xpc_object_t
```

---

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)