Function: writeTrun()
ts
function writeTrun(cursor, box): void;Defined in: writers/writeTrun.ts:23
Write the trun box (TrackRunBox).
ISO/IEC 14496-12:2015 - 8.8.8
Parameters
cursor
The write cursor
box
The TrackRunBox fields to write
A box with samples writes the length of samples as sample_count. A box with no samples writes sampleCount.
Returns
void
Throws
RangeError if a value of the box does not fit its field. The writer also throws if the flags select a sample field and the box has no samples.