---
title: "init(id:time:duration:offset:)"
framework: Immersive Media Support
role: symbol
role_heading: Initializer
platforms: [iOS 26.4+, iPadOS 26.4+, Mac Catalyst 26.4+, macOS 26.0+, visionOS 26.0+]
path: "immersivemediasupport/shotflopcommand/init(id:time:duration:offset:)"
---

# init(id:time:duration:offset:)

Creates a command instance for a certain time, duration and offset.

## Declaration

```swift
init(id: Int, time: CMTime, duration: CMTime, offset: CMTime? = nil)
```

## Parameters

- `id`: The unique ID of this command.
- `time`: The time for this command to start during playback.
- `duration`: The duration of this command during playback.
- `offset`: The offset from the start time of this command.
