---
title: anchorTime()
framework: coremedia
role: symbol
role_heading: Instance Method
path: coremedia/cmclock/anchortime()
---

# anchorTime()

Returns the current time from a clock and the matching time from the clock’s reference clock.

## Declaration

```swift
func anchorTime() throws -> (anchorTime: CMTime, referenceTime: CMTime)
```

## See Also

### Getting Time and Devices

- [audioDevice()](coremedia/cmclock/audiodevice().md)
- [setAudioDeviceID(_:)](coremedia/cmclock/setaudiodeviceid(_:).md)
- [setAudioDeviceUID(_:)](coremedia/cmclock/setaudiodeviceuid(_:).md)
