@@ -199,10 +199,10 @@ discard block |
||
199 | 199 | $this->getServiceManager()->setShared('playgroundcore_phpvideotoolkit', false); |
200 | 200 | |
201 | 201 | $this->getServiceManager()->get('playgroundcore_phpvideotoolkit') |
202 | - ->addCommand('-i', $videoSource) |
|
203 | - ->addCommand('-i', $audioSource, true) |
|
204 | - ->setOutputPath($target) |
|
205 | - ->execute(); |
|
202 | + ->addCommand('-i', $videoSource) |
|
203 | + ->addCommand('-i', $audioSource, true) |
|
204 | + ->setOutputPath($target) |
|
205 | + ->execute(); |
|
206 | 206 | return $target; |
207 | 207 | } |
208 | 208 | |
@@ -366,10 +366,10 @@ discard block |
||
366 | 366 | } |
367 | 367 | |
368 | 368 | /** |
369 | - * This method concatenate an array of sounds |
|
370 | - * ffmpeg -y -i in-1.wav -i in-2.wav -i in-3.wav |
|
371 | - * -filter_complex '[0:0][1:0][2:0]concat=n=3:v=0:a=1[out]' -map '[out]' out.wav |
|
372 | - */ |
|
369 | + * This method concatenate an array of sounds |
|
370 | + * ffmpeg -y -i in-1.wav -i in-2.wav -i in-3.wav |
|
371 | + * -filter_complex '[0:0][1:0][2:0]concat=n=3:v=0:a=1[out]' -map '[out]' out.wav |
|
372 | + */ |
|
373 | 373 | public function concatenateSounds($sounds = array(), $target) |
374 | 374 | { |
375 | 375 | if (!is_array($sounds)) { |
@@ -396,10 +396,10 @@ discard block |
||
396 | 396 | } |
397 | 397 | |
398 | 398 | /** |
399 | - * This method merge an array of sounds |
|
400 | - * ffmpeg -i in-1.wav -i in-2.wav -i in-3.wav |
|
401 | - * -filter_complex "[0:a][1:a][2:a]amerge=inputs=3[aout]" -map "[aout]" -ac 2 out.wav |
|
402 | - */ |
|
399 | + * This method merge an array of sounds |
|
400 | + * ffmpeg -i in-1.wav -i in-2.wav -i in-3.wav |
|
401 | + * -filter_complex "[0:a][1:a][2:a]amerge=inputs=3[aout]" -map "[aout]" -ac 2 out.wav |
|
402 | + */ |
|
403 | 403 | public function mergeSounds($sounds = array(), $target) |
404 | 404 | { |
405 | 405 | if (!is_array($sounds)) { |
@@ -449,9 +449,9 @@ discard block |
||
449 | 449 | } |
450 | 450 | |
451 | 451 | /** |
452 | - * this method extracts an image form a video at the $time second in the video. |
|
453 | - * ffmpeg -ss 00:00:04 -i video.mp4 -vframes 1 out.png |
|
454 | - */ |
|
452 | + * this method extracts an image form a video at the $time second in the video. |
|
453 | + * ffmpeg -ss 00:00:04 -i video.mp4 -vframes 1 out.png |
|
454 | + */ |
|
455 | 455 | public function extractImage($source, $target, $start = '00:00:01', $frames = 1) |
456 | 456 | { |
457 | 457 | $this->getServiceManager()->setShared('playgroundcore_phpvideotoolkit', false); |
@@ -472,10 +472,10 @@ discard block |
||
472 | 472 | } |
473 | 473 | |
474 | 474 | /** |
475 | - * this method splits a video into n chunks defined by the frames array. |
|
476 | - * $frames = array(array(0, 12), array(13, 110), array(111, 200)); |
|
477 | - * ffmpeg -i quickns.mov -an -vf "select=between(n\,110\,200),setpts=PTS-STARTPTS" grg.mov |
|
478 | - */ |
|
475 | + * this method splits a video into n chunks defined by the frames array. |
|
476 | + * $frames = array(array(0, 12), array(13, 110), array(111, 200)); |
|
477 | + * ffmpeg -i quickns.mov -an -vf "select=between(n\,110\,200),setpts=PTS-STARTPTS" grg.mov |
|
478 | + */ |
|
479 | 479 | public function splitVideo($source, $frames = array(), $target) |
480 | 480 | { |
481 | 481 | $this->getServiceManager()->setShared('playgroundcore_phpvideotoolkit', false); |