Ver Fonte

gallery nice

amic há 1 semana atrás
pai
commit
ded03c6736
1 ficheiros alterados com 2 adições e 2 exclusões
  1. 2 2
      modules/manager/models/Gallery.php

+ 2 - 2
modules/manager/models/Gallery.php

@@ -60,7 +60,7 @@ class Gallery extends \app\models\base\Gallery
 							$ifile = $this->copyName;
 							$fork = " >/dev/null &";
 						}
-                        exec("nice -n 1 convert -define jpeg:size=".$width."x".$height."+0+0 ".$ifile." -thumbnail ".$w."x".$h."^ -gravity center -background '#FFFFFF' $addp ".$file);
+                        exec("nice -n 5 convert -define jpeg:size=".$width."x".$height."+0+0 ".$ifile." -thumbnail ".$w."x".$h."^ -gravity center -background '#FFFFFF' $addp ".$file);
 						$this->tmpName = $file;
 //						file_put_contents($file.".sh", "nice -n 1 convert -define jpeg:size=".$width."x".$height."+0+0 ".$ifile." -thumbnail ".$w."x".$h."^ -gravity center -background '#FFFFFF' $addp ".$file);
 //						echo "convert -define jpeg:size=".$width."x".$height."+0+0 ".$meta['filepath']." -thumbnail ".$w."x".$h."^ -gravity center -background '#FFFFFF' $addp ".$file;
@@ -147,7 +147,7 @@ class Gallery extends \app\models\base\Gallery
 							$fork = " >/dev/null &";
 							list($width, $height) = getimagesize($ifile);
 						}
-                        exec("nice -n 1 convert -define jpeg:size=".$width."x".$height."+0+0 ".$ifile." -thumbnail ".$w."x".$h."^ -gravity center -background '#FFFFFF' $addp ".$file.$fork);
+                        exec("nice -n 5 convert -define jpeg:size=".$width."x".$height."+0+0 ".$ifile." -thumbnail ".$w."x".$h."^ -gravity center -background '#FFFFFF' $addp ".$file.$fork);
 //						echo "convert -define jpeg:size=".$width."x".$height."+0+0 ".$meta['filepath']." -thumbnail ".$w."x".$h."^ -gravity center -background '#FFFFFF' $addp ".$file;
 						return true;
                     },