I give a try with your code and i get same result. After searching a while, i found an explanation.
Well, problem is around MP4 and streams.
I am not a specialist of video, but it seems that when manipulating MP4 file, ffmpeg need to seek into file ans seeking is incompatible with streams by nature.
So you need to output a filesystem file from ffmpeg (make this file temporary by removing it after using it) and then use this file according to your needs.
For having more debug information about ffmpeg error you need to modify your error event listener code like this:
// .format('mp4') .on('error', function (err, stdout, stderr) { console.log(Error: ${err}) console.log('Stdout: %o', stdout); console.log('Stderr: %o', stderr); }) .on('progress', function (progress) {
And you will see while executing the stderr logs of the ffmpeg process.
You can have confirmation of this here: