mxf file doesn't support? #1807
-
hi, I have a question. I need to use an mxf file, but I get the above error when entering the link, is it possible that mxf files are not supported? Sample file: https://filesamples.com/samples/video/mxf/sample_1280x720_surfing_with_audio.mxf I changed ...
const commonFormatsAndDetectedFormat = useMemo(
() =>
new Set([
...commonVideoAudioFormats,
...commonAudioFormats,
commonSubtitleFormats,
detectedFileFormat !== "mxf" ? detectedFileFormat : null // I changed
]),
[detectedFileFormat]
);
... |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
Hi. I just tried to open your file and it works for me. I'm also able to cut/export. what's your problem exactly and which version are you on? |
Beta Was this translation helpful? Give feedback.
-
I'm using v3.55.7. When I dragged and dropped the MXF file ( https://filesamples.com/samples/video/mxf/sample_1280x720_surfing_with_audio.mxf ), I was getting the following error. "File not natively supported. Preview may have no audio or low quality. The final export will however be lossless with audio. You may convert it from the menu for a better preview with audio." The following error appears in the console. The error seems to occur in // App.jsx
const onVideoError = useCallback(async () => {
const { error } = videoRef.current;
if (!error) return;
if (!fileUri) return; // Probably MEDIA_ELEMENT_ERROR: Empty src attribute
console.error("onVideoError", error.message, error.code); // just test
try {
const PIPELINE_ERROR_DECODE = 3; // This usually happens when the user presses play or seeks, but the video is not actually playable. To reproduce: "RX100VII PCM audio timecode.MP4" or see https://github.com/mifi/lossless-cut/issues/804
const MEDIA_ERR_SRC_NOT_SUPPORTED = 4; // Test: issue-668-3.20.1.m2ts - NOTE: DEMUXER_ERROR_COULD_NOT_OPEN and DEMUXER_ERROR_NO_SUPPORTED_STREAMS is also 4
if (!([MEDIA_ERR_SRC_NOT_SUPPORTED, PIPELINE_ERROR_DECODE].includes(error.code) && !usingPreviewFile && filePath))
return;
// this error can happen half way into playback if the file has some corruption
// example: "DEMUXER_ERROR_COULD_NOT_PARSE: FFmpegDemuxer: PTS is not defined 4"
if (error.code === MEDIA_ERR_SRC_NOT_SUPPORTED && error.message?.startsWith("DEMUXER_ERROR_COULD_NOT_PARSE"))
return;
if (workingRef.current) return;
try {
setWorking(i18n.t("Converting to supported format"));
console.log("Trying to create preview");
when(!isDurationValid(await getDuration(filePath)), () => {
throw new Error("Invalid duration");
});
when(hasVideo, async () => {
!isDurationValid(await getDuration(filePath));
showUnsupportedFileMessage();
});
when(hasAudio, async () => {
await html5ifyAndLoadWithPreferences(customOutDir, filePath, "fastest-audio", hasVideo, hasAudio);
showUnsupportedFileMessage();
});
} catch (err) {
console.error(err);
showPlaybackFailedMessage();
} finally {
setWorking();
}
} catch (err) {
handleError(err);
}
}, [
fileUri,
usingPreviewFile,
filePath,
setWorking,
hasVideo,
hasAudio,
html5ifyAndLoadWithPreferences,
customOutDir,
showUnsupportedFileMessage
]); This code is not touched at all. I see that the latest release is 3.58.0, is it much different from my version? |
Beta Was this translation helpful? Give feedback.
but it will still play back, right? but with lower quality? it just means that the player doesn't natively support mxf, but you can use the file menu to convert it to a supported format for preview, see FAQ