Added parts of my developments to the vigra Computer Vision library...

Finally I managed to integrate the first few things, which I developed for my PhD thesis:

1. A local (window based) filter function environment. 
    applywindowfunction.hxx, medianfilter.hxx, specklefilters.hxx
It can be used to apply any given filter function on a complete image. Like convolveImage, this environment also supports correct border handling at the image boundaries. To demonstrate the use, I added a generic median filter and some of the most commonly used filters for speckle removal as well. 

2. A Coherence Enhancing Shock Filter
    shockfilter.hxx
This one was proposed by J. Weickert 2002 in "Coherence-Enhancing Shock Filters". It uses the Structure Tensor, a map and a weighted erosions/dilation function which perfoms "discrete upwinding" according to signums of the computed map. The results are images, that look like from Munch or van Gogh.

3. A correlation environment
    correlation.hxx
This one provides traditional correlation approaches using sliding windows as well as FFT powered fast versions of the cross-correlation as well as the normalized cross-correlation according to J.P. Lewis 1995: "Fast normalized cross correlation".

All of the included components are tested - tests are supplied by means of vigra tests (test/filters and test/correlation). And they are all documented by means of doxygen comments. All callable algorithms provide the new MultiArrayView calling mechanisms as well as the good old image iterators.
To leave the algorithmic design as it was created by Lewis (in the mentioned paper), we should not try to add complexity for the sake of genericity here. In gernal, of course, this should be the aim of choice. 
Another pro for the current approach is, that the mask is (for many application >> logN. For example, for images of sizes of 4096x2048 pixels we often use mask sizes of 61x61 pixels or more.
I checked the lost of precision for the sum_table2 in some exmaples and ended up with differences of the order 10^-5 for the correlation coefficient for typical matching tasks.