()
| 2035 | |
| 2036 | /* Hack needed to make the HyperStackReducer work. */ |
| 2037 | public void resetStack() { |
| 2038 | if (currentSlice==1 && stack!=null && stack.size()>0) { |
| 2039 | ColorModel cm = ip.getColorModel(); |
| 2040 | double min = ip.getMin(); |
| 2041 | double max = ip.getMax(); |
| 2042 | ImageProcessor ip2 = stack.getProcessor(1); |
| 2043 | if (ip2!=null) { |
| 2044 | ip = ip2; |
| 2045 | ip.setColorModel(cm); |
| 2046 | ip.setMinAndMax(min, max); |
| 2047 | } |
| 2048 | } |
| 2049 | } |
| 2050 | |
| 2051 | /** Set the current hyperstack position based on the stack index 'n' (one-based). */ |
| 2052 | public void setPosition(int n) { |
no test coverage detected