Optimizing high dynamic range (HDR) image processing based on selected regions

Multiple regions of a scene are identified, for example through user inputs to a touchscreen while the touchscreen displays preview frames of the scene. Multiple exposure settings are determined based on the identified regions. Each exposure setting is determined based on one of the identified regions, for instance to optimally expose that region. Multiple image frames are captured of the scene, with each image frame captured at a different one of the determined exposure settings. A high dynamic range (HDR) image of the scene is generated by merging the multiple image frames of the scene.

FIELD

This application is related to image processing. More specifically, this application relates to systems and methods of performing high dynamic range (HDR) image processing by merging multiple image frames of a scene that are each captured at different exposures, with the different exposures based on different regions of the scene.

BACKGROUND

The dynamic range of a digital image device, such as a digital camera, is the ratio between the largest amount of light that the device can capture without saturation, and the lowest amount of light the device can accurately measure and distinguish from intrinsic image noise (electrical, thermal, etc.). Most digital cameras are able to capture only a small portion of the natural illumination range of a real-world scene. The dynamic range of a scene may be, for example, 100,000:1, while the dynamic range of the image sensor of the digital camera may be, for example, 100:1. When the dynamic range of the scene exceeds the dynamic range of the sensor, details in the regions of highest light levels and lowest light levels are lost.

SUMMARY

High dynamic range (HDR) imaging can be improved by allowing a user or computing system to identify important regions in a scene that are prioritized in generating an HDR image of the scene. Image processing techniques and technologies are described herein for identifying regions of a scene that are important, determining exposure settings based on those specific regions, and merging together image frames captured at those exposure settings to generate a HDR image that optimally reproduces all of those regions.

In one example, a method of processing image data is provided. The method includes identifying a first region of a scene and determining a first exposure setting based on the first region of the scene. The method also includes identifying a second region of the scene and determining a second exposure setting based on the second region of the scene. The method also includes receiving a first image frame of the scene that is captured using the first exposure setting and receiving a second image frame of the scene that is captured using the second exposure setting. The method also includes generating a high dynamic range (HDR) image of the scene by merging at least the first image frame and the second image frame.

In another example, an apparatus for processing image data is provided. The apparatus includes a connector that is coupled to an image sensor. The connector receives a first image frame of a scene that is captured using a first exposure setting and receives a second image frame of the scene that is captured using a second exposure setting. The apparatus also includes one or more memory units storing instructions and one or more processors that execute the instructions. Execution of the instructions by the one or more processors causes the one or more processors to perform operations. The operations include identifying a first region of a scene and determining a first exposure setting based on the first region of the scene. The operations also include identifying a second region of the scene and determining a second exposure setting based on the second region of the scene. The operations also include generating a high dynamic range (HDR) image of the scene by merging at least the first image frame and the second image frame.

In another example, a non-transitory computer-readable medium is provided that has stored thereon instructions that, when executed by one or more processors, cause the one or more processors to: identify a first region of a scene; determine a first exposure setting based on the first region of the scene; identify a second region of the scene; determine a second exposure setting based on the second region of the scene; receive a first image frame of the scene that is captured using the first exposure setting; receive a second image frame of the scene that is captured using the second exposure setting; and generate a high dynamic range (HDR) image of the scene by merging at least the first image frame and the second image frame.

In another example, an apparatus for processing image data is provided. The apparatus includes: means for identifying a first region of a scene; means for determining a first exposure setting based on the first region of the scene; means for identifying a second region of the scene; means for determining a second exposure setting based on the second region of the scene; means for receiving a first image frame of the scene that is captured using the first exposure setting; means for receiving a second image frame of the scene that is captured using the second exposure setting; and means for generating a high dynamic range (HDR) image of the scene by merging at least the first image frame and the second image frame.

In some aspects, the methods, apparatuses, and computer-readable medium described above further comprise: receiving one or more touch-based inputs through a touchscreen while the touchscreen displays one or more preview frames of the scene, wherein identifying the first region and the second region is based on the one or more touch-based inputs.

In some aspects, the methods, apparatuses, and computer-readable medium described above further comprise: receiving one or more pointer-based inputs through an input device that controls a pointer on a screen while the screen displays one or more preview frames of the scene, wherein identifying the first region and the second region is based on the one or more pointer-based inputs.

In some aspects, the methods, apparatuses, and computer-readable medium described above further comprise: identifying an object in the scene using an object detection algorithm, wherein identifying the first region of the scene is based on identifying that the object is within the first region. In some examples, the object is a face.

In some aspects, the methods, apparatuses, and computer-readable medium described above further comprise: identifying a third region of the scene; determining a third exposure setting based on a third region of the scene; and receiving a third image frame of the scene captured using the third exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame.

In some aspects, the methods, apparatuses, and computer-readable medium described above further comprise: the first exposure setting corresponds to a first exposure time and the second exposure setting corresponds to a second exposure time that is different from the first exposure time.

In some aspects, a mid-tone of the first region in the scene matches a mid-tone of a representation of the first region in the first image frame within a first threshold. In some cases, a mid-tone of the second region in the scene matches a mid-tone of a representation of the first region in the second image frame within a second threshold.

In some aspects, the first region is reproduced in the second image frame at a second contrast level and in the first image frame at a first contrast level that exceeds the second contrast level.

In some aspects, the second region is reproduced in the first image frame at a first contrast level and in the second image frame at a second contrast level that exceeds the first contrast level.

In some aspects, a third dynamic range of the HDR image is greater than at least one of a first dynamic range of the first image frame and a second dynamic range of the second image frame.

In some aspects, the first region includes all pixels of the first image frame.

In some aspects, the methods, apparatuses, and computer-readable medium described above further comprise: determining a third exposure setting and a fourth exposure setting using exposure bracketing based on the first exposure setting; receiving a third image frame of the scene captured using the third exposure setting; and receiving a fourth image frame of the scene captured using the fourth exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame and the fourth image frame.

In some aspects, the methods, apparatuses, and computer-readable medium described above further comprise: determining a third exposure setting that is offset from the first exposure setting by a predetermined offset; and receiving a third image frame of the scene captured using the third exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame.

In some aspects, the methods, apparatuses, and computer-readable medium described above further comprise: capturing the first image frame of the scene using the first exposure setting; and capturing the second image frame of the scene using the second exposure setting.

In some aspects, the apparatus comprises a camera, a mobile device (e.g., a mobile telephone or so-called “smart phone” or other mobile device), a wearable device, an extended reality device (e.g., a virtual reality (VR) device, an augmented reality (AR) device, or a mixed reality (MR) device), a personal computer, a laptop computer, a server computer, or other device. In some aspects, the apparatus includes a camera or multiple cameras for capturing one or more images. In some aspects, the apparatus further includes a display for displaying one or more images, notifications, and/or other displayable data. In some aspects, the apparatuses described above can include one or more sensors.

DETAILED DESCRIPTION

High-dynamic-range imaging (HDRI) is a high dynamic range (HDR) technique used in imaging and photography. A camera performing HDRI generally captures two or more image frames of the same scene at different exposure settings, and then merges these image frames into a single HDR image. The HDR image generally has a higher dynamic range than any of the image frames that were merged to produce the HDR image.

