Node-fluent-ffmpeg: ffmpeg exited with code 1: pipe:1: Invalid argument | stream h264, express

Created on 1 Nov 2018  路  4Comments  路  Source: fluent-ffmpeg/node-fluent-ffmpeg

Version information

  • fluent-ffmpeg version: 2.1.2
  • ffmpeg version: 2.8.15
  • OS: Ubuntu X64 16.04

Code to reproduce

Modified example:

  app.get('/video', function (req, res) {

    const head = {
      //'Content-Length': fileSize,
      'Content-Type': 'video/mp4'
    };

    res.writeHead(200, head);


var proc = ffmpeg("./video.webm")
    // use the 'flashvideo' preset (located in /lib/presets/flashvideo.js)
    //.preset('flashvideo')
    .videoCodec("libx264")
    // setup event handlers
    .on('end', function() {
      console.log('file has been converted succesfully');
    })
    .on('error', function(err) {
      console.log('an error happened: ' + err.message);
    })
    // save to stream
.pipe(res, {end:true});



});

(note: if the problem only happens with some inputs, include a link to such an input file)

Expected results

Stream to HTTP client (h264/mp4)

Observed results

ffmpeg exit with code 1, "invalid argument" -> "pipe:1"

Checklist

  • [X] I have read the FAQ
  • [x] I tried the same with command line ffmpeg and it works correctly (hint: if the problem also happens this way, this is an ffmpeg problem and you're not reporting it to the right place)
  • [X] I have included full stderr/stdout output from ffmpeg

STDERR.txt

Most helpful comment

Same problem, did you find something?

All 4 comments

Same problem, did you find something?

same problem.

I would make a fork and fix the bug.
But i dont want to waste my time.

It looks like the maintainer is active on github, but not in this repositroy.
When he would comment that he merge the fix, i would debug & fix the problem.

add .format

Link here

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jfrux picture jfrux  路  4Comments

345ml picture 345ml  路  6Comments

odigity picture odigity  路  4Comments

danielbanfield picture danielbanfield  路  5Comments

timkendall picture timkendall  路  7Comments