// seems like ffmpeg handles this itself well when encoding same source file
// if (videoLevel != null) args.push(`-level:${outputIndex}`, videoLevel);
// if (videoProfile != null) args.push(`-profile:${outputIndex}`, videoProfile);
returnargs;
}
constmapStreamsArgs=getMapStreamsArgs({
allFilesMeta,
copyFileStreams,
outFormat,
getVideoArgs,
});
constffmpegArgs=[
'-hide_banner',
// No progress if we set loglevel warning :(
// '-loglevel', 'warning',
'-ss',cutFrom.toFixed(5),// if we don't -ss before -i, seeking will be slow for long files, see https://github.com/mifi/lossless-cut/issues/126#issuecomment-1135451043
'-i',filePath,
'-ss','0',// If we don't do this, the output seems to start with an empty black after merging with the encoded part
'-t',(cutTo-cutFrom).toFixed(5),
...mapStreamsArgs,
// See https://github.com/mifi/lossless-cut/issues/170
// seems like ffmpeg handles this itself well when encoding same source file
// if (videoLevel != null) args.push(`-level:${outputIndex}`, videoLevel);
// if (videoProfile != null) args.push(`-profile:${outputIndex}`, videoProfile);
returnargs;
}
constmapStreamsArgs=getMapStreamsArgs({
allFilesMeta,
copyFileStreams,
outFormat,
getVideoArgs,
});
constffmpegArgs=[
'-hide_banner',
// No progress if we set loglevel warning :(
// '-loglevel', 'warning',
'-ss',cutFrom.toFixed(5),// if we don't -ss before -i, seeking will be slow for long files, see https://github.com/mifi/lossless-cut/issues/126#issuecomment-1135451043
'-i',filePath,
'-ss','0',// If we don't do this, the output seems to start with an empty black after merging with the encoded part
'-t',(cutTo-cutFrom).toFixed(5),
...mapStreamsArgs,
// See https://github.com/mifi/lossless-cut/issues/170