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

# IOSurfaceLookupFromXPCObject(_:)

```
func IOSurfaceLookupFromXPCObject(_ xobj: xpc_object_t) -> IOSurfaceRef?
```

## Discussion

This call takes an XPC object created via IOSurfaceCreateXPCObject() and recreates an IOSurfaceRef from it. Note: This call does NOT destroy the port.

---

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)