itpixelz / phpvideotoolkit

Automatically exported from code.google.com/p/phpvideotoolkit
0 stars 0 forks source link

bad -sameq '' parameteter #6

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. when converting to flv the -sameq param is set by default. thi 
beaks ffmpeg on mac ports

What is the expected output? What do you see instead?
Ffmpeg says "Unable for find a suitable output format for ''"

What version of the product are you using? On what operating system?
v 0.1.5 on OSX 10.5 

Please provide any additional information below.
Output log file attached.
Putting this in the _combineCommands:
[code]
$command_string = trim($command.($argument ? ' '.$argument : ''));
if ($command == '-sameq') $command_string = '-sameq';   
[/code]
fixes the issue.
But I recommend extending PHPVideoToolkit and overwriting 
setFormatToFLV(). Instead of:

$this->addCommand('-sameq');

a better result is obtained with:

$this->addCommand('-qmin', 3);
$this->addCommand('-qmax', 6);
$this->addCommand('-r', 25);

Original issue reported on code.google.com by cosmin.c...@gmail.com on 14 Oct 2009 at 3:52

Attachments:

GoogleCodeExporter commented 8 years ago
it seems to be a general issue with ffmpeg not accepting the "-command ''" 
syntax. 
The fix would be:
if ($argument == "''") $command_string = $command;

Original comment by cosmin.c...@gmail.com on 14 Oct 2009 at 6:34

GoogleCodeExporter commented 8 years ago
When you say a better result is acheived with

$this->addCommand('-qmin', 3);
$this->addCommand('-qmax', 6);
$this->addCommand('-r', 25);

do you mean that it works or the video is of better quality?

Original comment by bugged...@gmail.com on 15 Dec 2009 at 10:13

GoogleCodeExporter commented 8 years ago
This error happens for params, with empty args? Such as "-sameq". So the 
desision to 
fix this bug is change line:
$command_string = trim($command.($argument ? ' '.$argument : ''));
to:
$command_string = trim($command.($argument !== "''" ? ' '.$argument : ''));
in _combineCommands function. 

Tested on ubuntu.

Original comment by fedulov.ivan on 27 Feb 2010 at 8:51

GoogleCodeExporter commented 8 years ago
PHPVideoToolkit has been updated to version 2.

Original comment by bugged...@gmail.com on 20 Mar 2013 at 11:37