TimeRange

class TimeRange(val start: Duration, val endExclusive: Duration? = null)(source)

A half-open range of media time, [start, endExclusive).

Half-open so ranges concatenate without sharing a frame: the clip ending at ten seconds and the clip starting at ten seconds overlap on no sample.

Constructors

Link copied to clipboard
constructor(start: Duration, endExclusive: Duration? = null)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

How long the range covers, or null while the end is open and the source has not been probed.

Link copied to clipboard

Where the range ends, or null to run to the end of the source.

Link copied to clipboard

Where the range starts.

Functions

Link copied to clipboard
operator fun contains(time: Duration): Boolean

Tests a media time against the range.