I need to implement something like this:
- do a per-element max() for two not-equal-sized matrices a, b into a result matrix c [that is: c[i]=max(a[i],b[i])]
- remember if a or b provided the max value (in a second channel of c or in a new matrix d)
- alternative to second point: have channel 2 of a or b copied to channel 2 of c, depending if a or b provided the max value (in channel 1)
Is there a good way to use opencv functionality for this? (NB: I'll implement in java, but I guess my question is language-independent.)