Low exposures limit the amount of light that reaches the image sensor. Thus, image frames captured at low exposures and are generally able to accurately reproduce details in very bright regions of a scene, such as regions of a scene depicting the sun, a lamp, a screen, or another light source. High exposures, on the other hand, allow more light to reach the image sensor. Image frames captured at high exposures, then, are generally able to accurately reproduce details in very dim regions of a scene, such as regions that are shrouded in shadows. An HDR image that is generated by merging an image frame captured at a low exposure with an image frame captured at a high exposure can accurately reproduce details in both very bright and very dim regions, and thus reproduces a greater dynamic range of luminosity than image frames captured at any single exposure.

Exposure times of the image frames to be merged in the HDRI process may, in some cases, be selected through a process known as exposure bracketing. In exposure bracketing, a “main” exposure is selected and is denoted as exposure value (EV) 0. The “main” exposure may be selected, for instance, based on an auto-exposure (AE) control, which may try incremental adjustments to exposure settings until one is found that produces a representation of the scene in which a mid-tone of the representation of the scene matches a mid-tone of the actual scene as closely as possible (e.g., within a threshold). A predetermined offset EV is selected, such as N stops. A lower exposure is selected that is lower than EV 0 by the offset EV. For example, if the offset is N stops, this lower exposure is denoted as EV −N. A higher exposure is selected that is higher than EV 0 by the offset EV. For example, if the offset is N stops, this higher exposure is denoted as EV+N. The HDR image is generated by merging an image frame captured at EV 0, an image frame captured at EV −N, and an image frame captured at EV+N. Here, N may be any value, such as 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 4.5, 5.0, a number between 0 and 0.5, a number greater than 5.0, or a number in between any two previously listed numbers.

Exposure bracketing has its limitations, however. If region of the scene is poorly exposed all three of the image frames (e.g., EV 0, EV −N, and EV +N), then that region will still be poorly exposed in the resulting HDR image. A user using an image capture and processing device that captures image frames for merging into an HDR image and selects the exposure settings for those image frames through exposure bracketing has no way to ensure that specific regions of a scene that are important to the user, such as faces or regions with written text, are properly exposed in the HDR image.

In some cases, the image frames that are eventually combined to form the HDR image may be captured at exposure settings that are selected based on specific regions of the scene. These regions may be identified by an image capture and processing device based on user inputs (e.g., selecting an object within the region or one or more corners or edges of the region), one or more object recognition algorithms (e.g., automatically recognizing human faces or other important objects within a scene), or some combination thereof. Exposure settings may be generated based on the identified regions of the scene, with the exposure setting that corresponds to each region generated to optimize exposure for that region. For instance, an exposure setting with a long exposure time may be generated to correspond to a region that is dimly lit in order to capture enough light to make details within the dimly lit region clear, while an exposure setting with a short exposure time may be generated to correspond to a region that is brightly lit in order to limit light intake to make details within the brightly lit region clear. An HDR image that is generated by merging image frames that are captured with these exposure settings that correspond to specific regions in the scene includes optimal levels of detail within those regions. In some cases, a combination of region-focused exposure settings and exposure bracketing may be used.

FIG.1is a block diagram illustrating an architecture of an image capture and processing device. The image capture and processing device100ofFIG.1includes various components that the image capture and processing device100uses to capture and process an image of a scene110. A lens115of the device100faces a scene110and receives light from the scene110and bends the light toward the image sensor130. The light received by the lens115passes through an aperture controlled by one or more control mechanisms120and is received by an image sensor130. The one or more control mechanisms120may control exposure, focus, and/or zoom based on information from the image sensor130and/or from the image processor150. The one or more control mechanisms120may include multiple mechanisms and components; for instance, the control mechanisms120may include one or more exposure control mechanisms125A, one or more focus control mechanisms125B, and/or one or more zoom control mechanisms125C.

The focus control mechanism125B of the control mechanisms120stores a focus setting in a memory register, and based on this focus setting, adjusts the position of the lens115relative to the position of the image sensor130, in some cases moving the lens115closer to the image sensor130or farther from the image sensor130by actuating a motor or servo, thereby adjusting focus. In some cases, additional lenses may be included in the device100, such as one or more microlenses over each photodiode of the image sensor130, which each bend the light received from the lens115toward the corresponding photodiode before the light reaches the photodiode. The focus setting may be determined via contrast detection autofocus (CDAF), phase detection autofocus (PDAF), or some combination thereof. The focus setting may be determined using the control mechanism120, the image sensor130, and/or the image processor150.

The exposure control mechanism125A of the control mechanisms120stores an exposure setting in a memory register, and based on this exposure setting, the exposure control mechanism125A controls a size of the aperture (e.g., aperture size or f/stop), a duration of time for which the aperture is open (e.g., exposure time or shutter speed), a sensitivity of the image sensor130(e.g., ISO speed or film speed), analog gain applied by the image sensor130, or some combination thereof. For HDR photography, aperture size is in some cases unchanged, as changes to aperture size may in some cases change depth of field, which could cause certain areas that are clear in one image frame to be blurry in another or vice versa, potentially preventing image frames captured at different aperture sizes from being cleanly merged together into an HDR image in such scenarios. Changes to exposure time, ISO speed, and analog gain generally do not affect depth of field, and therefore may be used more effectively for capturing image frames that are eventually merged generated a HDR image.

The zoom control mechanism125C of the control mechanisms120stores a zoom setting in a memory register. Based on this zoom setting, the zoom control mechanism125C controls a focal length of an assembly of lens elements (lens assembly) that includes the lens115and one or more additional lenses by actuating one or more motors or servos to move one or more of the lenses relative to one another. The lens assembly may include a parfocal zoom lens or a varifocal zoom lens. The lens assembly may include a focusing lens115that receives the light from the scene110first, then an afocal zoom system between the focusing lens115and the image sensor130. The afocal zoom system may, in some cases, include two positive (e.g., converging, convex) lenses of equal or similar focal length (e.g., within a threshold difference) with a negative (e.g., diverging, concave) lens between them. In some cases, the zoom control mechanism125C moves one or more of the lenses in the afocal zoom system, such as the negative lens and one or both of the positive lenses.

The image sensor130includes one or more arrays of photodiodes or other photosensitive elements, each photodiode measuring an amount of light that eventually corresponds to a particular pixel in the image produced by the image sensor130. In some cases, different photodiodes may be covered by different color filters, and may thus measure light matching the color of the filter covering the photodiode. For instance, Bayer color filters include red color filters, blue color filters, and green color filters, with each pixel of the image generated based on red light data from at least one photodiode covered in a red color filter, blue light data from at least one photodiode covered in a blue color filter, and green light data from at least one photodiode covered in a green color filter. Other types of color filters may use yellow, magenta, and/or cyan (also referred to as “emerald”) color filters instead of or in addition to red, blue, and/or green color filters. Some image sensors may lack color filters altogether, and may instead use different photodiodes throughout the pixel array (in some cases vertically stacked), the different photodiodes having different spectral sensitivity curves and therefore responding to different wavelengths of light. Monochrome image sensors may also lack color filters and therefore lack color depth.

