Lines Matching refs:buffer
218 function protoDecoder(buffer, fileType, fileName, store) { argument
219 var decoded = fileType.decoderParams.protoType.decode(buffer);
228 let blobUrl = URL.createObjectURL(new Blob([buffer], { type: fileType.dataType.mime }));
232 function videoDecoder(buffer, fileType, fileName, store) { argument
233 let [data, timeline] = fileType.decoderParams.videoDecoder(buffer);
268 function decodedFile(fileType, buffer, fileName, store) { argument
269 return [fileType, fileType.decoder(buffer, fileType, fileName, store)];
272 function detectAndDecode(buffer, fileName, store) { argument
273 if (arrayStartsWith(buffer, LAYER_TRACE_MAGIC_NUMBER)) {
274 return decodedFile(FILE_TYPES['layers_trace'], buffer, fileName, store);
276 if (arrayStartsWith(buffer, WINDOW_TRACE_MAGIC_NUMBER)) {
277 return decodedFile(FILE_TYPES['window_trace'], buffer, fileName, store);
279 if (arrayStartsWith(buffer, MPEG4_MAGIC_NMBER)) {
280 return decodedFile(FILE_TYPES['screen_recording'], buffer, fileName, store);
282 if (arrayStartsWith(buffer, WAYLAND_TRACE_MAGIC_NUMBER)) {
283 return decodedFile(FILE_TYPES['wl_trace'], buffer, fileName, store);
285 if (arrayStartsWith(buffer, PROTO_LOG_MAGIC_NUMBER)) {
286 return decodedFile(FILE_TYPES['proto_log'], buffer, fileName, store);
290 return decodedFile(FILE_TYPES[name], buffer, fileName, store);