A adaptive filter interpolation method and system for the demosaicing of color images. In general, input pixels are input in a Bayer-mosaiced pattern (only one color per pixel), and output pixels are in full RGB mode (three color values per pixel). For each pixel location, in raster scan order, the processing steps can be summarized as follows. Following a regular raster scanning order (from left to right and top to bottom), for each pixel location horizontal and vertical gradients are first computed (whose computation depends on the available color for that pixel), and from those the appropriate interpolation filters are chosen from a small set of predetermined filters. Then, the chosen filters are applied to interpolate the missing data.