hostTime(forBeats:error:)
Gets the host time the sequence plays at the specified position.
Declaration
func hostTime(forBeats inBeats: AVMusicTimeStamp, error outError: NSErrorPointer) -> UInt64Parameters
- inBeats:
The timestamp for the beat position.
- outError:
On exit, if an error occurs, a description of the error.
Discussion
This call is valid when the player is in a playing state. It returns 0 with an error, otherwise, or if the starting position of the player is after the specified beat. The method uses the sequence’s tempo map to translate a beat time from the starting time and the beat of the player.