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

Method scaleXWithOverflow

ij/src/main/java/ij/gui/Plot.java:2018–2024  ·  view source on GitHub ↗

Converts calibrated coordinates to pixel coordinates. In contrast to the image calibration, also works with log axes and inverted x axes. Returns a large number instead NaN for log x axis and zero or negative x

(double x)

Source from the content-addressed store, hash-verified

2016 /** Converts calibrated coordinates to pixel coordinates. In contrast to the image calibration, also
2017 * works with log axes and inverted x axes. Returns a large number instead NaN for log x axis and zero or negative x */
2018 @AstroImageJ(reason = "Access widen for Vector Plot saving", modified = true)
2019 public int scaleXWithOverflow(double x) {
2020 if (!logXAxis || x>0)
2021 return scaleX(x);
2022 else
2023 return xScale > 0 ? -1000000 : 1000000;
2024 }
2025
2026 /** Converts calibrated coordinates to pixel coordinates. In contrast to the image calibration, also
2027 * works with log axes and inverted x axes. Returns a large number instead NaN for log y axis and zero or negative y */

Callers 1

Calls 1

scaleXMethod · 0.95

Tested by

no test coverage detected