JN_newbie
JN_newbie

Reputation: 6062

setup ffmpeg on ubuntu and node.js

I am new to ubuntu and I am struggling in setting up ffmpeg installation on the ubuntu server. I have install the ffmpeg on ubuntu and also I can see it by issuing a command ffmpeg -v. I have done the development in node.js in windows and specify the path of ffmpeg. Below is the path of window in node.js:

proc.setFfmpegPath("D:\\abc\\ffmpeg-20121120-git-8b6aeb1-win64-static\\bin\\ffmpeg.exe");

but now I have to specify the path for ffmpeg for ubuntu in my node.js code.

proc.setFfmpegPath("/usr/bin/ffmpeg/ffmpeg");

it says Uncaught Error: spawn ENOTDIR

Even though I have tried with this path:

proc.setFfmpegPath("/usr/bin/ffmpeg");

then it says An error happened: ffmpeg exited with code 1

Also I have run this command "whereis ffmpeg" and it says "/usr/bin/ffmpeg"

Any help is very much appreciated

Upvotes: 0

Views: 1528

Answers (1)

Trott
Trott

Reputation: 70075

This one is correct:

proc.setFfmpegPath("/usr/bin/ffmpeg");

It is returning error code 1, which means that it is executing the ffmpeg but ffmpeg is not successfully running to completion. Try running it on the command line to see if there are any obvious problems. If that doesn't work, you'll have to dig in with some more logging and/or debugging.

Upvotes: 1

Related Questions