Abstract:
A digital image acquisition system having no photographic film comprises an apparatus for capturing digital images and a flash unit for providing illumination during image capture. The system has a portrait mode for generating an image of a foreground object against a blurred background, the portrait mode being operable to capture first, second and third images (A, B and C) of nominally the same scene. One of the first and second images (A, B) is taken with flash and the other is taken without flash, and the third image (C) is blurred compared to the first and second images. The portrait mode is further operable to determine foreground and background regions of the scene using the first and second images (A, B), and to substitute the blurred background of the third image (C) for the background of an in-focus image of the scene. In one embodiment the in-focus image is one of the first and second images. In another embodiment the in-focus image is a fourth image.

Description:
PRIORITY AND CROSS-REFERENCE TO RELATED APPLICATIONS 
     This application is a Continuation of U. S. patent application Ser. No. 11/319,766, filed Dec. 27, 2005, now U.S. Pat. No. 7,692,696, and this application is related to U.S. pat. application Ser. No. 12/140,827, filed Jun. 17, 2008, and PCT application no. PCT/EP2006/007573, filed Jul. 31, 2006, each of which are all hereby incorporated by reference. 
    
    
     BACKGROUND OF THE INVENTION 
     1. Field of the Invention 
     This invention relates to a digital image acquisition system having a portrait mode for generating an image of a foreground object against a blurred background, and a corresponding method. 
     2. Description of the Related Art 
     In digital cameras the depth of field (DOF) is typically much greater than for conventional cameras due to the image sensor being somewhat smaller than a 35 mm film negative. This means that portrait images, in particular, will tend to have the background in sharp focus, which may not be desirable as the photographer may wish to emphasize the person&#39;s face and de-emphasize the background of the picture. This problem can be corrected by careful photography combined with careful use of camera settings. Alternatively, portrait images are often blurred manually by professional photographers using image processing algorithms. A blurring algorithm may apply various techniques using convolution kernels to create the blurring effects. These effects are normally added on a desktop computer after an image has been captured. This may involve manual intervention and be time-consuming. 
     US 2003/0052991 discloses to adjust image brightness based on depths of different image features. A digital camera simulates the use of fill flash. The camera takes a series of photographs of a scene at various focus distances. The photographs are stored, along with their corresponding focus distances. The photographs are analyzed to determine distances to objects at various locations of the scene. Regions of a final photograph are selectively adjusted in brightness based on distance information to simulate the effect that would have resulted had fill flash been used. 
     SUMMARY OF THE INVENTION 
     There is provided a digital image acquisition system having no photographic film. The system includes an apparatus for capturing digital images and a flash unit for providing illumination during image capture. The system has a portrait mode for generating an image of a foreground object against a blurred background. The portrait mode is operable to capture first, second and third images of nominally the same scene, not necessarily in the order stated. One of the first and second images is taken with flash and the other is taken without flash. The third image is blurred compared to the first and second images. The portrait mode is operable to determine foreground and background regions of the scene using the first and second images, and to substitute the blurred background of the third image for the background of a substantially in-focus image of the scene. 
     There is further provided a method of generating a digital image of a foreground object against a blurred background. The method includes capturing first, second and third images of nominally the same scene, not necessarily in the order stated. One of the first and second images is taken with flash and the other is taken without flash. The third image is blurred compared to the first and second images. Foreground and background regions of the scene are determined using the first and second images. The blurred background of the third image is substituted for the background of a substantially in-focus image of the scene. 
     In one embodiment, the substantially in-focus image is one of the first and second images. 
     In a second embodiment, the substantially in-focus image is a fourth image. 
    
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
       Embodiments will now be described, by way of example, with reference to the accompanying drawings, in which: 
         FIG. 1  is a block diagram of a camera apparatus operating in accordance with one embodiment. 
         FIG. 2  shows a workflow of a portrait mode processing according to another embodiment. 
         FIG. 3  shows the workflow of the portrait mode processing according to another embodiment. 
     
    
    
     DETAILED DESCRIPTION OF PREFERRED EMBODIMENTS 
       FIG. 1  shows a block diagram of an image acquisition device  20  operating in accordance with a preferred embodiment. The digital acquisition device  20 , which in the present embodiment is a portable digital camera, includes a processor  120 . It can be appreciated that many of the processes implemented in the digital camera may be implemented in or controlled by software operating in a microprocessor, central processing unit, controller, digital signal processor and/or an application specific integrated circuit, collectively depicted as block  120  labelled “processor”. Generically, all user interface and control of peripheral components such as buttons and display is controlled by a microcontroller  122 . The processor  120 , in response to a user input at  122 , such as half pressing a shutter button (pre-capture mode  32 ), initiates and controls the digital photographic process. Ambient light exposure is monitored using light sensor  40  in order to automatically determine if a flash is to be used. A distance to the subject is determined using a focus component  50  which also focuses the image on image capture component  60 . If a flash is to be used, processor  120  causes the flash  70  to generate a photographic illumination in substantial coincidence with the recording of the image by image capture component  60  upon full depression of the shutter button. The image capture component  60  digitally records the image in color. The image capture component  60  preferably includes a CCD (charge coupled device) or CMOS to facilitate digital recording. The flash  70  may be selectively generated either in response to the light sensor  40  or a manual input  72  from the user of the camera. The high resolution image recorded by image capture component  60  is stored in an image store  80  which may comprise computer memory such a dynamic random access memory or a non-volatile memory. The camera is equipped with a display  100 , such as an LCD, for preview and post-view of images. 
     In the case of preview images which are generated in the pre-capture mode  32  with the shutter button half-pressed, the display  100  can assist the user in composing the image, as well as being used to determine focusing and exposure. Temporary storage  82  is used to store one or more of the preview images and can be part of the image store  80  or a separate component. The preview image is preferably generated by the image capture component  60 . For speed and memory efficiency reasons, preview images preferably have a lower pixel resolution than the main image taken when the shutter button is fully depressed, and are generated by subsampling a raw captured image using software  124  which can be part of the general processor  120  or dedicated hardware or combination thereof. Depending on the settings of this hardware subsystem, the pre-acquisition image processing may satisfy some predetermined test criteria prior to storing a preview image. Such test criteria may be chronological, such as to constantly replace the previous saved preview image with a new captured preview image every 0.5 seconds during the pre-capture mode  32 , until the final high resolution image is captured by full depression of the shutter button. More sophisticated criteria may involve analysis of the preview image content, for example, testing the image for changes, before deciding whether the new preview image should replace a previously saved image. Other criteria may be based on image analysis such as sharpness, or metadata analysis such as an exposure condition, whether a flash is going to happen, and/or a distance to the subject. 
     If test criteria are not met, the camera continues by capturing the next preview image without saving the current one. The process continues until the final high resolution image is acquired and saved by fully depressing the shutter button. 
     Where multiple preview images can be saved, a new preview image will be placed on a chronological First In First Out (FIFO) stack, until the user takes the final picture. The reason for storing multiple preview images is that the last preview image, or any single preview image, may not be the best reference image for comparison with the final high resolution image in, for example, a red-eye correction process or, in a preferred embodiment, portrait mode processing. By storing multiple images, a better reference image can be achieved, and a closer alignment between the preview and the final captured image can be achieved in an alignment stage discussed later. 
     The camera is also able to capture and store in the temporary storage  82  one or more low resolution post-view images when the camera is in portrait mode, as will be described. Post-view images are preferably the same as preview images, except that they occur after the main high resolution image is captured. 
     The camera  20  preferably has a user-selectable portrait mode  30 . Alternatively, camera software may include face detection functionality arranged to detect one or more faces in one or more of a series of preview images being captured and if so to switch to portrait mode. In portrait mode, when the shutter button is depressed the camera is caused to automatically capture and store a series of images at close intervals so that the images are nominally of the same scene. The particular number, resolution and sequence of images, whether flash is used or not, and whether the images are in or out of focus, depends upon the particular embodiment, as will be described. A portrait mode processor  90  analyzes and processes the stored images according to a workflow to be described. The processor  90  can be integral to the camera  20 —indeed, it could be the processor  120  with suitable programming—or part of an external processing device  10  such as a desktop computer. In this embodiment the processor  90  receives a main high resolution image from the image store  80  as well as one or more pre- or post-view images from temporary storage  82 . 
     Where the portrait mode processor  90  is integral to the camera  20 , the final processed image may be displayed on image display  100 , saved on a persistent storage  112  which can be internal or a removable storage such as CF card, SD card or the like, or downloaded to another device, such as a personal computer, server or printer via image output component  110  which can be tethered or wireless. In embodiments where the processor  90  is implemented in an external device  10 , such as a desktop computer, the final processed image may be returned to the camera  20  for storage and display, or stored and displayed externally of the camera. 
       FIG. 2  illustrates the workflow of a first embodiment of portrait mode processing. 
     First, portrait mode is selected at  200 . Now, when the shutter button is fully depressed, the camera automatically captures and stores three digital images. The first image includes a high pixel resolution, in-focus, flash image of the subject of interest (image A) at  202 . This is the main image whose background is to be substituted by a blurred background. The second image includes a low pixel resolution, in-focus, non-flash post-view image (image B), at  204 . The third image includes a low pixel resolution, de-focussed (i.e. deliberately blurred) post-view image (image C) at  206 . 
     These three images are taken in rapid succession so that the scene captured by each image is nominally the same. If desired, image A could be taken non-flash and image B taken with flash. In general, one of them is taken with flash and one without. Normally, in portraiture, the main image A would be the flash image but this will depend on other lighting. Image C can be flash or non-flash, but is preferably flash to provide a good contrast between foreground and background. It is to be understood that when we refer to an image being in-focus or blurred we are speaking in relative terms, since no image is perfectly in focus and especially not all over. Thus, by saying that images A and B are in focus we mean that these images, and especially in the case of image A and its background, are substantially more in focus than image C. 
     At  200  to  206  of  FIG. 2  the just-described preferably take place in the camera  20 . The remaining steps now to be described can take place in the camera  20  or in an external device  10 . 
     Images A and B are aligned at  208 , to compensate for any slight movement in the subject or camera between taking these images. Alignment may be performed globally across entire images or locally using various techniques such as those described in U.S. patent application Ser. No. 11/217,788, filed Aug. 30, 2005, which is assigned to the same assignee as the present application and is hereby incorporated by reference. Then, at  210 , the images A and B are matched in pixel resolution by up-sampling image B and/or down-sampling image A. Next, at  212 , the flash and non-flash images A and B are used to construct a foreground/background (f/b) map, step  212 , which identifies foreground and background regions of the scene captured in the images A, B and C. Processes  208 ,  210  and  212  are preferably as described in the Ser. No. 11/217,788 application, incorporated by reference above. 
     At  214 , the pixel resolution of blurred low resolution image C is matched to that of the original image A (i.e., as it was before any processing at  208  to  212 ) by up-sampling image C. Next, using the f/b map constructed at  212 , the blurred background from image C is used to replace the background in image A. To speed up this process, blocks of memory from the blurred background image C may be written to the corresponding blocks of image A, rather than replacing on a pixel by pixel basis. Finally, at  218 , image processing filters are applied to smooth the transition between the composited foreground and background regions of the composite image resulting from  216 . 
     Variations of the foregoing embodiment are possible. For example, one or both of the images B and C could be pre-view images rather than post-view images. Also, image B and/or image C could be the same resolution as image A. This can serve to avoid matching image resolution at  210  and/or  214 . 
       FIG. 3  illustrates the workflow of a second embodiment of portrait mode processing. Processes which are the same as those in  FIG. 2  are given the same reference numerals. Only the differences in the two workflows are described below. 
     In the embodiment of  FIG. 3 , upon fully depressing the shutter button the camera takes four images of the same nominal scene in rapid succession. Images A and C ( 202  and  206 ) are taken as before, but instead of taking a single image B, two images B1 and B2 are taken, both being low resolution post-view images but one being taken with flash and one without. The two images B1 and B2 are used to construct the f/b map,  208 A and  212 A according to the principles of the Ser. No. 11/217,788 application, incorporated by reference above, leaving a free choice as to whether the image A is taken with flash or not and avoiding matching image resolution at  210  of  FIG. 2 . 
     As before, any one or more of images B1, B2 and C could be a pre-view image, and image C could be the same resolution as image A to avoid matching image resolution at  214 . 
     The present invention is not limited to the embodiments described above herein, which may be amended or modified without departing from the scope of the present invention as set forth in the appended claims, and structural and functional equivalents thereof. 
     In methods that may be performed according to preferred embodiments herein and that may have been described above and/or claimed below, the operations have been described in selected typographical sequences. However, the sequences have been selected and so ordered for typographical convenience and are not intended to imply any particular order for performing the operations. 
     In addition, all references cited above herein, in addition to the background and summary of the invention sections, are hereby incorporated by reference into the detailed description of the preferred embodiments as disclosing alternative embodiments and components.