Contents

duration

The unmodified sum of the durations of all samples in the sample buffer.

Declaration

var duration: CMTime { get }

Discussion

If the buffer contains out-of-presentation-order samples, any gaps in the presentation timeline are not represented in the returned duration. The calculated duration is simply the sum of all the individual sample durations.

Returns invalid if sampleTimings is empty or contains invalid duration.