<!--
{
  "availability" : [
    "iOS: 17.0.0 -",
    "iPadOS: 17.0.0 -",
    "macCatalyst: -",
    "macOS: 14.0.0 -",
    "tvOS: 17.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Cinematic",
  "identifier" : "/documentation/Cinematic/CNDetectionTrack-2bxtd/detections(in:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Cinematic"
    ],
    "preciseIdentifier" : "s:9Cinematic16CNDetectionTrackC10detections2inSayAA0B0VGSo11CMTimeRangea_tF"
  },
  "title" : "detections(in:)"
}
-->

# detections(in:)

Returns the array of detections in the detection track within the given time range.

```
func detections(in timeRange: CMTimeRange) -> [CNDetection]
```

## Parameters

`timeRange`

The time range of interest.

## Return Value

The array of detections in the detection track within the given time range. The return value is only appropriate for discrete detection tracks.

---

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)