In some cases, the image sensor130may alternately or additionally include opaque and/or reflective masks that block light from reaching certain photodiodes, or portions of certain photodiodes, at certain times and/or from certain angles, which may be used for phase detection autofocus (PDAF). The image sensor130may also include an analog gain amplifier to amplify the analog signals output by the photodiodes and/or an analog to digital converter (ADC) to convert the analog signals output of the photodiodes (and/or amplified by the analog gain amplifier) into digital signals. In some cases, certain components or functions discussed with respect to one or more of the control mechanisms120may be included instead or additionally in the image sensor130. The image sensor130may be a charge-coupled device (CCD) sensor, an electron-multiplying CCD (EMCCD) sensor, an active-pixel sensor (APS), a complimentary metal-oxide semiconductor (CMOS), an N-type metal-oxide semiconductor (NMOS), a hybrid CCD/CMOS sensor (e.g., sCMOS), or some other combination thereof.

The image processor150may include one or more processors, such as one or more image signal processors (ISPs), one or more digital signal processors (DSPs), and/or one or more of any other type of processor610discussed with respect to the computing system600. The image processor150may perform a number of tasks, such as de-mosaicing, color space conversion, image frame downsampling, pixel interpolation, automatic exposure (AE) control, automatic gain control (AGC), CDAF, PDAF, automatic white balance, merging of image frames to form an HDR image, image recognition, object recognition, feature recognition, receipt of inputs, managing outputs, managing memory, or some combination thereof. The image processor150may store image frames and/or processed images in random access memory (RAM)140/620, read-only memory (ROM)145/625, a cache612, a memory unit615, another storage device630, or some combination thereof.

Various input/output (I/O) devices160may be connected to the image processor150, such as a display screen, a keyboard, a keypad, a touchscreen, a trackpad, a touch-sensitive surface, any other output devices635, any other input devices645, or some combination thereof. In some cases, regions of a scene may be identified based on inputs received from a user by one or more of the I/O devices160and conveyed to the image processor150. The I/O160may include one or more ports, jacks, or other connectors that enable a wired connection between the device100and one or more peripheral devices, over which the device100may receive data from the one or more peripheral device and/or transmit data to the one or more peripheral devices. The I/O160may include one or more wireless transceivers that enable a wireless connection between the device100and one or more peripheral devices, over which the device100may receive data from the one or more peripheral device and/or transmit data to the one or more peripheral devices.

In some cases, the image capture and processing device100may be a single device. In some cases, the image capture and processing device100may actually be two separate devices—an image capture device105A (e.g., a camera) and an image processing device105B (e.g., a computing device coupled to the camera). The image capture device105A and the image processing device105B may be coupled together, for example via one or more wires or cables, or wirelessly. The image capture device105A and the image processing device105B may be disconnected from one another. A vertical dashed line divides the image capture and processing device100ofFIG.1into two portions, the two portions representing the image capture device105A and the image processing device105B, respectively. The image capture device105A includes the lens115, control mechanisms120, image sensor130, and a portion of the image processor150(including the ISP). The image processing device105B includes a second portion of the image processor150(including the DSP), the RAM140, the ROM145, and the I/O160. In some cases, certain components illustrated in the image capture device105A, such as the ISP, may be included in the image processing device105B. In some cases certain components illustrated in the image processing device105B, such as the DSP, may be included in the image capture device105A.

The image capture and processing device100ofFIG.1may include an electronic device, such as a mobile or stationary telephone handset (e.g., smartphone, cellular telephone, or the like), a desktop computer, a laptop or notebook computer, a tablet computer, a set-top box, a television, a camera, a display device, a digital media player, a video gaming console, a video streaming device, an Internet Protocol (IP) camera, or any other suitable electronic device. In some examples, the image capture and processing device100may include one or more wireless transceivers for wireless communications.

While the image capture and processing device100is shown to include certain components, one of ordinary skill will appreciate that the image capture and processing device100can include more components than those shown inFIG.1. The components of the image capture and processing device100can include software, hardware, or one or more combinations of software and hardware. For example, in some implementations, the components of the image capture and processing device100can include and/or can be implemented using electronic circuits or other electronic hardware, which can include one or more programmable electronic circuits (e.g., microprocessors, graphics processing units (GPUs), digital signal processors (DSPs), central processing units (CPUs), and/or other suitable electronic circuits), and/or can include and/or be implemented using computer software, firmware, or any combination thereof, to perform the various operations described herein. The software and/or firmware can include one or more instructions stored on a computer-readable storage medium and executable by one or more processors of the electronic device implementing the image capture and processing device100.

FIG.2is a flow diagram illustrating operations for image processing to generate a high dynamic range (HDR) image. The image processing operations200ofFIG.2may be performed by the image capture and processing device100or the image processing device105B ofFIG.1. For simplicity, the operations200ofFIG.2will be discussed as being performed by the image processing device105B.

At operation215, the image processing device105B identifies a first region of a scene. At operation220, the image processing device105B identifies a second region of the scene. In some cases, the identification of the first region and second region in operations220may be based on operation205and/or operation210.

At operation205, the image processing device105B receives one or more inputs selecting the first region of the scene and/or the second region of the scene. In one example, the one or more inputs may include touch-based inputs received through a touchscreen of the I/O160of the image processing device105B while the touchscreen displays one or more preview frames of the scene. Preview frames can also be referred to herein as preview images. Alternately or additionally, the one or more inputs may include one or more pointer-based inputs received through an input device of the I/O160of the image processing device105B that controls a pointer on a screen (e.g., a mouse or trackpad or keyboard or keypad) while the screen displays one or more preview frames of the scene.

For instance, a user may touch or click an object to define a region that includes the object. In response to receiving the touch or click on the object from the touchscreen or input device, the image processing device105B can determine the boundaries of the region by identifying the boundaries of the object via edge detection, feature detection, object detection, object recognition, or some combination thereof. In another example, a user may touch or click an intended center of a region, and the image processing device105B can define a region of a pre-defined size around the location of the touch or click input that the image processing device105B receives from the touchscreen or input device. In another example, the user may touch one or more corners or edges of a region to define the area spanned by the region, and the image processing device105B can define a region based on the corners or edges indicated by the touch or click inputs received by the image processing device105B from the touchscreen or input device. In another example, the user may touch or click a corner of a region and swipe or drag to an opposite corner of the region before releasing the touch or click, and the image processing device105B can define the area spanned by the region being a rectangle having the two corners indicated by the touch or pointer inputs received by the image processing device105B from the touchscreen or input device. In another example, the user may touch, click, drag, and/or swipe their finger or pointer into one or more boxes (e.g. squares or oblong rectangles) of a grid overlaid over the scene on the touchscreen, and the image processing device105B can identify a region that includes those boxes of the grid that are indicated by the touch or pointer inputs received by the image processing device105B from the touchscreen or input device. In another example, a user may draw a shape on the touchscreen via touch or on the screen via the pointer, and the image processing device105B can define a region to include the area of the scene within the shape that is drawn using the touch or pointer inputs received by the image processing device105B from the touchscreen or input device. While touch-based inputs and pointer-based inputs are used herein as an illustrative example, any type of input can be used, such as pointer-based input, gesture-based input, voice- or speech-based input, any combination of inputs (e.g., a combination of touch- and voice-based input, etc.), and/or other type of input.

