Instance Method


Set's the timebase's rate and time.


func setRate(_ rate: Float, time: CMTime)



The new timebase rate. This value must be greater than or equal to 0.0.


The new timebase time. This value must be greater than or equal to zero or invalid.


This method first sets the new time and then the new rendering rate. A rate value of 0.0 means that playback has stopped while a rate value of 1.0 indicates playback should be at the natural rate of the media.

See Also

Accessing Time Information

var timebase: CMTimebase

The synchronizer's rendering timebase, which governs how timestamps are interpreted.

var rate: Float

The current playback rate.

class let rateDidChangeNotification: NSNotification.Name

The synchronizer's rendering rate changed.

func currentTime() -> CMTime

Returns the current time of the synchronizer.