SourceForge has been redesigned. Learn more.
Close

Diff of /stitch.php [deb837] .. [6d8a96]  Maximize  Restore

Switch to side-by-side view

--- a/stitch.php
+++ b/stitch.php
@@ -35,18 +35,6 @@
 else if (isset($argv[2])) $dest = $argv[2];
 else {print_script_contents();}
 
-if (isset($_GET['bp']))   $black_point = $_GET['bp'];
-else if (isset($argv[3])) $black_point = $argv[3];
-else                      $black_point = 0;
-
-if (isset($_GET['wp']))   $white_point = $_GET['wp'];
-else if (isset($argv[4])) $white_point = $argv[4];
-else                      $white_point = 25;
-
-if (isset($_GET['q']))    $quality = $_GET['q'];
-else if (isset($argv[5])) $quality = $argv[5];
-else                      $quality = 92;
-
 if (!is_dir($dest)) {
   //creating a folder with access rights - 0777
   $old = umask(0);
@@ -76,25 +64,25 @@
     
     $f=update_fs($suffs[$index]);
     
-    for ($i=0;$i<9;$i++)   if (is_file("$src/{$tss}-".$f[$i])) $list1 .= " $src/{$tss}-".$f[$i];
-    for ($i=9;$i<18;$i++)  if (is_file("$src/{$tss}-".$f[$i])) $list2 .= " $src/{$tss}-".$f[$i];
-    for ($i=18;$i<27;$i++) if (is_file("$src/{$tss}-".$f[$i])) $list3 .= " $src/{$tss}-".$f[$i];
+    for ($i=0;$i<9;$i++)   $list1 .= " $src/{$tss}-".$f[$i];
+    for ($i=9;$i<18;$i++)  $list2 .= " $src/{$tss}-".$f[$i];
+    for ($i=18;$i<27;$i++) $list3 .= " $src/{$tss}-".$f[$i];
     
     //echo "dam {$suffs[$index]}\n";
     
-    //exec("enblend-mp -l 10 --no-optimize --fine-mask -a -v -w -o $dest/result_{$tss}_1.tif $list");
-    exec("enblend-mp -w -o $dest/result_{$tss}_top.tif $list1");
-    exec("enblend-mp -w -o $dest/result_{$tss}_mid.tif $list2");
-    exec("enblend-mp -w -o $dest/result_{$tss}_bot.tif $list3");
+    //exec("enblend -l 10 --no-optimize --fine-mask -a -v -w -o $dest/result_{$tss}_1.tif $list");
+    exec("enblend -l 10 -w -o $dest/result_{$tss}_top.tif $list1");
+    exec("enblend -l 10 -w -o $dest/result_{$tss}_mid.tif $list2");
+    exec("enblend -l 10 -w -o $dest/result_{$tss}_bot.tif $list3");
     
-    exec("enblend-mp --wrap='vertical' -o $dest/result_{$tss}.tif $dest/result_{$tss}_top.tif $dest/result_{$tss}_mid.tif $dest/result_{$tss}_bot.tif");
+    exec("enblend --wrap='vertical' -l 10 -o $dest/result_{$tss}.tif $dest/result_{$tss}_top.tif $dest/result_{$tss}_mid.tif $dest/result_{$tss}_bot.tif");
     unlink("$dest/result_{$tss}_top.tif");
     unlink("$dest/result_{$tss}_mid.tif");
     unlink("$dest/result_{$tss}_bot.tif");
     //exec("convert $dest/result_{$tss}.tif -level 0%,10%,1 $dest/result_{$tss}-0-10-1.jpeg");
     //exec("convert $dest/result_{$tss}.tif -level 0%,14%,1 $dest/result_{$tss}-0-14-1.jpeg");
     //exec("convert $dest/result_{$tss}.tif -level 0%,18%,1 $dest/result_{$tss}-0-18-1.jpeg");
-    exec("convert $dest/result_{$tss}.tif -level {$black_point}%,{$white_point}%,1 -quality $quality $dest/result_{$tss}-0-25-1.jpeg");
+    exec("convert $dest/result_{$tss}.tif -level 0%,25%,1 $dest/result_{$tss}-0-25-1.jpeg");
     //exec("convert $dest/result_{$tss}.tif -level 0%,50%,1 $dest/result_{$tss}-0-50-1.jpeg");
 }
 
@@ -106,13 +94,10 @@
     $found = false;
     $ts = substr($file,0,17);
     
-    $mid = "RGB24";
-    if (preg_match("/INT16/",$file)!=0) $mid = "INT16";
-
     $suf = "DECONV";//default
-    if (preg_match("/DECONV/",$file)!=0)   $suf = "DECONV-{$mid}_EQR";
-    if (preg_match("/DEMOSAIC/",$file)!=0) $suf = "DEMOSAIC-{$mid}_EQR";
-    if (preg_match("/LOWRES/",$file)!=0)   $suf = "LOWRES-{$mid}_EQR";
+    if (preg_match("/DECONV/",$file)!=0)   $suf = "DECONV-INT16_EQR";
+    if (preg_match("/DEMOSAIC/",$file)!=0) $suf = "DEMOSAIC-INT16_EQR";
+    if (preg_match("/LOWRES/",$file)!=0)   $suf = "LOWRES-INT16_EQR";
     
     foreach($timestamps as $index=>$elem) {
 	if ($ts==$elem) {