[vtkusers] Integer overflow in vtkImageAccumulate
g.bogle at auckland.ac.nz
Tue Oct 7 03:30:38 EDT 2014
I encountered a problem in 3DSlicer with the auto calculation of window/level. This may be a well-known issue. For some big 3D tiffs, the algorithm gives bad w/l values, i.e. < 0. I have tracked this to vtkImageAccumulate() in vtkImageAccumulate.cxx, where the histogram is computed. The problem is that the voxel counts are stored in an int array (outPtr), and it's possible to have more than 2^31 voxels with the same value (e.g. 0). I admit that these are unusual tiffs - they are binary and big - so it's a rather extreme case, but it seems that this is going to bite others as image sizes increase.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the vtkusers