Currently ScalarImageToCooccurrenceMatrixFilter
assumes that the mask image would be the same type as the gray value image. This is not ideal, and can be even problematic when working with floating-point types.
I think its possible to extend ScalarImageToCooccurrenceMatrixFilter
to add a template parameter for the mask image type. But would such a PR be acceptable?