---
title: "track(_:cameraInformation:image:)"
framework: dockkit
role: symbol
role_heading: Instance Method
path: "dockkit/dockaccessory/track(_:camerainformation:image:)-3uuza"
---

# track(_:cameraInformation:image:)

Automatically generate and send tracking vectors to the device.

## Declaration

```swift
final func track(_ data: [DockAccessory.Observation], cameraInformation: DockAccessory.CameraInformation, image: CVPixelBuffer) async throws
```

## Parameters

- `data`: An array of doc://com.apple.DockKit/documentation/DockKit/DockAccessory/Observation objects indicating the location of objects of interest in the frame.
- `cameraInformation`: The camera currently being used, and the orientation of the device.
- `image`: The captured camera image buffer.

## Discussion

Discussion The device receives tracking vectors based on manually constructed observations. Disable system tracking, then supply the observations at a fixed rate between 10 and 30 times per second. Any other rate is unsupported. Calling this method without first disabling system tracking is a fatal error. note: DockKitError.notSupported if called on macOS.
