cleaner edges for Markesteijn demosaic

Make a mirrored/interpolated extra border to give algorithm room to
work. Thank you to Lars Kotthoff for the idea! This version uses more
memory and is slightly slower, but worth it to help the top tier
algorithm do a good job on edges with a lot of detail.