<!--
{
  "availability" : [
    "iOS: 14.0.0 -",
    "iPadOS: 14.0.0 -",
    "macCatalyst: 14.0.0 -",
    "macOS: 11.0.0 -",
    "tvOS: 14.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Vision",
  "identifier" : "/documentation/Vision/VNStatefulRequest/init(frameAnalysisSpacing:completionHandler:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "Vision"
    ],
    "preciseIdentifier" : "c:objc(cs)VNStatefulRequest(im)initWithFrameAnalysisSpacing:completionHandler:"
  },
  "title" : "init(frameAnalysisSpacing:completionHandler:)"
}
-->

# init(frameAnalysisSpacing:completionHandler:)

Initializes a video-based request.

```
init(frameAnalysisSpacing: CMTime, completionHandler: VNRequestCompletionHandler? = nil)
```

## Parameters

`frameAnalysisSpacing`

A <doc://com.apple.documentation/documentation/CoreMedia/CMTime> value that indicates the duration between analysis operations. Increase this value to reduce the number of frames analyzed on slower devices. Set this argument to <doc://com.apple.documentation/documentation/CoreMedia/CMTime/zero> to analyze all frames.

`completionHandler`

A closure that’s invoked after the request has completed its processing. The system invokes the completion handler on the same dispatch queue as the request performs its processing.

## Discussion

---

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)