In some cases, the first region and/or the second region may be identified based on identifying an object in the scene via an object detection or object recognition algorithm. If an object is identified by the object detection or object recognition algorithm, a region may be identified by the image processing device105B to include that object as detected by the image processing device105B. In some cases, the object may be a face of a human being or of an animal (e.g., a pet). In some case, the object may be a sign, a document, a screen, a projection surface, or another area that includes text and/or numbers printed, written, displayed, or projected thereon. In some cases, the object may be a vehicle, a computer, or another mechanical and/or electronic device. In some cases, the object may be an animal, a plant, or another natural object. In some cases, the object may be a particularly brightly-lit object or area relative to the rest of the scene (e.g., the average luminance of the object or area having being higher than the average luminance of the scene by a threshold, for instance by a standard deviation or multiple thereof). In such cases, the object can be selected so that the HDR image ultimately represents the brightly-lit object or area optimally due to the image frame corresponding to the region with the object being captured with an optimal exposure setting for that object. In some cases, the object may be a particularly dimly-lit object or area in the scene (e.g., the average luminance of the object or area having being lower than the average luminance of the scene by a threshold, for instance by a standard deviation or multiple thereof). In such cases, the object can be selected so that the HDR image ultimately represents that dimly-lit object or area optimally due to the image frame corresponding to the region with the object being captured with an optimal exposure setting for that object. The object may thus include a particular area of floor, wall, ceiling, a roof, an edge, a corner, a piece of furniture, a window, a door, an area of sky, an area in nature, or some combination thereof. The boundaries of the region may be identified to be the boundaries of the object, or boundaries having a particular pre-determined shape (e.g., square, oblong rectangular, circular, oval) that contains the object, that contains whatever portion of the object is visible in the image frame(s) in question, or that contains a part of the object that includes the highest concentration of edges or other features.

The object detection and/or recognition algorithm applied by the image processing device105B may include and/or incorporate an image detection and/or recognition algorithm, an object detection and/or recognition algorithm, a facial detection and/or recognition algorithm, a feature detection and/or recognition algorithm, an edge detection algorithm, a boundary tracing function, or some combination thereof. Object detection is a technology used to detect (or locate) objects from an image or video frame. Detected objects can be represented using bounding regions that identify the location and/or approximate boundaries of the object (e.g., a face) in the image or video frame. A bounding region of a detected object can include a bounding box, a bounding circle, a bounding ellipse, a bounding polygon, or any other suitably-shaped region representing and/or including a detected object. Object detection and/or recognition can be used to identify a detected object and/or to recognize and classify the detected object into a category or type of object. For instance, feature recognition may identify a number of edges and corners in an area of the scene. Object detection may detect that the detected edges and corners in the area all belong to a single object. Object detection and/or object recognition and/or face detection may identify that the object is a human face. Object recognition and/or face recognition may further identify the identity of the person corresponding to that face.

The object detection and/or recognition algorithm can be performed using any suitable object recognition and/or detection technique. In some implementations, the object detection and/or recognition algorithm can be based on a machine learning model trained using a machine learning algorithm on images of the same types of objects and/or features that may extract features of the image and detect and/or classify the object comprising those features based on the training of the model by the algorithm. For instance, the machine learning algorithm may be a neural network (NN), such as a convolutional neural network (CNN), a time delay neural network (TDNN), a deep feed forward neural network (DFFNN), a recurrent neural network (RNN), an auto encoder (AE), a variation AE (VAE), a denoising AE (DAE), a sparse AE (SAE), a markov chain (MC), a perceptron, or some combination thereof. The machine learning algorithm may be a supervised learning algorithm, a deep learning algorithm, or some combination thereof.

In some implementations, a computer vision-based object detection and/or recognition technique can be used. Different types of computer vision-based object detection algorithms can be used. In one illustrative example, a template matching-based technique can be used to detect one or more hands in an image. Various types of template matching algorithms can be used. One example of a template matching algorithm can perform Haar or Haar-like feature extraction, integral image generation, Adaboost training, and cascaded classifiers. Such an object detection technique performs detection by applying a sliding window (e.g., having a rectangular, circular, triangular, or other shape) across an image. An integral image may be computed to be an image representation evaluating particular regional features, for example rectangular or circular features, from an image. For each current window, the Haar features of the current window can be computed from the integral image noted above, which can be computed before computing the Haar features.

The Harr features can be computed by calculating sums of image pixels within particular feature regions of the object image, such as those of the integral image. In faces, for example, a region with an eye is typically darker than a region with a nose bridge or cheeks. The Haar features can be selected by a learning algorithm (e.g., an Adaboost learning algorithm) that selects the best features and/or trains classifiers that use them, and can be used to classify a window as a face (or other object) window or a non-face window effectively with a cascaded classifier. A cascaded classifier includes multiple classifiers combined in a cascade, which allows background regions of the image to be quickly discarded while performing more computation on object-like regions. Using a face as an example of a body part of an external observer, the cascaded classifier can classify a current window into a face category or a non-face category. If one classifier classifies a window as a non-face category, the window is discarded. Otherwise, if one classifier classifies a window as a face category, a next classifier in the cascaded arrangement will be used to test again. Until all the classifiers determine the current window is a face (or other object), the window will be labeled as a candidate for being a hand (or other object). After all the windows are detected, a non-max suppression algorithm can be used to group the windows around each face to generate the final result of one or more detected faces.

At operation225, the image processing device105B determines a first exposure setting based on the first region of the scene. At operation230, the image processing device105B determines a second exposure setting based on the second region of the scene. At operation235, the image processing device105B receives a first image frame of the scene captured using the first exposure setting. Operation235may, in some cases, also include the image capture device105A capturing the first image frame of the scene using the first exposure setting. At operation240, the image processing device105B captures a second image frame of the scene using the second exposure setting. Operation240may, in some cases, also include the image capture device105A capturing the second image frame of the scene using the second exposure setting.

In some cases, the first exposure setting corresponds to a first exposure time and the second exposure setting corresponds to a second exposure time that is different from the first exposure time. In some cases, the first region is optimally exposed in the first image frame, and the second region is optimally exposed in the second image frame. In some cases, a mid-tone of the first region in the scene matches a mid-tone of a representation of the first region in the first image frame within a first threshold, and a mid-tone of the second region in the scene matches a mid-tone of a representation of the first region in the second image frame within a second threshold.

In some cases, the first region is reproduced in the second image frame at a second contrast level and in the first image frame at a first contrast level that exceeds the second contrast level. In some cases, the second region is reproduced in the first image frame at a first contrast level and in the second image frame at a second contrast level that exceeds the first contrast level.

At operation250, the image processing device105B generates a high dynamic range (HDR) image of the scene by merging at least the first image frame and the second image frame. In some cases, the dynamic range of the HDR image is greater than a first dynamic range of the first image frame and/or than a second dynamic range of the second image frame.

