[FFmpeg-user] Detecting errors

Murthy avsn avsn9849625263 at hotmail.com
Fri Aug 17 04:40:15 CEST 2012





> > > > Hi all,
> > > > I am calling 'ffmpeg' from PHP to encode a video.here id how I am
> > calling. exec(''ffmpeg -i inputfile outputfile 2>result.log");
> > > > I am trying to redirect stderr to a text file.ProblemI was expecting
> > only errors to be written to log file but the entire console output is
> > being written to file.Is there a way to only display error with ffmpeg.How
> > can I find a encoding failure by looking at the console out put.
> > > > Please help me.
> > >
> > > Look into the -loglevel option. If you set it to "-loglevel warning"
> > > or "-loglevel error" you'll just get messages with a minimum priority
> > > of warning or error (respectively).
> > >
> > > --Michael
> >
> >
> > Thanks Michael
> > I think -loglevel 'error' is working for me.I am also using -report to
> > make output of the command to a file .
> > Thank you all.
> >
> 
> the loglevel error didn't work for me...it was empty all the time.
> Why was so?
> 
> thanks

I was using the  following command
"ffmpeg -i <input> -v 'error' <output>"
the terminal was empty till the encoding is finished. I again tried out with a non existing file like this
   "ffmpeg -i <nonexistingfile> -v 'error' <output>"
      I got an error < No such file or directory>.  You may get empty if no error is found while encoding.I will be trying this in real time from a while from now.I will post to same thread If I found any issues.
Sorry if it is too early to post as 'It worked'.

Thank you.





 		 	   		  


More information about the ffmpeg-user mailing list