Abstract:
An imaging device includes an imagine lens, an imaging sensor having a color filter array with color filters of a plurality of colors having a plurality of pixels which are arranged on a light-receiving surface, a computing section obtaining a pixel value of an objective pixel by adding pixel values of a plurality of adjacent pixels which are adjacent to the objective pixel and which have one of the color filters of same color as the objective pixel among pixel values output from the imaging sensor, and a control section making the computing section compute, while shifting the objective pixel one by one in one direction, a pixel row formed of pixel values of the objective pixel in the one direction with respect to each predetermined pixel width in other direction, and generating an image thinned out at the predetermined pixel width in the other direction.

Description:
CROSS-REFERENCE TO RELATED APPLICATION 
       [0001]    This application is based upon and claims the benefit of priority from Japanese Patent Application No. 2009-021571, filed on Feb. 2, 2009, the entire contents of which are incorporated herein by reference. 
       BACKGROUND 
       [0002]    1. Field 
         [0003]    The present application relates to an imaging device capable of reducing a color moire in a captured image. 
         [0004]    2. Description of the Related Art 
         [0005]    In recent years, in accordance with an improvement in performance of an imaging sensor such as a CCD and a CMOS, a digital camera, a digital video camera and the like capable of changing a gain setting of imaging sensitivity and capable of easily capturing an image with high sensitivity have been becoming popular. However, when capturing a still image of night scene in which a shutter speed becomes slow due to a lack of light amount, when capturing a moving image at a high frame rate and the like, addition processing and the like are performed on pixel values of an imaging sensor. A technical development has been under way for realizing an improvement in sensitivity and image quality by reducing a moire, a noise and the like generated at the time of processing (for example, Japanese Unexamined Patent Application Publication No. 2003-46876). 
         [0006]    However, the method of addition processing for the pixel values of the imaging sensor such as the one in the prior art has a problem such that, since color filters of respective colors of R (red), Gr (Gb) (green), and B (blue) provided in respective pixels of the imaging sensor are arranged in a Bayer array being a non-uniform array, even if a high component of spatial frequency equal to or greater than a Nyquist frequency which causes an image deterioration is removed by an optical low-pass filter, a threshold value of the Nyquist frequency is lowered by the addition of the pixel values as described above, which results in generating an image deterioration due to a color moire among the moires. 
       SUMMARY 
       [0007]    In view of the aforementioned problems in the prior art, a proposition of the present embodiments is to provide a technique capable of performing addition processing for pixel values of an imaging sensor in which a color moire is hardly generated. 
         [0008]    To solve the aforementioned problems, an imaging device of the present embodiments includes an imaging lens, an imaging sensor having a color filter array in which color filters of a plurality of colors are disposed in a predetermined pattern and having a plurality of pixels which are two-dimensionally arranged on a light-receiving surface to correspond to the predetermined pattern, a computing section obtaining a pixel value of an objective pixel by adding pixel values of a plurality of adjacent pixels which are a plurality of pixels adjacent to the objective pixel and which have one of the color filters of same color as the objective pixel among pixel values output from the plurality of pixels of the imaging sensor, and a control section making the computing section compute, while shifting the objective pixel one by one in one direction, a pixel row formed of pixel values of the objective pixel in the one direction with respect to each predetermined pixel width in other direction, and generating an image thinned out at the predetermined pixel width in the other direction. 
         [0009]    Further, the plurality of adjacent pixels may also be a plurality of pixels adjacent to the objective pixel and located on each of lines in the one direction and the other direction or in directions of 45 degrees and 135 degrees with respect to the one direction. 
         [0010]    Further, the control section may make the computing section compute by using pixel values of a plurality of pixels adjacent to the objective pixel as the plurality of adjacent pixels which are located on each of lines in the one direction and the other direction or in directions of 45 degrees and 135 degrees with respect to the one direction in accordance with a position of the objective pixel. 
         [0011]    Further, the computing section may add the pixel values of the plurality of adjacent pixels, compute an average value, and set the average value as the pixel value of the objective pixel. 
         [0012]    Moreover, it is also possible to further include a weighted average section performing weighted average on each pixel row formed of the pixel values of the objective pixel in the one direction of the image being thinned-out for each predetermined number of pixels. 
         [0013]    According to the present embodiments, it is possible to perform addition processing on pixel values of an imaging sensor in which a color moire is hardly generated. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0014]      FIG. 1  is a schematic view showing a structural example of a digital camera  100  according to one embodiment of the present invention. 
           [0015]      FIG. 2  is a view showing a pixel array of a part of a still image captured by the digital camera  100 . 
           [0016]      FIG. 3  is a flow chart showing a procedure of addition processing and weighted average processing in the digital camera  100  according to the one embodiment of the present invention. 
           [0017]      FIG. 4  is a view showing an extraction of pixels on first six horizontal scanning lines out of the pixel array of the part of the still image in  FIG. 2 . 
           [0018]      FIG. 5  is a view showing a pixel array after the addition processing and the weighted average processing are performed on the pixel array of the part of the still image in  FIG. 2 . 
       
    
    
     DETAILED DESCRIPTION OF THE EMBODIMENTS 
     One Embodiment 
       [0019]      FIG. 1  is a structural view of a digital camera  100  according to one embodiment of the present invention. 
         [0020]    The digital camera  100  is formed of an imaging lens  1 , an imaging sensor  2 , an A/D converter  3 , a line memory  4 , a CPU  5 , an image processing section  6 , an operation member  7 , a storage section  8 , a display section  9 , and a card interface (card I/F)  10 . The line memory  4 , the CPU  5 , the image processing section  6 , the operation member  7 , the storage section  8 , the display section  9 , and the card I/F  10  are coupled so as to be capable of transmitting information via a bus  12 . Note that  FIG. 1  shows only an essential part of the digital camera  100 . For example, a timing generator that supplies a timing pulse of shooting instruction to the imaging sensor  2  and the A/D converter  3  in accordance with an instruction from the CPU  5 , and the like are omitted in  FIG. 1 . 
         [0021]    The imaging lens  1  is formed of a plurality of optical lenses, and forms a subject image on a light-receiving surface of the imaging sensor  2 . 
         [0022]    The imaging sensor  2  is a CCD or CMOS semiconductor image sensor or the like in which a plurality of pixels disposed on the light-receiving surface thereof respectively have color filters of either R, Gr (Gb), or B arranged in a Bayer array format. In accordance with the instruction from the CPU  5 , the imaging sensor  2  can capture a subject image with all pixels, or capture a through image for live view and a subject image in a moving image by performing thinning in a horizontal scanning direction or a vertical scanning direction to read out pixel values.  FIG. 2  shows a pixel array of a part of the image captured by the imaging sensor  2  with all pixels. Each cell indicates one pixel. First symbols R, Gr (Gb), and B in the respective cells indicate pixels having the respective color filters. Two-digit numbers following these symbols indicate positions of the pixels. Note that a part of the image in  FIG. 2  corresponds to a part of an upper left corner starting with a pixel R 11 . 
         [0023]    Upon receiving the instruction from the CPU  5 , the imaging sensor  2  operates based on the timing pulse supplied from the timing generator (not shown), and captures a subject image formed by the imaging lens  1  provided in front thereof. Based on the instruction from the CPU  5 , the captured image data is output as an image signal from the imaging sensor  2  and is converted into a digital signal in the A/D converter  3 . The digital image signal is temporarily recorded in the line memory  4 . Here, in the present embodiment, in order to perform addition processing on pixel values output from the imaging sensor  2  as will be described later, the imaging sensor  2  is supposed to receive, from the CPU  5  via the timing generator (not shown), an instruction to output pixel values on a plurality of horizontal scanning lines at a time. Further, the number of the plurality of horizontal scanning lines is set to six, in the present embodiment. Therefore, the line memory  4  in  FIG. 1  is supposed to be formed of six line memories each recording pixel values on each of six horizontal scanning lines. Further, a high speed SRAM or the like can be appropriately selected and used as the line memory  4 . 
         [0024]    The CPU  5  reads a control program stored in the storage section  8 , receives various instructions from users via the operation member  7 , and controls to operate the digital camera  100  based on the instructions. For example, the CPU  5  performs control to give an instruction for capturing a subject image to the imaging sensor  2 , to make the image processing section  6  perform image processing on the captured image data, to record the processed image in the storage section  8  and the card memory  10 , to display the image on the display section  9 , and the like. Further, as described above, in the present embodiment, the CPU  5  gives a control instruction for performing addition processing to improve sensitivity and image quality of the captured image, to the imaging sensor  2 , the line memory  4 , and the image processing section  6 . A commonly used computer&#39;s CPU can be used as the CPU  5 . 
         [0025]    The image processing section  6  is a digital front end circuit that performs image processing such as interpolation processing, edge enhancement processing, and white balance correction on the captured still image, moving image or through image to generate a still image file in JPEG format, YUV format or the like, and a moving image file in MPEG format or the like, and performs addition processing and weighted average processing on the still image based on a setting made by a user, to thereby improve the sensitivity and the image quality. 
         [0026]    The operation member  7  outputs, to the CPU  5 , an operation signal in accordance with the contents of operation of the member made by the user. The operation member  7  includes an operation member such as, for instance, a power button, a mode setting button for setting a shooting mode and the like, and a release button. Note that the operation member  7  may also be a touch panel type button displayed on a screen of later-described display section  9 . 
         [0027]    The storage section  8  stores image data captured by the digital camera  100 , the control program with which the CPU  5  controls the digital camera  100 , and the like. The program and the data stored in the storage section  8  can be appropriately referred to from the CPU  5  via the bus  12 . A commonly used hard disk device, a magneto-optic disk device, an arbitrary nonvolatile memory being a semiconductor memory, or the like can be appropriately selected and used as the storage section  8 . 
         [0028]    The display section  9  displays a through image, a shot image, a mode setting screen or the like. A liquid crystal monitor or the like can be appropriately selected and used as the display section  9 . 
         [0029]    The card memory  12  is detachably attached to the card I/F  10 . The captured still image or moving image is image-processed in the image processing section  12  based on the instruction from the CPU  5 , and is recorded in the card memory  8  as a file in JPEG format, MPEG format or the like. 
         [0030]    Next, a procedure of addition processing and weighted average processing in the digital camera  100  according to the present embodiment will be described with reference to a flow chart shown in  FIG. 3 . 
         [0031]    When the power button of the operation member  7  is pressed by a user, the CPU  5  reads the control program stored in the storage section  8  of the digital camera  100 , and initializes the digital camera  100 . Subsequently, processing from step S 10  is carried out. Note that in the present embodiment, it is assumed that the mode is previously set, by the user with the mode setting button of the operation member  7 , to the mode for performing the addition processing and the weighted average processing to improve the sensitivity and the image quality of the captured still image. 
         [0032]    Step S 10 : The CPU  5  determines whether or not the release button of the operation member  7  is pressed by the user and a signal for instructing to capture a subject image is received. When the CPU  5  receives the signal for instructing to capture the subject image made by the user, it makes the imaging sensor  2  capture a still image with all pixels via the timing generator (not shown), and proceeds to step S 11  (YES side). Meanwhile, when the CPU  5  does not receive the signal of capturing instruction (NO side), it waits at step S 10  until it receives the capturing instruction, makes the imaging sensor  2  capture the subject image through thinning-out reading at a predetermined frame rate (30 fps, for instance) for the timing generator (not shown), makes the image processing section  6  perform image processing such as interpolation processing, edge enhancement processing, and white balance correction, and displays the image on the display section  9  as a through image generated for live view. 
         [0033]    Step S 11 : The CPU  5  issues an instruction, to the imaging sensor  2  via the timing generator (not shown), to sequentially output pixel values located on first six horizontal scanning lines Y 1  to Y 6 . The imaging sensor  2  outputs the pixel values on the respective horizontal scanning lines, and the pixel values on the respective horizontal scanning lines are converted from analog to digital signals by the A/D converter  3  to be temporarily recorded in the line memory  4 . 
         [0034]    Step S 12 : The CPU  5  transfers data on the pixel values on the horizontal scanning lines Y 1  to Y 6  recorded in the line memory  4  in step S 11  ( FIG. 4 ) to the image processing section  6  via the bus  12 .  FIG. 4  shows the data on the pixel values on the horizontal scanning lines Y 1  to Y 6  read out in step S 11 . The image processing section  6  performs image processing such as interpolation processing, edge enhancement processing, and white balance correction on the transferred data on the pixel values on the horizontal scanning lines Y 1  to Y 6 . 
         [0035]    Step S 13 : The image processing section  6  performs addition processing on the pixel values on the horizontal scanning lines Y 1  to Y 6  image-processed in step S 12 . Concretely, for instance, when the pixel of R 33  located on the horizontal scanning line Y 3  is set as an objective pixel, the image processing section  6  adds, except the pixel value of R 33 , pixel values of R 13 , R 31 , R 35  and R 53  being pixels located on the horizontal scanning lines Y 1 , Y 3  and Y 5 , adjacent to R 33  and having the color filters R of the same color, and sets the added pixel value as a new pixel value of R 33 . In like manner, the image processing section  6  sequentially performs addition processing as represented by the following equation (1) on all pixel values of pixels such as Gr 34  adjacent to R 33 , located on the horizontal scanning line Y 3  and the horizontal scanning line Y 4 . 
         [0000]        R ′( i,j )= R ( i− 2 ,j )+ R ( i+ 2 ,j )+ R ( i,j− 2)+ R ( i,j+ 2)  (1) 
         [0000]        Gr′ ( i+ 1 ,j )= Gr ( i− 1 ,j )+ Gr ( i+ 3 ,j )+ Gr ( i+ 1 ,j− 2)+ Gr ( i+ 1 ,j+ 2) 
         [0000]        Gb ′( i,j+ 1)= Gb ( i− 2 ,j+ 1)+ Gb ( i+ 2 ,j+ 1)+ Gb ( i,j− 1)+ Gb ( i,j+ 3) 
         [0000]        B ′( i+ 1 ,j+ 1)= B ( i− 1 ,j+ 1)+ B ( i+ 3 ,j+ 1)+ B ( i+ 1 ,j− 1)+ B ( i+ 1 ,j+ 3) 
         [0000]    Here, coordinates of the objective pixel of R are set to (i,j) (i=3, 4, 5, . . . , M−3, j=3, 4, 9, 10, . . . , N−3, N−2 (M and N are integers of six or more)). Further, each of R′, Gr′, Gb′ and B′ indicates the added pixel value. 
         [0036]    As described above, in the present embodiment, the pixel value of the objective pixel itself is obtained by adding, except its own pixel value, the pixel values adjacent to the pixel value at the top, bottom, left and right and having the color filters of the same color, and the original pixel value of the objective pixel itself is used to obtain an added pixel value of another objective pixel adjacent to the pixel and having the color filter of the same color. Accordingly, it is possible to reduce the color moire, which enables to improve the sensitivity and the image quality of the still image. 
         [0037]    Step S 14 : The CPU  5  determines whether the pixel values on all the horizontal scanning lines of the still image captured by the imaging sensor  2  with all pixels are read or not. When the CPU  5  reads the pixel values on all the horizontal scanning lines, it proceeds to step S 15  (YES side). Meanwhile, when the CPU  5  has not read the pixel values on all the horizontal scanning lines yet, it proceeds to step S 11  (NO side), and reads pixel values on the following Y 7  and subsequent lines, for each of six horizontal scanning lines. Further, the CPU  5  performs processing of step S 11  to step S 13 .  FIG. 5  shows an image after the addition processing is finally performed on the pixel values on all the horizontal scanning lines shown in  FIG. 2 . Though this processing, the number of vertical scanning lines is reduced to one-third and the pixel values corresponding to two-pixel width surrounding the original still image (for instance, R 11 , Gr 12 , and the like) are eliminated, as shown in  FIG. 5 . 
         [0038]    Step S 15 : The image processing section  6  performs, since the number of horizontal scanning lines in the still image captured by the imaging sensor  2  is reduced to one-third through the addition processing from step S 11  to step S 14  as shown in  FIG. 5 , a publicly known general method of weighted average on each of three pixels having the color filters of the same color (for instance, R 33 , R 35  and R 37 , and the like) on the respective horizontal scanning lines in order to set a ratio of vertical to horizontal length of the still image to be the same as that of the original still image, and generates a new still image having the same ratio of vertical to horizontal length as that of the original still image. 
         [0039]    Step S 16 : The image processing section  6  records the still image on which the processing in step S 15  is performed, as a file in jPEG format, YUV format or the like in the storage section  8  and the card memory  11  via the bus  12  and the card I/F  10 , and completes a series of operations. 
         [0040]    As described above, in the present embodiment, the pixel value of the objective pixel itself is obtained by adding, except its own pixel value, the pixel values adjacent to the pixel value at the top, bottom, left and right and having the color filters of the same color, and the original pixel value of the objective pixel itself is used to obtain a pixel value of another objective pixel adjacent to the pixel and having the color filter of the same color. Accordingly, it is possible to effectively reduce the color moire, which enables to improve the sensitivity and the image quality of the captured still image. 
         [0041]    Further, the addition processing through the equation (1) in the present embodiment can reduce not only the color moire but also a luminance moire. 
       Another Embodiment 
       [0042]    A digital camera according to another embodiment of the present invention is the same as the digital camera  100  according to the one embodiment. Therefore, the same digital camera  100  as that in the one embodiment shown in  FIG. 1  is used as a digital camera in the present embodiment, and a detailed explanation on the respective components will be omitted. 
         [0043]    Further, the procedure of the addition processing and the weighted average processing in the digital camera  100  according to the present embodiment is also basically the same as that from step S 10  to step S 16  in the flow chart shown in  FIG. 3 . However, the digital camera  100  in the present embodiment differs from the digital camera  100  in the one embodiment in how to perform the addition processing in step S 13 . 
         [0044]    Concretely, in step S 13  in the present embodiment, the image processing section  6  first performs the addition processing on the data on the pixel values on the horizontal scanning lines Y 1  to Y 6  shown in  FIG. 4 , in the same manner as in the one embodiment. At this time, if each pixel of R 33 , Gr 34 , Gb 43  and B 44  located on the horizontal scanning line Y 3  and the horizontal scanning line Y 4  (hereinafter, one combination of R, Gr, Gb and B is set as a Bayer block) is set as an objective pixel, for instance, the CPU  5  obtains an added pixel value of each pixel by using the equation (1), similar to the one embodiment. 
         [0045]    Next, if each pixel in a Bayer block of R 35 , Gr 36 , Gb 45  and B 46  located on the horizontal scanning line Y 3  and the horizontal scanning line Y 4  and adjacent to the Bayer block of R 33 , Gr 34 , Gb 43  and B 44  is set as an objective pixel, there is performed addition processing as represented by the following equation (2) by using pixel values located on straight lines with angle of diagonally 45 degrees and 135 degrees with respect to the horizontal scanning lines, adjacent to the respective objective pixels and having the color filters of the same color. 
         [0000]        R ′( i,j )= R ( i− 2 ,j− 2)+ R ( i+ 2 ,j− 2)+ R ( i− 2 ,j+ 2)+ R ( i+ 2 ,j+ 2)  (2) 
         [0000]        Gr ′( i+ 1 ,j )= Gr ( i− 1 ,j− 2)+ Gr ( i+ 3 ,j− 2)+ Gr ( i− 1 ,j+ 2)+ Gr ( i+ 3 ,j+ 2) 
         [0000]        Gb ′( i,j+ 1)= Gb ( i− 2 ,j− 1)+ Gb ( i+ 2 ,j− 1)+ Gb ( i− 2 ,j+ 3)+ Gb ( i+ 2 ,j+ 3) 
         [0000]        B ′( i+ 1 ,j+ 1)= B ( i− 1 ,j− 1)+ B ( i+ 3 ,j− 1)+ B ( i− 1 ,j+ 3)+ B ( i+ 3 ,j+ 3) 
         [0000]    Note that coordinates of the objective pixel are set to (i, j). 
         [0046]    Specifically, in the present embodiment, the addition processing through the equation (1) and the addition processing through the equation (2) are alternately performed, in a manner such that the addition processing represented by the equation (1) is performed on a certain Bayer block, and the addition processing represented by the equation (2) is performed on the following Bayer block adjacent to the certain Bayer block. Further, in the present embodiment, the addition processing through the equation (1) and the equation (2) are performed on the following horizontal scanning line Y 9  and the horizontal scanning line Y 10  in the opposite order to that of the processing on the horizontal scanning line X 3  and the horizontal scanning line Y 4 , namely, the processing are alternately performed in a manner such that the addition processing through the equation (1) is performed after performing the addition processing through the equation (2). 
         [0047]    As above, in the present embodiment, the addition processing through the equation (1) or the equation (2) is alternately performed to obtain added pixel values in each Bayer block on the horizontal scanning lines. Accordingly, even when an objective pixel has the color filter of the same color as that of the adjacent pixel, pixel values of different combination of adjacent pixels are used, so that the color moire can be more effectively reduced, and it becomes possible to improve the sensitivity and the image quality of the captured still image. 
         [0048]    Further, the addition processing in the present embodiment in which the equation (1) and the equation (2) are combined enables to more effectively reduce not only the color moire but also the luminance moire. 
       Supplementary Items to the Embodiments 
       [0049]    In the one embodiment and the other embodiment, although the pixel values are output for each of six horizontal scanning lines out of all the pixel values of the imaging sensor  2  in step S 11 , the present invention is not limited to this. For example, it is also possible that the pixel values are output for each of, not six, but a plurality of number of horizontal scanning lines. Note that in this case, there is a need to adjust the number of line memories  4  in accordance with the number of horizontal scanning lines from which the pixel values are output. 
         [0050]    Note that in the one embodiment and the other embodiment, the line memory  4  and the image processing section  6  in the digital camera  100  are formed as independent components, but, the present invention is not limited to this, and it is also possible to form a digital front end circuit in which the line memory  4  and the image processing section  6  are formed as one component, and step S 11  to step S 15  are performed through pipeline processing. This enables to realize higher-speed image processing and downsizing of the circuit scale. 
         [0051]    Further, for instance, when the digital camera  100  captures an image by being rotated, from its normal position (a state where an optical axis of the imaging lens  1  is set horizontally and a lower surface of the digital camera  100  is positioned downward, which is, so-called horizontal shooting), by 90 degrees or 270 degrees around the optical axis of the imaging lens  1  (so-called vertical shooting) and the like, it is also possible to read pixel values for each of a plurality of vertical scanning lines and perform the addition processing and the weighted average processing from step S 11  to step S 15 . However, the equation (1) and the equation (2) are deformed as the following equation (3) and the following equation (4). 
         [0000]        R ′( i,j )= R ( i,j− 2)+ R ( i,j+ 2)+ R ( i− 2, j )+ R ( i+ 2, j )  (3) 
         [0000]        Gr′ ( i+ 1 ,j )= Gr ( i− 1 ,j− 2)+ Gr ( i+ 1, j− 2)+ Gr ( i− 1 ,j )+ Gr ( i+ 3 ,j ) 
         [0000]        Gb ′( i,j+ 1)= Gb ( i,j− 1)+ Gb ( i,j+ 3)+ Gb ( i− 2 ,j+ 1)+ Gb ( i+ 2, j+ 1) 
         [0000]        B ′( i+ 1, j+ 1)= B ( i+ 1 ,j− 1)+ B ( i+ 1 ,j+ 3)+ B ( i− 1 ,j+ 1)+ B ( i+ 3 ,j+ 1) 
         [0000]        R ′( i,j )= R ( i− 2, j− 2)+ R ( i− 2 ,j+ 2)+ R ( i+ 2, j− 2)+ R ( i+ 2, j+ 2)  (4) 
         [0000]        Gr′ ( i+ 1 ,j )= Gr ( i− 1, j− 2)+ Gr ( i− 1, j+ 2)+ Gr ( i+ 3, j− 2)+ Gr ( i+ 3 ,j+ 2) 
         [0000]        Gb ′( i,j+ 1)= Gb ( i− 2 ,j− 1)+ Gb ( i− 2 ,j+ 3)+ Gb ( i+ 2 ,j− 1)+ Gb ( i+ 2 ,j+ 3) 
         [0000]        B′ ( i+ 1 ,j+ 1)= B ( i− 1, j− 1)+ B ( i− 1, j+ 3)+ B ( i+ 3 ,j− 2)+ B ( i+ 3 ,j+ 3) 
         [0000]    Here, coordinates of the objective pixel are set to (i, j), in which i is 3, 4, 9, 10, . . . , M−3, M−2, and j is 3, 4, 5, 6, . . . , N−3 (M and N are integers of six or more). 
         [0052]    Note that in the one embodiment and the other embodiment, the pixel value of the objective pixel is obtained through the addition processing using the equation (1) and the equation (2) in step S 13 , but, the present invention is not limited to this. For instance, it is also possible to average the added pixel value of the objective pixel, and to set the average value as the pixel value of the objective pixel. By using the average value as the pixel value of the objective pixel as above, it is possible to achieve an effect of improving an S/N ratio of the still image processed in the weighted average processing in step S 15  in which the size of the image is changed. 
         [0053]    Note that in the one embodiment and the other embodiment, the weighted average processing is performed in step S 15  to set the ratio of vertical to horizontal length of the image on which the addition processing is performed to be the same as that of the captured original still image, but, the present invention is not limited to this. For example, it is also possible that the weighted average processing by the image processing section  6  is not performed, and the image processing section  6  directly records raw data of the image on which only the addition processing is performed in the storage section  8  and the card memory  11 . Further, according to need, the CPU  5  may make the image processing section  6  read the raw data and perform the weighted average processing, to thereby generate a still image having the same ratio of vertical to horizontal length as that of the original still image. 
         [0054]    Note that in the one embodiment, although the color moire of the captured still image is reduced by the addition processing through the equation (1), the present invention is not limited to this, and it is also possible to reduce the color moire using the addition processing through the equation (2), for instance. 
         [0055]    Note that in the other embodiment, although the color moire of the captured still image is reduced by changing the order of addition processing through the equation (1) and the equation (2) depending on the horizontal scanning lines, the present invention is not limited to this, and it is also possible to reduce the color moire using the addition processing through the equation (1) and the equation (2) which are performed on all the horizontal scanning lines in the same order. 
         [0056]    The many features and advantages of the embodiments are apparent from the detailed specification and, thus, it is intended by the appended claims to cover all such features and advantages of the embodiments that fall within the true spirit and scope thereof. Further, since numerous modifications and changes will readily occur to those skilled in the art, it is not desired to limit the inventive embodiments to the exact construction and operation illustrated and described, and accordingly all suitable modifications and equivalents may be resorted to, falling within the scope thereof.