@@ -24,7 +24,6 @@ |
||
24 | 24 | /** |
25 | 25 | * Generates the Item controller |
26 | 26 | * |
27 | - * @param ServiceLocatorInterface $serviceLocator |
|
28 | 27 | * @return \PHPVideoToolkit\FfmpegProcess |
29 | 28 | */ |
30 | 29 | public function createService(ServiceLocatorInterface $serviceManager) |
@@ -25,7 +25,6 @@ |
||
25 | 25 | /** |
26 | 26 | * Generates the Item controller |
27 | 27 | * |
28 | - * @param ServiceLocatorInterface $serviceLocator |
|
29 | 28 | * @return Services_Twilio |
30 | 29 | */ |
31 | 30 | public function createService(ServiceLocatorInterface $serviceManager) |
@@ -171,7 +171,7 @@ |
||
171 | 171 | * This method will merge videos in .mpg format with exactly the same codec and codec parameters : |
172 | 172 | * http://trac.ffmpeg.org/wiki/Concatenate |
173 | 173 | * @param array $videos |
174 | - * @return string |
|
174 | + * @return boolean |
|
175 | 175 | */ |
176 | 176 | public function mergeMpgVideos($videos = false, $target = false) |
177 | 177 | { |
@@ -203,10 +203,10 @@ discard block |
||
203 | 203 | $this->serviceLocator->setShared('playgroundcore_phpvideotoolkit', false); |
204 | 204 | |
205 | 205 | $this->serviceLocator->get('playgroundcore_phpvideotoolkit') |
206 | - ->addCommand('-i', $videoSource) |
|
207 | - ->addCommand('-i', $audioSource, true) |
|
208 | - ->setOutputPath($target) |
|
209 | - ->execute(); |
|
206 | + ->addCommand('-i', $videoSource) |
|
207 | + ->addCommand('-i', $audioSource, true) |
|
208 | + ->setOutputPath($target) |
|
209 | + ->execute(); |
|
210 | 210 | return $target; |
211 | 211 | } |
212 | 212 | |
@@ -374,10 +374,10 @@ discard block |
||
374 | 374 | } |
375 | 375 | |
376 | 376 | /** |
377 | - * This method concatenate an array of sounds |
|
378 | - * ffmpeg -y -i in-1.wav -i in-2.wav -i in-3.wav |
|
379 | - * -filter_complex '[0:0][1:0][2:0]concat=n=3:v=0:a=1[out]' -map '[out]' out.wav |
|
380 | - */ |
|
377 | + * This method concatenate an array of sounds |
|
378 | + * ffmpeg -y -i in-1.wav -i in-2.wav -i in-3.wav |
|
379 | + * -filter_complex '[0:0][1:0][2:0]concat=n=3:v=0:a=1[out]' -map '[out]' out.wav |
|
380 | + */ |
|
381 | 381 | public function concatenateSounds($sounds, $target) |
382 | 382 | { |
383 | 383 | if (empty($sounds)) { |
@@ -407,10 +407,10 @@ discard block |
||
407 | 407 | } |
408 | 408 | |
409 | 409 | /** |
410 | - * This method merge an array of sounds |
|
411 | - * ffmpeg -i in-1.wav -i in-2.wav -i in-3.wav |
|
412 | - * -filter_complex "[0:a][1:a][2:a]amerge=inputs=3[aout]" -map "[aout]" -ac 2 out.wav |
|
413 | - */ |
|
410 | + * This method merge an array of sounds |
|
411 | + * ffmpeg -i in-1.wav -i in-2.wav -i in-3.wav |
|
412 | + * -filter_complex "[0:a][1:a][2:a]amerge=inputs=3[aout]" -map "[aout]" -ac 2 out.wav |
|
413 | + */ |
|
414 | 414 | public function mergeSounds($sounds, $target) |
415 | 415 | { |
416 | 416 | if (empty($sounds)) { |
@@ -464,9 +464,9 @@ discard block |
||
464 | 464 | } |
465 | 465 | |
466 | 466 | /** |
467 | - * this method extracts an image form a video at the $time second in the video. |
|
468 | - * ffmpeg -ss 00:00:04 -i video.mp4 -vframes 1 out.png |
|
469 | - */ |
|
467 | + * this method extracts an image form a video at the $time second in the video. |
|
468 | + * ffmpeg -ss 00:00:04 -i video.mp4 -vframes 1 out.png |
|
469 | + */ |
|
470 | 470 | public function extractImage($source, $target, $start = '00:00:01', $frames = 1) |
471 | 471 | { |
472 | 472 | $this->serviceLocator->setShared('playgroundcore_phpvideotoolkit', false); |
@@ -487,10 +487,10 @@ discard block |
||
487 | 487 | } |
488 | 488 | |
489 | 489 | /** |
490 | - * this method splits a video into n chunks defined by the frames array. |
|
491 | - * $frames = array(array(0, 12), array(13, 110), array(111, 200)); |
|
492 | - * ffmpeg -i quickns.mov -an -vf "select=between(n\,110\,200),setpts=PTS-STARTPTS" grg.mov |
|
493 | - */ |
|
490 | + * this method splits a video into n chunks defined by the frames array. |
|
491 | + * $frames = array(array(0, 12), array(13, 110), array(111, 200)); |
|
492 | + * ffmpeg -i quickns.mov -an -vf "select=between(n\,110\,200),setpts=PTS-STARTPTS" grg.mov |
|
493 | + */ |
|
494 | 494 | public function splitVideo($source, $frames, $target) |
495 | 495 | { |
496 | 496 | if (empty($frames)) { |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | ->addPreInputCommand('-pattern_type', 'glob') |
77 | 77 | ->addCommand('-i', $path) |
78 | 78 | ->addCommand('-c:v', 'libx264') |
79 | - ->addCommand('-vf', 'fps='. $fps) |
|
79 | + ->addCommand('-vf', 'fps='.$fps) |
|
80 | 80 | ->addCommand('-pix_fmt', 'yuv420p') |
81 | 81 | ->setOutputPath($target) |
82 | 82 | ->execute(); |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | ->addPreInputCommand('-pattern_type', 'glob') |
108 | 108 | ->addCommand('-i', $path) |
109 | 109 | ->addCommand('-vcodec', 'qtrle') |
110 | - ->addCommand('-vf', 'fps='. $fps) |
|
110 | + ->addCommand('-vf', 'fps='.$fps) |
|
111 | 111 | ->setOutputPath($target) |
112 | 112 | ->execute(); |
113 | 113 | } catch (FfmpegProcessOutputException $e) { |
@@ -180,7 +180,7 @@ discard block |
||
180 | 180 | $this->serviceLocator->setShared('playgroundcore_phpvideotoolkit', false); |
181 | 181 | $this->serviceLocator->get('playgroundcore_phpvideotoolkit') |
182 | 182 | ->addPreInputCommand('-y') |
183 | - ->addCommand('-i', 'concat:' . implode('|', $videos)) |
|
183 | + ->addCommand('-i', 'concat:'.implode('|', $videos)) |
|
184 | 184 | ->addCommand('-c', 'copy') |
185 | 185 | ->addCommand('-bsf:a', 'aac_adtstoasc') |
186 | 186 | ->addCommand('-bufsize', '1835k') |
@@ -295,7 +295,7 @@ discard block |
||
295 | 295 | foreach ($layer as $k => $l) { |
296 | 296 | $ffmpeg->addCommand('-i', $l, true); |
297 | 297 | $overlay .= 'overlay=format=rgb'; |
298 | - if ($k<count($layer)-1) { |
|
298 | + if ($k < count($layer) - 1) { |
|
299 | 299 | $overlay .= ','; |
300 | 300 | } |
301 | 301 | } |
@@ -396,7 +396,7 @@ discard block |
||
396 | 396 | $ffmpeg->addCommand('-i', $s, true); |
397 | 397 | $concat .= '['.$k.':0]'; |
398 | 398 | } |
399 | - $concat .= 'concat=n='. count($sounds) .':v=0:a=1[out]'; |
|
399 | + $concat .= 'concat=n='.count($sounds).':v=0:a=1[out]'; |
|
400 | 400 | |
401 | 401 | $ffmpeg->addCommand('-filter_complex', $concat) |
402 | 402 | ->addCommand('-map', '[out]') |
@@ -429,7 +429,7 @@ discard block |
||
429 | 429 | $ffmpeg->addCommand('-i', $s, true); |
430 | 430 | $merge .= '['.$k.':a]'; |
431 | 431 | } |
432 | - $merge .= 'amerge=inputs='. count($sounds) .'[aout]'; |
|
432 | + $merge .= 'amerge=inputs='.count($sounds).'[aout]'; |
|
433 | 433 | |
434 | 434 | $ffmpeg->addCommand('-filter_complex', $merge) |
435 | 435 | ->addCommand('-map', '[aout]') |
@@ -450,8 +450,8 @@ discard block |
||
450 | 450 | { |
451 | 451 | $this->serviceLocator->setShared('playgroundcore_phpvideotoolkit', false); |
452 | 452 | |
453 | - $text = "fontfile=$font:text='". $message."':fontsize=". |
|
454 | - $fontSize .":fontcolor=" . $fontColor . ":x=".$x.":y=".$y; |
|
453 | + $text = "fontfile=$font:text='".$message."':fontsize=". |
|
454 | + $fontSize.":fontcolor=".$fontColor.":x=".$x.":y=".$y; |
|
455 | 455 | |
456 | 456 | $this->serviceLocator->get('playgroundcore_phpvideotoolkit') |
457 | 457 | ->addPreInputCommand('-y') |
@@ -498,14 +498,14 @@ discard block |
||
498 | 498 | } |
499 | 499 | $this->serviceLocator->setShared('playgroundcore_phpvideotoolkit', false); |
500 | 500 | |
501 | - $i=1; |
|
501 | + $i = 1; |
|
502 | 502 | foreach ($frames as $frame) { |
503 | 503 | $this->serviceLocator->get('playgroundcore_phpvideotoolkit') |
504 | 504 | ->addPreInputCommand('-y') |
505 | 505 | ->addCommand('-i', $source) |
506 | 506 | ->addCommand('-an') |
507 | - ->addCommand('-vf', 'select=between(n\,' . $frame[0] . '\,' . $frame[1] . '),setpts=PTS-STARTPTS') |
|
508 | - ->setOutputPath($target . sprintf('s%02d', $i) . '.mov') |
|
507 | + ->addCommand('-vf', 'select=between(n\,'.$frame[0].'\,'.$frame[1].'),setpts=PTS-STARTPTS') |
|
508 | + ->setOutputPath($target.sprintf('s%02d', $i).'.mov') |
|
509 | 509 | ->execute(); |
510 | 510 | $i++; |
511 | 511 | } |
@@ -28,8 +28,7 @@ |
||
28 | 28 | |
29 | 29 | /** |
30 | 30 | * This method calls Google ReCaptcha. |
31 | - * @param unknown_type $url |
|
32 | - * @return unknown |
|
31 | + * @return boolean |
|
33 | 32 | */ |
34 | 33 | public function recaptcha($response, $ipClient = null) |
35 | 34 | { |
@@ -41,7 +41,6 @@ |
||
41 | 41 | /** |
42 | 42 | * Sets the path to the blacklist file |
43 | 43 | * |
44 | - * @param string $path to the blacklist file |
|
45 | 44 | * @return Blacklist Provides a fluent interface |
46 | 45 | * @throws Exception\InvalidArgumentException When file is not found |
47 | 46 | */ |
@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | const FORBIDDEN = 'FORBIDDEN'; |
11 | 11 | |
12 | 12 | protected $options = array( |
13 | - 'file' => null, // File containing the blacklist file |
|
13 | + 'file' => null, // File containing the blacklist file |
|
14 | 14 | ); |
15 | 15 | |
16 | 16 | protected $messageTemplates = array( |
@@ -20,9 +20,9 @@ discard block |
||
20 | 20 | public function __construct($options = null) |
21 | 21 | { |
22 | 22 | if (is_string($options)) { |
23 | - $this->options = array('file' => str_replace('\\', '/', getcwd()) . '/' . ltrim($options, '/')); |
|
23 | + $this->options = array('file' => str_replace('\\', '/', getcwd()).'/'.ltrim($options, '/')); |
|
24 | 24 | } elseif (is_array($options)) { |
25 | - $this->options = array('file' => str_replace('\\', '/', getcwd()) . $options[0]); |
|
25 | + $this->options = array('file' => str_replace('\\', '/', getcwd()).$options[0]); |
|
26 | 26 | } |
27 | 27 | |
28 | 28 | parent::__construct($options); |
@@ -41,7 +41,6 @@ |
||
41 | 41 | /** |
42 | 42 | * Sets the path to the file |
43 | 43 | * |
44 | - * @param string $path to the file |
|
45 | 44 | * @return MailDomain Provides a fluent interface |
46 | 45 | * @throws Exception\InvalidArgumentException When file is not found |
47 | 46 | */ |
@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | const FORBIDDEN = 'FORBIDDEN'; |
11 | 11 | |
12 | 12 | protected $options = array( |
13 | - 'file' => null, // File containing the authorized domains |
|
13 | + 'file' => null, // File containing the authorized domains |
|
14 | 14 | ); |
15 | 15 | |
16 | 16 | protected $messageTemplates = array( |
@@ -20,9 +20,9 @@ discard block |
||
20 | 20 | public function __construct($options = null) |
21 | 21 | { |
22 | 22 | if (is_string($options)) { |
23 | - $this->options = array('file' => str_replace('\\', '/', getcwd()) . '/' . ltrim($options, '/')); |
|
23 | + $this->options = array('file' => str_replace('\\', '/', getcwd()).'/'.ltrim($options, '/')); |
|
24 | 24 | } elseif (is_array($options)) { |
25 | - $this->options = array('file' => str_replace('\\', '/', getcwd()) . '/' . ltrim(reset($options), '/')); |
|
25 | + $this->options = array('file' => str_replace('\\', '/', getcwd()).'/'.ltrim(reset($options), '/')); |
|
26 | 26 | } |
27 | 27 | |
28 | 28 | parent::__construct($this->options); |
@@ -36,7 +36,6 @@ |
||
36 | 36 | protected $request; |
37 | 37 | |
38 | 38 | /** |
39 | - * @param \Zend\View\Helper\HeadMeta $metaData |
|
40 | 39 | * @return \Zend\View\Helper\HeadMeta |
41 | 40 | */ |
42 | 41 | public function __invoke() |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | * General module configurations |
48 | 48 | */ |
49 | 49 | if (isset($this->Config['BasePath'])) { |
50 | - $CKEditor->basePath = $this->Config['BasePath'].'/'; |
|
50 | + $CKEditor->basePath = $this->Config['BasePath'].'/'; |
|
51 | 51 | } |
52 | 52 | if (isset($this->Config['Toolbar'])) { |
53 | 53 | $CKEditor->config['toolbar'] = $this->Config['Toolbar']; |
@@ -68,10 +68,10 @@ discard block |
||
68 | 68 | $CKEditor->config['stylesSet'] = $this->Config['stylesSet']; |
69 | 69 | } |
70 | 70 | if (isset($this->Config['contentsCss'])) { |
71 | - $CKEditor->config['contentsCss']= $this->Config['contentsCss']; |
|
71 | + $CKEditor->config['contentsCss'] = $this->Config['contentsCss']; |
|
72 | 72 | } |
73 | 73 | if (isset($this->Config['templates_files'])) { |
74 | - $CKEditor->config['templates_files'] = $this->Config['templates_files']; |
|
74 | + $CKEditor->config['templates_files'] = $this->Config['templates_files']; |
|
75 | 75 | } |
76 | 76 | |
77 | 77 | // El Finder |
@@ -116,7 +116,7 @@ discard block |
||
116 | 116 | $CKEditor->config['contentsCss'] = $options['contentsCss']; |
117 | 117 | } |
118 | 118 | if (isset($options['templates_files'])) { |
119 | - $CKEditor->config['templates_files'] = $options['templates_files']; |
|
119 | + $CKEditor->config['templates_files'] = $options['templates_files']; |
|
120 | 120 | } |
121 | 121 | |
122 | 122 | // El Finder |
@@ -50,11 +50,11 @@ discard block |
||
50 | 50 | return $locales; |
51 | 51 | } |
52 | 52 | |
53 | - /** |
|
54 | - * getLocaleService : Recuperer le service des locales |
|
55 | - * |
|
56 | - * @return Service/Locale $localeService |
|
57 | - */ |
|
53 | + /** |
|
54 | + * getLocaleService : Recuperer le service des locales |
|
55 | + * |
|
56 | + * @return Service/Locale $localeService |
|
57 | + */ |
|
58 | 58 | public function getLocaleService() |
59 | 59 | { |
60 | 60 | if ($this->localeService === null) { |
@@ -64,8 +64,8 @@ discard block |
||
64 | 64 | } |
65 | 65 | |
66 | 66 | /** |
67 | - * setLocaleService : set le service locale |
|
68 | - */ |
|
67 | + * setLocaleService : set le service locale |
|
68 | + */ |
|
69 | 69 | public function setLocaleService($localeService) |
70 | 70 | { |
71 | 71 | $this->localeService = $localeService; |