One Logo Pool Ball
RealityFoundation · IOS API REFERENCE

PhotogrammetrySession.Output

enum · iOS 17.0+ · SDK 27.1

enum Output

Status updates on the object-creation process. RealityKit’s Object Capture is a long-running background task. The session publishes messages status and error messages to ``RealityKit/PhotogrammetrySession/outputs-swift.property``, a Swift <doc://com.apple.documentation/documentation/swift/asyncsequence>. Your app can respond to these updates using a `for`-`await`-`in` loop inside of a `Task`, as this example demonstrates. ```swift let waiter = Task { do { for try await output in session.outputs { switch output { case .processingComplete: // RealityKit has processed all requests. case .requestError(let request, let error): // Request encountered an error. case .requestComplete(let request, let result): // RealityKit has finished processing a request. case .requestProgress(let request, let fractionComplete): // Periodic progress update. Update UI here. case requestProgressInfo(let request, let progressInfo): // Periodic progress info update. case .inputComplete: // Ingestion of images is complete and processing begins. case .invalidSample(let id, let reason): // RealityKit deemed a sample invalid and didn't use it. case .skippedSample(let id): // RealityKit was unable to use a provided sample. case .automaticDownsampling: // RealityKit downsampled the input images because of // resource constraints. case .processingCancelled // Processing was canceled. @unknown default: // Unrecognized output. } } } catch { print("Output: ERROR = \(String(describing: error))") // Handle error. } } ```

Members (1)

get · iOS 17.0+

localizedDescription

TypeScript
get localizedDescription(): string
Swift declaration
var localizedDescription: String { get }

Localized string containing any extra information about the message, such as the reason why a sample is invalid.

Skipped declarations

No declarations were skipped in this snapshot.

All RealityFoundation types →