Ask Your Question

Revision history [back]

Preventing information loss on image subtraction

I have two images that I am subtracting from one another quite simply:

Mat foo, a, b;
...//imread onto a and b or somesuch
foo = a - b;

Now, as I understand it, any pixel value that goes into the negatives will end up being zero. If that is so, I'd like to know if there is any way to permit it to go under zero so that I may adjust the image later without loss of information.