(String arg)
| 66 | private boolean showMicroProgress = true; |
| 67 | |
| 68 | public void run(String arg) { |
| 69 | imp = IJ.getImage(); |
| 70 | ImageProcessor ip = imp.getProcessor(); |
| 71 | if (ip.isInvertedLut() && !IJ.isMacro()) { |
| 72 | if (!IJ.showMessageWithCancel("3D Project", ZProjector.lutMessage)) |
| 73 | return; |
| 74 | } |
| 75 | if (!showDialog()) |
| 76 | return; |
| 77 | if (sliceInterval>100) { |
| 78 | IJ.error("Z spacing ("+(int)sliceInterval+") is too large."); |
| 79 | return; |
| 80 | } |
| 81 | imp.startTiming(); |
| 82 | isRGB = imp.getType()==ImagePlus.COLOR_RGB; |
| 83 | if (imp.isHyperStack()) { |
| 84 | if (imp.getNSlices()>1) |
| 85 | doHyperstackProjections(imp); |
| 86 | else |
| 87 | IJ.error("Hyperstack Z dimension must be greater than 1"); |
| 88 | return; |
| 89 | } |
| 90 | if (interpolate && sliceInterval>1.0) { |
| 91 | imp = zScale(imp, true); |
| 92 | if (imp==null) return; |
| 93 | sliceInterval = 1.0; |
| 94 | } |
| 95 | if (isRGB) |
| 96 | doRGBProjections(imp); |
| 97 | else { |
| 98 | ImagePlus imp2 = doProjections(imp); |
| 99 | if (imp2!=null) |
| 100 | imp2.show(); |
| 101 | } |
| 102 | } |
| 103 | |
| 104 | private boolean showDialog() { |
| 105 | ImageProcessor ip = imp.getProcessor(); |
nothing calls this directly
no test coverage detected