Commit c2de0cdf authored by Andrey Filippov's avatar Andrey Filippov
Browse files

cleanup

parent 695dfdbd
Loading
Loading
Loading
Loading
+39 −31
Original line number Original line Diff line number Diff line
@@ -5017,6 +5017,14 @@ private Panel panel1,
		if (DEBUG_LEVEL > -2){
		if (DEBUG_LEVEL > -2){
			System.out.println("++++++++++++++ Calculating combined correlations ++++++++++++++");
			System.out.println("++++++++++++++ Calculating combined correlations ++++++++++++++");
		}
		}
		// reset if ran after 3d model to save memory
		if (QUAD_CLT.tp != null) {
			QUAD_CLT.tp.clt_3d_passes = null; // resetCLTPasses();
		}
		if (QUAD_CLT_AUX.tp != null) {
			QUAD_CLT_AUX.tp.clt_3d_passes = null; // resetCLTPasses();
		}

		try {
		try {
			TWO_QUAD_CLT.processCLTQuadCorrPairs(
			TWO_QUAD_CLT.processCLTQuadCorrPairs(
					QUAD_CLT, // QuadCLT quadCLT_main,
					QUAD_CLT, // QuadCLT quadCLT_main,
+3 −16
Original line number Original line Diff line number Diff line
@@ -8915,28 +8915,15 @@ public class QuadCLT {


		  int image_width = imp.getWidth();
		  int image_width = imp.getWidth();
		  int image_height = imp.getHeight();
		  int image_height = imp.getHeight();
		  double scale_h = 1.0 * correctionsParameters.thumb_width/image_width;
		  double scale_h = 1.0 * (correctionsParameters.thumb_width + 1)/image_width;
		  double scale_v = 1.0 * correctionsParameters.thumb_height/image_height;
		  double scale_v = 1.0 * (correctionsParameters.thumb_height + 1)/image_height;
//		  double scale = Math.min(scale_h,  scale_v) /correctionsParameters.thumb_size;
		  double scale = ((scale_h > scale_v) ? scale_h : scale_v) / correctionsParameters.thumb_size;
		  double scale = scale_h / correctionsParameters.thumb_size;


//		  ImageProcessor ip = imp.getChannelProcessor();
		  ImageProcessor ip = imp.getProcessor().duplicate();
		  ImageProcessor ip = imp.getProcessor().duplicate();


		  ip.setInterpolationMethod(ImageProcessor.BICUBIC);
		  ip.setInterpolationMethod(ImageProcessor.BICUBIC);
//		  ip.setInterpolationMethod(ImageProcessor.BILINEAR);
		  ip.blurGaussian(2.0);
		  ip.blurGaussian(2.0);
		  ip.scale(scale, scale);
		  ip.scale(scale, scale);
//		  Rectangle rs = new Rectangle(
//				  (int)Math.round(0.5*image_width*(1.0-scale)),
//				  (int)Math.round(0.5*image_height*(1.0-scale)),
//				  (int)Math.round(image_width*scale),
//				  (int)Math.round(image_height*scale));

//		  int scaled_width = rs.width; // ip.getWidth();
//		  int scaled_height = rs.height; // ip.getHeight();
//		  int lm = (int) Math.round ((scaled_width-correctionsParameters.thumb_width)* correctionsParameters.thumb_h_center);
//		  int tm = (int) Math.round ((scaled_height-correctionsParameters.thumb_height)* correctionsParameters.thumb_v_center);
		  int lm = (int) Math.round (((image_width*scale)-correctionsParameters.thumb_width)* correctionsParameters.thumb_h_center + (0.5*image_width*(1.0-scale)));
		  int lm = (int) Math.round (((image_width*scale)-correctionsParameters.thumb_width)* correctionsParameters.thumb_h_center + (0.5*image_width*(1.0-scale)));
		  int tm = (int) Math.round (((image_height*scale)-correctionsParameters.thumb_height)* correctionsParameters.thumb_v_center + (0.5*image_height*(1.0-scale)));
		  int tm = (int) Math.round (((image_height*scale)-correctionsParameters.thumb_height)* correctionsParameters.thumb_v_center + (0.5*image_height*(1.0-scale)));
		  Rectangle r = new Rectangle(lm,tm,correctionsParameters.thumb_width,correctionsParameters.thumb_height);
		  Rectangle r = new Rectangle(lm,tm,correctionsParameters.thumb_width,correctionsParameters.thumb_height);
+2 −257

File changed.

Preview size limit exceeded, changes collapsed.

+1 −249

File changed.

Preview size limit exceeded, changes collapsed.

+1 −1
Original line number Original line Diff line number Diff line
@@ -5377,7 +5377,7 @@ public class TileProcessor {
				clt_parameters.batch_run?-1:1, // -1,                       // debugLevel,                  // final int        debugLevel)
				clt_parameters.batch_run?-1:1, // -1,                       // debugLevel,                  // final int        debugLevel)
				clt_parameters.tileX,
				clt_parameters.tileX,
				clt_parameters.tileY);
				clt_parameters.tileY);
//		showDoubleFloatArrays sdfa_instance = null;
//		showDoubleFloatArrays sdfa_instance = null; - already no state capitol plane
//		if (debugLevel > -1) sdfa_instance = new showDoubleFloatArrays(); // just for debugging?
//		if (debugLevel > -1) sdfa_instance = new showDoubleFloatArrays(); // just for debugging?




Loading