Generating the HDR image based on identified regions as in the operations200allows the image processing device105B to ensure that the identified regions are optimally and clearly reproduced in the HDR image, based on each of those regions being optimally exposed in at least one of the image frames that are ultimately merged together to generate the HDR image. On the other hand, important regions of an HDR image that is generated based on exposure bracketing can still appear overexposed, underexposed, or otherwise unclear, in some cases leaving faces in the HDR image unrecognizable and text in the HDR image unreadable. For instance, if none of the three exposures selected via exposure bracketing (EV 0, EV −N, EV +N) provide an optimal exposure for a particular region, that region may appear overexposed, underexposed, or otherwise unclear in all three image frames captured using exposure bracketing, and the region will remain unclear (e.g., still appearing overexposed or underexposed) in the resulting HDR image. Generating the HDR image based on identified regions as in the operations overcomes this technical limitations of exposure bracketing, ultimately improving image capture devices and image processing devices to produce HDR images that are superior in that important regions with faces or blocks of text or other important objects do not appear underexposed, overexposed, or otherwise unclear.

In some cases, at operation245, the image processing device105B may receive a third image frame of the scene captured using a third exposure setting based on a third region, and may generate the HDR image based on the third image frame in addition to the first and second image frames. Operation245may, in some cases, also include the image capture device105A capturing the third image frame of the scene using the third exposure setting. At operation245, the image processing device105B may also receive a fourth image frame, a fifth image frame, and so forth, with each respective image frame captured using a respective exposure setting based on a respective region. Any number of regions may be identified, based upon which an exposure settings may be determined and used to capture additional image frames to be merged with the other image frames to generate the HDR image. In some cases, one of the first region, the second region, a third region, or another region is a region that includes the entire scene.

In some cases, operation250may be followed by operation255, in which the image processing device105B stores the device in a non-transitory computer-readable storage medium, such as a hard drive, an optical disk, flash memory, RAM145/625, ROM140/620, a removable storage device, a secure digital (SD) card, a mini secure digital (SD) card, a micro secure digital (SD) card, another type of memory615or storage device630, or some combination thereof.

In some cases, operation250may be followed by operation260, in which the image processing device105B transmits the HDR image to a second device using a transmitter or a transceiver. The transmission may occur over a wired connection, a wireless connection, or some combination thereof. The transmission may in some cases occur over a network, such as a cellular network, a local area network (LAN), a wireless local area network (WLAN), the Internet, or some combination thereof.

In some cases, operation250may be followed by operation265, in which the image processing device105B displays the HDR image on a screen or projector. The screen or projector may be part of the image processing device105B or may be coupled to the image processing device105B. The screen or projector may be part of the second device that the image processing device105B transmits the HDR image to via the operation260.

In some cases, the image processing device105B determines a third exposure setting and a fourth exposure setting using exposure bracketing based on the first exposure setting. For instance, if the first exposure setting is indicated as EV 0, then the third exposure setting may be lower than the first exposure setting by an offset value N (EV −N), and the fourth exposure setting may be higher than the first exposure setting by an offset value N (EV +N). The image processing device105B may capture a third image frame of the scene using the third exposure setting and a capture a fourth image frame of the scene using the fourth exposure setting. In this case, generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame and the fourth image frame. In effect, this technique combines exposure-bracketing-based HDR with the region-based HDR of the operations200. In one example, the first region includes the entire scene, and therefore the first exposure setting is based on the entire scene.

In some cases, the image processing device105B determines a third exposure setting that is offset from the first exposure setting (EV 0) by a predetermined offset value N. That is, the third exposure setting is either lower than the first exposure setting by the offset N (EV −N) or higher than the first exposure setting by the offset N (EV +N). The image processing device105B captures a third image frame of the scene using the third exposure setting. In this case, generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame.

In some cases, the operations200ofFIG.2may be performed by an apparatus or system. The apparatus or system may be or include the image processing device105B, the image capture device105A, the image capture and processing device100, or some combination thereof. The apparatus or system may be or include a mobile device, a mobile phone, a camera, a camcorder, a display device, a projector, or some combination thereof. The apparatus or system may be or include a computing system600.

FIG.3Aillustrates a preview frame of a scene. While the operations described with respect toFIG.3A(andFIG.3B) are described with respect to the image processing device105B, the operations may be performed by the image capture device105A, the image capture and processing device100, the computing system600, or some combination thereof. With respect to the example ofFIG.3AandFIG.3B, the image processing device105B may include a touchscreen or other type of screen, which can display a preview frame. For example, if the image processing device105B is part of a camera device or other image capture and processing device100, the screen may display one or more preview frames of the scene before the user pushes the shutter button.

The particular preview frame300illustrated inFIG.3Adepicts a scene that includes four human figures whose faces are visible in the scene. The faces of the four figures are labeled as face310, face320, face330, and face340. The scene also illustrates a laptop computer350. The scene illustrates a window on the right-hand side that illuminates the right-hand side of the scene, with the left-hand side of the scene comparatively dimly lit and shrouded in shadow. As a result, the faces310and320are dimly lit and shrouded in shadow and not very illuminated by light from the window, while the faces330and340are brightly lit and not shrouded in shadow and well illuminated by light from the window. The laptop computer350, while in the shadow, also acts as its own light source, as the display screen of the laptop computer350is illuminated (e.g., backlit or frontlit). In some cases, contrasts between dimly-lit areas and brightly-lit areas are reproduced poorly using single exposures or traditional HDR techniques.

FIG.3Billustrates the preview frame ofFIG.3Awith multiple regions identified. As shown, the preview frame360ofFIG.3Billustrates the same scene as the preview frame300ofFIG.3A, but with five rectangular regions being identified. In particular, a first region315is identified as a rectangle around the first face310. A second region325is identified as a rectangle around the second face320. A third region335is identified as a rectangle around the third face330. A fourth region345is identified as a rectangle around the fourth face340. A fifth region355is identified as a rectangle around the laptop computer350.

In one exemplary scenario, the preview frame300ofFIG.3Amay be displayed on a touchscreen or other screen of an image processing device105B. A user may observe and touch or click each of the faces310,320,330, and340in the scene, as well as the laptop computer350in the scene. As a result, the image processing device105B may identify region315including the face310, the region325including the face320, the region335including the face330, the region345including the face340, and the region355including the laptop computer350. In some cases, the image processing device105B may use an object recognition algorithm to determine, based on each touch or click by the user, what object was touched or clicked on (e.g., a face310/320/330/340or a laptop computer350), what the boundaries of that object are, and what region shape and size would best encompass that object.

The regions315,325,335,345, and355are all illustrated as rectangular, but may be any shape, including square, oblong rectangular, circular, oblong oval, any polygon, or any freehand-drawn shape, or some combination thereof. In some cases, the shape of a region may be drawn by a user using user inputs to an input device, for example drawn by touch by the user's finger or stylus on the touchscreen or by the mouse pointer using a mouse or trackpad. In some cases, the shape of a region may be indicated by a touch, drag, and release action, or a click, drag, and release action, with the touch or click indicating one corner of the rectangle and the release indicating a diagonally opposite corner of the rectangle. A touch/click, drag, and release action could alternately indicate the two endpoints points of a radius or diameter of a circle or oval that is then the region.

