<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.10.0 -",
    "tvOS: 10.2.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "VideoToolbox",
  "identifier" : "/documentation/VideoToolbox/VTMultiPassStorageCreate(allocator:fileURL:timeRange:options:multiPassStorageOut:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Video Toolbox"
    ],
    "preciseIdentifier" : "c:@F@VTMultiPassStorageCreate"
  },
  "title" : "VTMultiPassStorageCreate(allocator:fileURL:timeRange:options:multiPassStorageOut:)"
}
-->

# VTMultiPassStorageCreate(allocator:fileURL:timeRange:options:multiPassStorageOut:)

Creates a multipass storage object using a temporary file.

```
func VTMultiPassStorageCreate(allocator: CFAllocator?, fileURL: CFURL?, timeRange: CMTimeRange, options: CFDictionary?, multiPassStorageOut: UnsafeMutablePointer<VTMultiPassStorage?>) -> OSStatus
```

## Parameters

`allocator`

An allocator for the session.  Pass `NULL` to use the default allocator.

`fileURL`

Specifies where to put the backing file for the multipass storage object. If you pass `NULL` for `fileURL`, the video toolbox will pick a unique temporary file name.

`timeRange`

Gives a hint to the multipass storage about valid time stamps for data. You can pass `kCMTimeRangeInvalid` if you do not want to provide a time range hint.

`options`

If the file did not exist when the storage was created, the file will be deleted when the multipass storage object is finalized, unless you set the [`kVTMultiPassStorageCreationOption_DoNotDelete`](/documentation/VideoToolbox/kVTMultiPassStorageCreationOption_DoNotDelete) option to <doc://com.apple.documentation/documentation/CoreFoundation/kCFBooleanTrue> in the `options` dictionary.

`multiPassStorageOut`

A pointer to the newly created multipass storage object.

## Discussion

You can use the multipass storage object to perform multipass encoding; see [`kVTCompressionPropertyKey_MultiPassStorage`](/documentation/VideoToolbox/kVTCompressionPropertyKey_MultiPassStorage).

Call <doc://com.apple.documentation/documentation/CoreFoundation/CFRelease> to release the multipass storage object when you are done with it.

---

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)