MCPcopy
hub / github.com/fanmingming/live / parseType

Function parseType

m3u8/mux-mp4.js:237–247  ·  view source on GitHub ↗
(header, byteIndex)

Source from the content-addressed store, hash-verified

235};
236
237var parseType = function(header, byteIndex) {
238 if ((header[byteIndex] === 'I'.charCodeAt(0)) &&
239 (header[byteIndex + 1] === 'D'.charCodeAt(0)) &&
240 (header[byteIndex + 2] === '3'.charCodeAt(0))) {
241 return 'timed-metadata';
242 } else if ((header[byteIndex] & 0xff === 0xff) &&
243 ((header[byteIndex + 1] & 0xf0) === 0xf0)) {
244 return 'audio';
245 }
246 return null;
247};
248
249var parseSampleRate = function(packet) {
250 var i = 0;

Callers 2

findBoxFunction · 0.85
mux-mp4.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected