Skip to content

Function: readHdlr() ​

ts
function readHdlr(cursor): HandlerBox;

Defined in: readers/readHdlr.ts:22

Read the hdlr box (HandlerBox).

Parameters ​

cursor ​

IsoBoxReadCursor<IsoInt64>

The read cursor at the first byte after the box header

Returns ​

HandlerBox

A parsed HandlerBox

Example ​

ts
// An hdlr box with the handler type 'vide' and the UTF-8 bytes of the name 'é日😀'.
const bytes = new Uint8Array([
	0, 0, 0, 42, 104, 100, 108, 114, 0, 0, 0, 0, 0, 0, 0, 0, 118, 105, 100, 101, 0, 0, 0, 0, 0, 0,
	0, 0, 0, 0, 0, 0, 0xc3, 0xa9, 0xe6, 0x97, 0xa5, 0xf0, 0x9f, 0x98, 0x80, 0,
])
const [hdlr] = readIsoBoxes(bytes, { readers: { hdlr: readHdlr } })

A Streaming Video Technology Alliance project.