MCPcopy Create free account
hub / github.com/AstroImageJ/astroimagej / getSum

Method getSum

ij/src/main/java/ij/plugin/Binner.java:252–261  ·  view source on GitHub ↗
(ImageProcessor ip, int x, int y)

Source from the content-addressed store, hash-verified

250 }
251
252 private float getSum(ImageProcessor ip, int x, int y) {
253 float sum = 0;
254 for (int y2=0; y2<yshrink; y2++) {
255 for (int x2=0; x2<xshrink; x2++)
256 sum += ip.getf(x*xshrink+x2, y*yshrink+y2);
257 }
258 if (maxValue>0f && sum>maxValue)
259 sum = maxValue;
260 return sum;
261 }
262
263 private boolean showDialog(ImagePlus imp) {
264 boolean stack = imp.getStackSize()>1;

Callers 1

shrinkMethod · 0.95

Calls 1

getfMethod · 0.45

Tested by

no test coverage detected