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

Method getPixelSize

ij/src/main/java/ij/macro/Functions.java:2185–2199  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2183 }
2184
2185 void getPixelSize() {
2186 Variable unit = getFirstVariable();
2187 Variable width = getNextVariable();
2188 Variable height = getNextVariable();
2189 Variable depth = null;
2190 if (interp.nextToken()==',')
2191 depth = getNextVariable();
2192 interp.getRightParen();
2193 Calibration cal = getImage().getCalibration();
2194 unit.setString(cal.getUnits());
2195 width.setValue(cal.pixelWidth);
2196 height.setValue(cal.pixelHeight);
2197 if (depth!=null)
2198 depth.setValue(cal.pixelDepth);
2199 }
2200
2201 void makeSelection() {
2202 String type = null;

Callers 1

doFunctionMethod · 0.95

Calls 9

getFirstVariableMethod · 0.95
getNextVariableMethod · 0.95
getImageMethod · 0.95
setStringMethod · 0.95
getUnitsMethod · 0.95
setValueMethod · 0.95
getRightParenMethod · 0.80
getCalibrationMethod · 0.80
nextTokenMethod · 0.45

Tested by

no test coverage detected