diff options
author | William Joye <wjoye@cfa.harvard.edu> | 2019-05-02 21:45:12 (GMT) |
---|---|---|
committer | William Joye <wjoye@cfa.harvard.edu> | 2019-05-02 21:45:12 (GMT) |
commit | 4795bdae5360f87d9524aa37e3ebc4dad882d4c8 (patch) | |
tree | cf06ae8b38955e419d6db8975907af16b1eae9e1 | |
parent | 516f9116281f0e1cfaa1f45524c09961ef2cba0b (diff) | |
download | blt-4795bdae5360f87d9524aa37e3ebc4dad882d4c8.zip blt-4795bdae5360f87d9524aa37e3ebc4dad882d4c8.tar.gz blt-4795bdae5360f87d9524aa37e3ebc4dad882d4c8.tar.bz2 |
REGION: fixed histogram analysis plot if region off image
-rw-r--r-- | tksao/frame/frblt.C | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tksao/frame/frblt.C b/tksao/frame/frblt.C index 735f72c..4f146ed 100644 --- a/tksao/frame/frblt.C +++ b/tksao/frame/frblt.C @@ -82,6 +82,10 @@ void Base::markerAnalysisHistogram(Marker* pp, double** x, double** y, double* xx = *x; double* yy = *y; + // check if we have any data + if (!isfinite(diff)) + goto end; + if (diff>0) { for (int ii=0; ii<nn; ii++) xx[ii] = (double)ii/last*diff + min; @@ -104,6 +108,7 @@ void Base::markerAnalysisHistogram(Marker* pp, double** x, double** y, } + end: if (marr) delete [] marr; if (mask) |