46 lines
1.6 KiB
JavaScript
46 lines
1.6 KiB
JavaScript
// Metro module 4782 (f4783).
|
|
import { getFileChunk, isFlvStringIncluded, isftypStringIncluded, findMatroskaDocTypeElements } from "./fetchFromObject";
|
|
import { FileTypes } from "./Module4775";
|
|
export function isAVI(a0) {
|
|
return FileTypes.checkByFileType((0, getFileChunk)(a0), "avi");
|
|
}
|
|
export function isFLV(a0) {
|
|
const r11 = (0, getFileChunk)(a0);
|
|
return !!FileTypes.checkByFileType(r11, "flv") && (0, isFlvStringIncluded)(r11);
|
|
}
|
|
export function isM4V(a0) {
|
|
const r11 = (0, getFileChunk)(a0);
|
|
return !!FileTypes.checkByFileType(r11, "m4v") && (0, isftypStringIncluded)(r11);
|
|
}
|
|
export function isMKV(a0) {
|
|
const r12 = (0, getFileChunk)(a0, 64);
|
|
return !!FileTypes.checkByFileType(r12, "mkv") && (0, findMatroskaDocTypeElements)(r12) === "mkv";
|
|
}
|
|
export function isMOV(a0) {
|
|
return FileTypes.checkByFileType((0, getFileChunk)(a0), "mov");
|
|
}
|
|
export function isMP4(a0, a1) {
|
|
const r6 = (0, getFileChunk)(a0);
|
|
let r18 = !!FileTypes.checkByFileType(r6, "mp4");
|
|
if (!r18) {
|
|
const excludeSimilarTypes = a1?.excludeSimilarTypes;
|
|
let r23 = !excludeSimilarTypes;
|
|
if (!excludeSimilarTypes) {
|
|
const r27 = (0, getFileChunk)(r6);
|
|
r23 = !!FileTypes.checkByFileType(r27, "m4v") && (0, isftypStringIncluded)(r27);
|
|
}
|
|
r18 = r23;
|
|
}
|
|
return r18;
|
|
}
|
|
export function isOGG(a0) {
|
|
return FileTypes.checkByFileType((0, getFileChunk)(a0), "ogg");
|
|
}
|
|
export function isSWF(a0) {
|
|
return FileTypes.checkByFileType((0, getFileChunk)(a0), "swf");
|
|
}
|
|
export function isWEBM(a0) {
|
|
const r12 = (0, getFileChunk)(a0, 64);
|
|
return !!FileTypes.checkByFileType(r12, "webm") && (0, findMatroskaDocTypeElements)(r12) === "webm";
|
|
}
|