[Insight-users] Re: subtract two binary images
Luis Ibanez
luis.ibanez at kitware.com
Fri Apr 20 14:59:55 EDT 2007
Hi Alireza,
What is your definition of subtraction in binary ?
If you actually do binary arithmetic on every pixel,
then that should be:
0 - 0 = 0
1 - 0 = 1
0 - 1 = 1 (Note this one!!)
1 - 1 = 0
Which is equivalent to an Exclusive Or (XOR) operation.
If this is the operation you want,
then you can use the filter:
itkXorImageFilter.h
Regards,
Luis
---------------------------
Alireza Salamy wrote:
> Hi Luis,
> May I ask you how can we subtract two binary images in ITK?
> Thanks,
> Alireza
>
More information about the Insight-users
mailing list