-
Notifications
You must be signed in to change notification settings - Fork 11
Description
I've been working on an Electron project and am using fluent-ffmpeg. I need to be able to create an output file that is x number of copies of a loop file. I'm able to accomplish what I need in the Mac version but Windows is killing me. Searching for an alternative way to tap into ffmpeg to accomplish this in Windows.
I was hoping I could do something like this...
ffmpeg -i "concat:audio-1.mp3|audio-1.mp3" -acodec copy out.mp3
... and let it concat the input file on to itself. On the command line it results in the original file length so it's ignoring anything that refers back to itself. Is there a way using audioconcat to accomplish this?
What I'm currently doing using fluent-ffmpeg is:
// variables declared earlier in the script
proc.videoFilter('-lavfi');
if(process.platform == 'win32') {
proc.videoFilter(`amovie=${audioFile}:aloop=${data.numLoops}`);
} else {
proc.addOption('-filter_complex', `amovie=${data.filepath}:loop=${data.numLoops}`);
}
Like I said, it works on Mac but not in Windows. It doesn't throw an error, just copies the input file to the output file. Using...
proc.addOption('-filter_complex', `amovie=${data.filepath}:loop=${data.numLoops}`);
...causes an error in Windows.