[MEncoder-users] PHP cannot execute some encoding commands

Ivo ivop at euronet.nl
Tue Aug 29 11:38:59 CEST 2006


On Tuesday 29 August 2006 03:24, Ko Ko wrote:
>   But when I use this command with PHP
>
>   mplayer -frames 5 -vo jpeg:outdir=$outdir:quality=100 -contrast 20
> test.mpg
>
>   It doesn't produce any jpeg images from test.mp file.
>
>   I try out the same set of command on my Fedora itself as root or normal
> user it is manage to create output directory and produce the jpeg images.
>
>   I have no idea why PHP command won't execute this command correctly.
>
>   Can anyone help me with this? =(

Try redirecting stdout/stderr to a file. Something like:

exec('mplayer -v -frames 5 -vo jpeg:outdir=somedir:quality=100 -contrast 20 
>logfile.log 2>&1');

Notice that I added -v so the output will be more verbose. Now look at 
logfile.log to see what actually happened and why it failed.

--Ivo



More information about the MEncoder-users mailing list