Once the five regions315,325,335,345, and355are identified, the image processing device105B identifies different exposure settings corresponding to each of the five regions. The image processing device105B may do so by performing an auto-exposure process specific to each region. The image processing device105B may thus perform five auto-exposure process; one auto-exposure process specific to the pixels within the first region315, one auto-exposure process specific to the pixels within the second region325, one auto-exposure process specific to the pixels within the third region335, one auto-exposure process specific to the pixels within the fourth region345, and one auto-exposure process specific to the pixels within the fifth region355. The resulting five exposure settings are each designed to optimally expose one of the five regions315,325,335,345, and355. Optimally exposing a region increases the visibility (e.g., contrast) of details within the region, making such details clearer to a viewer of an image captured using such an optimal exposure setting.

FIG.4illustrates an operation merging a plurality of image frames into a single high dynamic range (HDR) image. Five image frames415,425,435,445, and455of the scene ofFIG.3AandFIG.3Bare illustrated as having been captured inFIG.4. The five image frames415,425,435,445, and455of the scene ofFIG.3AandFIG.3Bare captured using the exposure settings generated by the image processing device105B for the five regions315,325,335,345, and355ofFIG.3B, respectively. For example, the first image frame415ofFIG.4was captured using a first exposure setting that optimizes exposure for the first region315ofFIG.3B, the second image frame425ofFIG.4was captured using a second exposure setting that optimizes exposure for the second region325ofFIG.3B, the third image frame435ofFIG.4was captured using a third exposure setting that optimizes exposure for the third region335ofFIG.3B, the fourth image frame445ofFIG.4was captured using a fourth exposure setting that optimizes exposure for the fourth region345ofFIG.3B, and the fifth image frame455ofFIG.4was captured using a fifth exposure setting that optimizes exposure for the fifth region355ofFIG.3B. The rectangles identifying the five regions315,325,335,345, and355are also illustrated in the image frames415,425,435,445, and455ofFIG.4to make it clear which image frame corresponds to which region. However, it should be understood that these region-identifying rectangles are illustrated within the image frames ofFIG.4to make this correspondence easier to understand, and may be missing from the actual image frames415,425,435,445, and455as captured.

Because the first region315and the second region325are both in the dimly-lit area that appears on the left-hand side of the scene in the preview frame300, the first exposure setting and the second exposure setting both use a long exposure time, a large aperture size, a fast ISO speed, a high analog and/or digital gain, or some combination thereof. As a result of the first exposure setting and the second exposure setting, the dimly-lit area that appears on the left-hand side of the scene in the preview frame300(that includes the first region315and the second region325) appears clear and bright in the first image frame415and the second image frame425. As a result of the first exposure setting and the second exposure setting, the brightly-lit area that appears on the right-hand side of the scene in the preview frame300(that includes the third region335and the fourth region345) appears overexposed (e.g., overly bright and saturated with light) in the first image frame415and the second image frame425. Likewise, the area of the scene that appears illuminated by the screen of the laptop computer350in the preview frame300(e.g., around the fifth region355) also appears overexposed in the first image frame415. However, because the second region325is slightly more illuminated than the first region315, for instance because the second region325is closer to the window and to the laptop computer350, the second exposure setting is slightly lower than the first exposure setting, and as a result, the area of the scene that appears illuminated by the screen of the laptop computer350in the preview frame300(e.g., around the fifth region355) is slightly clearer and less overexposed in the second image frame425than the first image frame415.

Because the third region335and the fourth region345are both in the brightly-lit area that appears on the right-hand side of the scene in the preview frame300, the third exposure setting and the fourth exposure setting both use a short exposure time, a small aperture size, a slow ISO speed, a low (or no) analog and/or digital gain, or some combination thereof. As a result of the third exposure setting and the fourth exposure setting, the brightly-lit area that appears on the right-hand side of the scene in the preview frame300(that includes the third region335and the fourth region345) appears clear in the third image frame435and the fourth image frame445. As a result of the third exposure setting and the fourth exposure setting, the dimly-lit area that appears on the left-hand side of the scene in the preview frame300(that includes the first region315and the second region325) appears very dark and dim in the third image frame435and the fourth image frame445. Because the fourth region345is closer to the light source (the window) than the third region335, the fourth exposure setting is even lower than the third exposure setting, so that even the area of the scene that appears illuminated by the screen of the laptop computer350in the preview frame300(that includes the fifth region355) appears darkened in the fourth image frame445, while it remains clear in the third image frame435.

Because the fifth region355includes a laptop computer350with an illuminated screen that may include text or other important information displayed on the screen, the fifth exposure setting uses a short exposure time, a small aperture size, a slow ISO speed, a low (or no) analog and/or digital gain, or some combination thereof. As a result of the fifth exposure setting, the area of the scene that appears illuminated by the screen of the laptop computer350in the preview frame300(that includes the fifth region355) appears clear in the fifth image frame455. Because of the fifth exposure setting, the brightly-lit area that appears on the right-hand side of the scene in the preview frame300(that includes the third region335and the fourth region345) appears slightly dark and dim in the fifth image frame455, and the dimly-lit area that appears on the left-hand side of the scene in the preview frame300(that includes the first region315and the second region325) appears very dark and dim in the fifth image frame455.

The first image frame415, second image frame425, third image frame435, fourth image frame445, and fifth image frame455are merged together into an HDR image460. While some areas of the scene are still brighter or dimmer in the HDR image460, all five of the regions315,325,335,345, and355appear clear, at high contrasts, and with all details (e.g., edges, corners, and other visual features) easily discernable.

FIG.5is a flowchart illustrating an example of a process500of processing image data using the techniques described herein. At block502, the process500includes identifying a first region of a scene. Block502may correspond to operation215of the operations200. At block504, the process500includes determining a first exposure setting based on the first region of the scene. Block504may correspond to operation225of the operations200. At block506, the process500includes identifying a second region of the scene. Block504may correspond to operation220of the operations200. At block508, the process500includes determining a second exposure setting based on the second region of the scene. Block504may correspond to operation230of the operations200.

In some cases, the first and second regions are identified at blocks502and506based on inputs received from certain input devices. In one example, the process500may include receiving one or more touch-based inputs through a touchscreen while the touchscreen displays one or more preview frames of the scene. The one or more touchscreen inputs may be received through a touchscreen connector coupled to the touchscreen and to the image processor150. Identifying the first region and the second region at blocks502and506is based on the one or more touch-based inputs. In another example, the process500may include receiving one or more pointer-based inputs through an input device that controls a pointer on a screen (e.g., a mouse or trackpad) while the screen displays one or more preview frames of the scene. The one or more pointer-based inputs may be received through an input device connector coupled to the input device and to the image processor150. Identifying the first region and the second region at blocks502and506is based on the one or more pointer-based inputs.

In some cases, the first and second regions are identified at blocks502and506based on an algorithm. In one example, the process500includes identifying an object in the scene using an object detection algorithm. Identifying the first region of the scene at block502is based on identifying that the object is within the first region. Similarly, identifying the second region of the scene at block506can be based on identifying that a second object is within the second region using the object detection algorithm. In some cases, the object can be a face of a person. The second object can be a second face of a second person, or can be a different object.

