<!--
{
  "availability" : [
    "iOS: 17.0.0 -",
    "iPadOS: 17.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "RealityKit",
  "identifier" : "/documentation/RealityKit/ObjectCaptureSession/Error",
  "metadataVersion" : "0.1.0",
  "role" : "Enumeration",
  "symbol" : {
    "kind" : "Enumeration",
    "modules" : [
      "RealityKit",
      "SwiftUI"
    ],
    "preciseIdentifier" : "s:19_RealityKit_SwiftUI20ObjectCaptureSessionC5ErrorO"
  },
  "title" : "ObjectCaptureSession.Error"
}
-->

# ObjectCaptureSession.Error

Errors associated with the top-level computation of this class.

```
enum Error
```

## Topics

### Enumeration Cases

[`case cancelled`](/documentation/RealityKit/ObjectCaptureSession/Error/cancelled)

The user requested that the session be canceled and the session is now canceled.  Another session may
now be created.

[`case directoryNotEmpty(URL)`](/documentation/RealityKit/ObjectCaptureSession/Error/directoryNotEmpty(_:))

We cannot continue a pre-existing capture, so if an output directory is provided that already exists and
it is not empty, this error is thrown.

[`case insufficientStorage(requiredBytes: Int64)`](/documentation/RealityKit/ObjectCaptureSession/Error/insufficientStorage(requiredBytes:))

The session can’t be started since there is not enough storage space in the provided directories.

[`case sensorFailed`](/documentation/RealityKit/ObjectCaptureSession/Error/sensorFailed)

There was an ARKit failure in one of the sensors.

[`case trackingFailed`](/documentation/RealityKit/ObjectCaptureSession/Error/trackingFailed)

There was an unrecoverable error related to tracking the object or environment.

### Instance Properties

[`var localizedDescription: String`](/documentation/RealityKit/ObjectCaptureSession/Error/localizedDescription)

Retrieve the localized description for this error.

## Relationships

### Conforms To

[`Sendable`](/documentation/Swift/Sendable)

[`Error`](/documentation/Swift/Error)

[`LocalizedError`](/documentation/Foundation/LocalizedError)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

---

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)