A correlation along a horizontal direction and a correlation along a
vertical direction are calculated with respect to a neighboring region
around an interpolation target pixel by using respective pixel values of
R pixels, G pixels, and B pixels in Bayer data. The pixel value of the G
pixel to be interpolated for the interpolation target pixel is determined
based upon pixel values of pixels adjacent to the interpolation target
pixel along a direction exhibiting a stronger correlation between the
calculated correlations. The interpolation target pixel in the Bayer data
is interpolated by using the G pixel of the pixel value determined.