In some cases, the first exposure setting corresponds to a first exposure time, and the second exposure setting corresponds to a second exposure time that is different from the first exposure time. In some cases, a mid-tone of the first region in the scene matches a mid-tone of a representation of the first region in the first image frame within a first threshold, and wherein a mid-tone of the second region in the scene matches a mid-tone of a representation of the first region in the second image frame within a second threshold.

In some cases, the first region includes all of the pixels of the first image frame. In other words, the first region includes the entire portion of the scene that is visible to the image sensor130, that is received by the image processor150from the image sensor130, or that results from one or more operations performed by the image processor150.

At block510, the process500includes receiving a first image frame of the scene that is captured using the first exposure setting. In some cases, block506may also include capturing the first image frame of the scene using the first exposure setting. Block506may correspond to operation235of the operations200.

At block512, the process500includes receiving a second image frame of the scene that is captured using the second exposure setting. In some cases, block508may also include capturing the second image frame of the scene using the second exposure setting. Block508may correspond to operation240of the operations200.

In some cases, the first region is reproduced in the second image frame at a second contrast level and in the first image frame at a first contrast level that exceeds the second contrast level. In some cases, the second region is reproduced in the first image frame at a first contrast level and in the second image frame at a second contrast level that exceeds the first contrast level.

At block514, the process500includes generating a high dynamic range (HDR) image of the scene by merging at least the first image frame and the second image frame. Block510may correspond to operation250of the operations200.

In some cases, a third dynamic range of the HDR image is greater than at least one of a first dynamic range of the first image frame and a second dynamic range of the second image frame.

In some cases, the process500may also include identifying a third region of the scene, determining a third exposure setting based on a third region of the scene, and receiving a third image frame of the scene captured using the third exposure setting. Generating the HDR image of the scene at block514, in this case, includes merging at least the first image frame and the second image frame and the third image frame.

In some cases, the process500may also include determining a third exposure setting and a fourth exposure setting using exposure bracketing based on the first exposure setting, receiving a third image frame of the scene captured using the third exposure setting, and receiving a fourth image frame of the scene captured using the fourth exposure setting. Generating the HDR image of the scene at block514, in this case, includes merging at least the first image frame and the second image frame and the third image frame and the fourth image frame.

In some cases, the process500may also include determining a third exposure setting that is offset from the first exposure setting by a predetermined offset and receiving a third image frame of the scene captured using the third exposure setting. Generating the HDR image of the scene at block514, in this case, includes merging at least the first image frame and the second image frame and the third image frame.

In some examples, the processes described herein (e.g., process500and/or other process described herein) may be performed by a computing device or apparatus. In one example, the process500can be performed by the image processing device105B ofFIG.1. In another example, the process500can be performed by the image capture and processing device100ofFIG.1. In another example, the process500can be performed by a computing system600including the architecture shown inFIG.6. The computing device can include any suitable device, such as a mobile device (e.g., a mobile phone), a desktop computing device, a tablet computing device, a wearable device (e.g., a VR headset, an AR headset, AR glasses, a network-connected watch or smartwatch, or other wearable device), a server computer, an autonomous vehicle or computing device of an autonomous vehicle, a robotic device, a television, and/or any other computing device with the resource capabilities to perform the processes described herein, including the process500. In some cases, the computing device or apparatus may include various components, such as one or more input devices, one or more output devices, one or more processors, one or more microprocessors, one or more microcomputers, one or more cameras, one or more sensors, and/or other component(s) that are configured to carry out the steps of processes described herein. In some examples, the computing device may include a display, a network interface configured to communicate and/or receive the data, any combination thereof, and/or other component(s). The network interface may be configured to communicate and/or receive Internet Protocol (IP) based data or other type of data.

FIG.6is a diagram illustrating an example of a system for implementing certain aspects of the present technology. In particular,FIG.6illustrates an example of computing system600, which can be for example any computing device making up internal computing system, a remote computing system, a camera, or any component thereof in which the components of the system are in communication with each other using connection605. Connection605can be a physical connection using a bus, or a direct connection into processor610, such as in a chipset architecture. Connection605can also be a virtual connection, networked connection, or logical connection.

Example system600includes at least one processing unit (CPU or processor)610and connection605that couples various system components including system memory615, such as read-only memory (ROM)620and random access memory (RAM)625to processor610. Computing system600can include a cache612of high-speed memory connected directly with, in close proximity to, or integrated as part of processor610.

Processor610can include any general purpose processor and a hardware service or software service, such as services632,634, and636stored in storage device630, configured to control processor610as well as a special-purpose processor where software instructions are incorporated into the actual processor design. Processor610may essentially be a completely self-contained computing system, containing multiple cores or processors, a bus, memory controller, cache, etc. A multi-core processor may be symmetric or asymmetric.

To enable user interaction, computing system600includes an input device645, which can represent any number of input mechanisms, such as a microphone for speech, a touch-sensitive screen for gesture or graphical input, keyboard, mouse, motion input, speech, etc. Computing system600can also include output device635, which can be one or more of a number of output mechanisms. In some instances, multimodal systems can enable a user to provide multiple types of input/output to communicate with computing system600. Computing system600can include communications interface640, which can generally govern and manage the user input and system output. The communication interface may perform or facilitate receipt and/or transmission wired or wireless communications using wired and/or wireless transceivers, including those making use of an audio jack/plug, a microphone jack/plug, a universal serial bus (USB) port/plug, an Apple® Lightning® port/plug, an Ethernet port/plug, a fiber optic port/plug, a proprietary wired port/plug, a BLUETOOTH® wireless signal transfer, a BLUETOOTH® low energy (BLE) wireless signal transfer, an IBEACON® wireless signal transfer, a radio-frequency identification (RFID) wireless signal transfer, near-field communications (NFC) wireless signal transfer, dedicated short range communication (DSRC) wireless signal transfer, 802.11 Wi-Fi wireless signal transfer, wireless local area network (WLAN) signal transfer, Visible Light Communication (VLC), Worldwide Interoperability for Microwave Access (WiMAX), Infrared (IR) communication wireless signal transfer, Public Switched Telephone Network (PSTN) signal transfer, Integrated Services Digital Network (ISDN) signal transfer, 3G/4G/5G/LTE cellular data network wireless signal transfer, ad-hoc network signal transfer, radio wave signal transfer, microwave signal transfer, infrared signal transfer, visible light signal transfer, ultraviolet light signal transfer, wireless signal transfer along the electromagnetic spectrum, or some combination thereof. The communications interface640may also include one or more Global Navigation Satellite System (GNSS) receivers or transceivers that are used to determine a location of the computing system600based on receipt of one or more signals from one or more satellites associated with one or more GNSS systems. GNSS systems include, but are not limited to, the US-based Global Positioning System (GPS), the Russia-based Global Navigation Satellite System (GLONASS), the China-based BeiDou Navigation Satellite System (BDS), and the Europe-based Galileo GNSS. There is no restriction on operating on any particular hardware arrangement, and therefore the basic features here may easily be substituted for improved hardware or firmware arrangements as they are developed.

The storage device630can include software services, servers, services, etc., that when the code that defines such software is executed by the processor610, it causes the system to perform a function. In some embodiments, a hardware service that performs a particular function can include the software component stored in a computer-readable medium in connection with the necessary hardware components, such as processor610, connection605, output device635, etc., to carry out the function.

