Patent ID: 7305141

Claim:
A contour filter for providing contour information from an array of pixel values representing an image, said array comprises a first and a second group of pixels, the first group of pixels representing part(s) of the image optically filtered with a filter having a first color, and the second group of pixels representing part(s) of the image optically filtered with one or more filters having one or more second colors each pixel in the first group having a vertical and a horizontal neighboring pixel of the second group, said contour filter comprising: means for converting said array of pixel values to a zero switched array, where the pixel values of the pixels in the second group are replaced by zero, means for contour filtering said zero switched array and outputting said contour information, wherein the contour filtering means comprises: means for calculating, for each pixel in the zero switched array, a filtered pixel value, said calculation being performed by using an array of filter coefficients having mutual ratios being substantially defined by: −0 ± A −1x ± B −2x ± C −1x ± D −0 ± E −1x ± F −0 ± G +2x ± H −0 ± I −1x ± J −2x ± K +2x ± L +8x ± M +2x ± N −2x ± O −1x ± P −0 ± Q +2x ± R −0 ± S −1x ± T −0 ± U −1x ± V −2x ± X −1x ± Y −0 ± Z where x is a real number and the value of each of A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, X, Y, Z is between 0 and 0.25x, and means for multiplying the pixel value of the actual pixel with the 8x±M coefficient and the remaining filtering coefficients with correspondingly positioned pixel values in the zero switched array and finally summing the resulting values.