|
From: <kin...@us...> - 2004-02-14 20:07:53
|
Update of /cvsroot/teem/teem/src/nrrd In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19605 Modified Files: arith.c Log Message: fixed a bug in which nrrdArithGamma generated all NaNs if input min and max were equal Index: arith.c =================================================================== RCS file: /cvsroot/teem/teem/src/nrrd/arith.c,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** arith.c 7 Jan 2004 15:34:30 -0000 1.33 --- arith.c 14 Feb 2004 20:01:07 -0000 1.34 *************** *** 74,77 **** --- 74,81 ---- min = range->min; max = range->max; + if (min == max) { + /* this is stupid. We want min < max to avoid making NaNs */ + max += 1; + } lup = nrrdDLookup[nin->type]; ins = nrrdDInsert[nout->type]; |