Illustrative aspects of the application are provided below:

Aspect 1. A method of processing image data, the method comprising: identifying a first region of a scene; determining a first exposure setting based on the first region of the scene; identifying a second region of the scene; determining a second exposure setting based on the second region of the scene; receiving a first image frame of the scene that is captured using the first exposure setting; receiving a second image frame of the scene that is captured using the second exposure setting; and generating a high dynamic range (HDR) image of the scene by merging at least the first image frame and the second image frame.

Aspect 2. The method of aspect 1, further comprising: receiving one or more touch-based inputs through a touchscreen while the touchscreen displays one or more preview frames of the scene, wherein identifying the first region and the second region is based on the one or more touch-based inputs.

Aspect 3. The method of any one of aspects 1 or 2, further comprising: receiving one or more pointer-based inputs through an input device that controls a pointer on a screen while the screen displays one or more preview frames of the scene, wherein identifying the first region and the second region is based on the one or more pointer-based inputs.

Aspect 4. The method of any one of aspects 1 to 3, further comprising: identifying an object in the scene using an object detection algorithm, wherein identifying the first region of the scene is based on identifying that the object is within the first region.

Aspect 5. The method of aspect 4, wherein the object is a face.

Aspect 6. The method of any one of aspects 1 to 5, further comprising: identifying a third region of the scene; determining a third exposure setting based on a third region of the scene; and receiving a third image frame of the scene captured using the third exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame.

Aspect 7. The method of any one of aspects 1 to 6, wherein the first exposure setting corresponds to a first exposure time and the second exposure setting corresponds to a second exposure time that is different from the first exposure time.

Aspect 8. The method of any one of aspects 1 to 7, wherein a mid-tone of the first region in the scene matches a mid-tone of a representation of the first region in the first image frame within a first threshold, and wherein a mid-tone of the second region in the scene matches a mid-tone of a representation of the first region in the second image frame within a second threshold.

Aspect 9. The method of any one of aspects 1 to 8, wherein the first region is reproduced in the second image frame at a second contrast level and in the first image frame at a first contrast level that exceeds the second contrast level.

Aspect 10. The method of any one of aspects 1 to 9, wherein the second region is reproduced in the first image frame at a first contrast level and in the second image frame at a second contrast level that exceeds the first contrast level.

Aspect 11. The method of any one of aspects 1 to 10, wherein a third dynamic range of the HDR image is greater than at least one of a first dynamic range of the first image frame and a second dynamic range of the second image frame.

Aspect 12. The method of any one of aspects 1 to 11, wherein the first region includes all pixels of the first image frame.

Aspect 13. The method of any one of aspects 1 to 12, further comprising: determining a third exposure setting and a fourth exposure setting using exposure bracketing based on the first exposure setting; receiving a third image frame of the scene captured using the third exposure setting; and receiving a fourth image frame of the scene captured using the fourth exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame and the fourth image frame.

Aspect 14. The method of any one of aspects 1 to 13, further comprising: determining a third exposure setting that is offset from the first exposure setting by a predetermined offset; and receiving a third image frame of the scene captured using the third exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame.

Aspect 15. The method of any one of aspects 1 to 14, further comprising: capturing the first image frame of the scene using the first exposure setting; and capturing the second image frame of the scene using the second exposure setting.

Aspect 16. An apparatus for processing image data, the apparatus comprising: a connector that is coupled to an image sensor, wherein the connector receives a first image frame of a scene that is captured using a first exposure setting and receives a second image frame of the scene that is captured using a second exposure setting; one or more memory units storing instructions; and one or more processors that execute the instructions, wherein execution of the instructions by the one or more processors causes the one or more processors to: identify a first region of the scene, determine the first exposure setting based on the first region of the scene, identify a second region of the scene, determine the second exposure setting based on the second region of the scene, and generate a high dynamic range (HDR) image of the scene by merging at least the first image frame and the second image frame.

Aspect 17. The apparatus of aspect 16, wherein the apparatus is a mobile device.

Aspect 18. The apparatus of any one of aspects 16 or 17, wherein the apparatus includes a display configured to display the HDR image.

Aspect 19. The apparatus of any one of aspects 16 to 18, wherein the apparatus is a camera.

Aspect 20. The apparatus of any one of aspects 16 to 19, further comprising a touchscreen connector that is coupled to a touchscreen, wherein the touchscreen connector receives one or more touch-based inputs from the touchscreen while the touchscreen displays one or more preview frames of the scene, wherein identifying the first region of the scene and identifying the second region of the scene are based on the one or more touch-based inputs.

Aspect 21. The apparatus of any one of aspects 16 to 20, further comprising an input device connector that is coupled to an input device that controls a pointer on a screen, wherein the input device connector receiving one or more pointer-based inputs from the input device while the screen displays one or more preview frames of the scene, wherein identifying the first region of the scene and identifying the second region of the scene are based on the one or more pointer-based inputs.

Aspect 22. The apparatus of any one of aspects 16 to 21, wherein execution of the instructions by the one or more processors causes the one or more processors to further identify an object in the scene using an object detection algorithm, wherein identifying the first region of the scene is based on identifying that the object is within the first region.

Aspect 23. The apparatus of aspect 22, wherein execution of the instructions by the one or more processors causes the one or more processors to further: identify a third region of the scene, determine a third exposure setting based on a third region of the scene, and receive a third image frame of the scene captured using the third exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame.

Aspect 24. The apparatus of any one of aspects 16 to 23, wherein the first exposure setting corresponds to a first exposure time and the second exposure setting corresponds to a second exposure time that is different from the first exposure time.

Aspect 25. The apparatus of any one of aspects 16 to 24, wherein a mid-tone of the first region in the scene matches a mid-tone of a representation of the first region in the first image frame within a first threshold, and wherein a mid-tone of the second region in the scene matches a mid-tone of a representation of the first region in the second image frame within a second threshold.

Aspect 26. The apparatus of any one of aspects 16 to 25, wherein the first region includes all pixels of the first image frame.

Aspect 27. The apparatus of any one of aspects 16 to 26, wherein execution of the instructions by the one or more processors causes the one or more processors to further:

determine a third exposure setting and a fourth exposure setting using exposure bracketing based on the first exposure setting, receive a third image frame of the scene captured using the third exposure setting, and receive a fourth image frame of the scene captured using the fourth exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame and the fourth image frame.

Aspect 28. The apparatus of any one of aspects 16 to 27, wherein execution of the instructions by the one or more processors causes the one or more processors to further: determine a third exposure setting that is offset from the first exposure setting by a predetermined offset, and receive a third image frame of the scene captured using the third exposure setting, wherein generating the HDR image of the scene includes merging at least the first image frame and the second image frame and the third image frame.

Aspect 29. The apparatus of any one of aspects 16 to 28, further comprising the image sensor, wherein the image sensor is configured to capture the first image frame of the scene using the first exposure setting and is configured to capture the second image frame of the scene using the second exposure setting.

Aspect 30. A non-transitory computer readable storage medium having embodied thereon a program, wherein the program is executable by a processor to perform any of the operations of aspects 1 to 29.

Aspect 31. An apparatus comprising means for performing any of the operations of aspects 1 to 29.