WO2016029641A1 - 照片获取方法及装置 - Google Patents

照片获取方法及装置 Download PDF

Info

Publication number
WO2016029641A1
WO2016029641A1 PCT/CN2015/071358 CN2015071358W WO2016029641A1 WO 2016029641 A1 WO2016029641 A1 WO 2016029641A1 CN 2015071358 W CN2015071358 W CN 2015071358W WO 2016029641 A1 WO2016029641 A1 WO 2016029641A1
Authority
WO
WIPO (PCT)
Prior art keywords
moving object
image
images
background area
electronic device
Prior art date
Application number
PCT/CN2015/071358
Other languages
English (en)
French (fr)
Inventor
唐明勇
刘华一君
陈涛
Original Assignee
小米科技有限责任公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 小米科技有限责任公司 filed Critical 小米科技有限责任公司
Priority to JP2016544716A priority Critical patent/JP6198958B2/ja
Priority to BR112015010286A priority patent/BR112015010286A2/pt
Priority to RU2015116616A priority patent/RU2634907C2/ru
Priority to KR1020157011766A priority patent/KR101772177B1/ko
Priority to MX2015005029A priority patent/MX354121B/es
Priority to US14/707,186 priority patent/US9674395B2/en
Publication of WO2016029641A1 publication Critical patent/WO2016029641A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N1/00Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
    • H04N1/387Composing, repositioning or otherwise geometrically modifying originals
    • H04N1/3876Recombination of partial images to recreate the original image
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • H04N5/2621Cameras specially adapted for the electronic generation of special effects during image pickup, e.g. digital cameras, camcorders, video cameras having integrated special effects capability
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/60Editing figures and text; Combining figures or text
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/40Scaling of whole images or parts thereof, e.g. expanding or contracting
    • G06T3/4038Image mosaicing, e.g. composing plane images from plane sub-images
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • H04N23/68Control of cameras or camera modules for stable pick-up of the scene, e.g. compensating for camera body vibrations
    • H04N23/681Motion detection
    • H04N23/6812Motion detection based on additional sensors, e.g. acceleration sensors
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/80Camera processing pipelines; Components thereof
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/95Computational photography systems, e.g. light-field imaging systems
    • H04N23/951Computational photography systems, e.g. light-field imaging systems by using two or more images to influence resolution, frame rate or aspect ratio
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • H04N5/2625Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects for obtaining an image which is composed of images from a temporal image sequence, e.g. for a stroboscopic effect
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules

Definitions

  • the present disclosure relates to the field of image processing, and in particular, to a photo acquisition method and apparatus.
  • a motion trajectory photograph is a photograph that can display a motion trajectory of a moving object.
  • Motion track photos can give users a novel visual effect.
  • the user usually adopts professional shooting techniques to shoot the motion track.
  • Most of the shooting process requires a tripod to fix the camera, and according to the moving speed of the moving object, the corresponding shutter speed is used for shooting, so as to obtain a high-quality motion track photo.
  • the cumbersome and professional operation ordinary users cannot take high-quality photos of motion tracks.
  • the embodiment of the present disclosure provides a photo acquisition method and device, and the technical solution is as follows:
  • a photo acquisition method comprising:
  • the target photo is synthesized according to the background area and the moving object, and the target photo includes images of at least two different motion states of the same moving object located on the same background area.
  • acquiring n frames of images includes:
  • the n-frame image is obtained by shooting in the fast continuous shooting mode, which is a mode in which one image is taken every predetermined time interval.
  • acquiring n frames of images includes:
  • An n-frame image is extracted from the video.
  • the method further includes:
  • the step of acquiring an n-frame image is performed.
  • detecting whether the electronic device is currently in a stationary state includes:
  • the sensor includes a gravity acceleration sensor and/or a gyroscope and/or an electronic compass sensor; detecting whether the sensor data changes, and characterizing the electronic device in a stationary state when the sensor data does not change ;
  • the background area collected by the image sensor in the electronic device is detected to be changed, and the electronic device is in a stationary state when the background area does not change.
  • identifying background regions and moving objects in the n-frame image includes:
  • a moving object whose moving speed reaches a preset threshold on the background area is detected based on the adjacent image.
  • the composite photo is synthesized based on the background area and the moving object, including:
  • the target photo is synthesized based on the same background area and at least two images of the same moving object.
  • the composite photo is synthesized based on the background area and the moving object, including:
  • the target photo is synthesized according to the target background area and at least two images of the same moving object.
  • a photo obtaining apparatus comprising:
  • An image acquisition module configured to acquire an n-frame image, n ⁇ 2;
  • An image recognition module configured to identify a background area and a moving object in the n-frame image
  • the photo synthesis module is configured to synthesize the target photo according to the background area and the moving object, and the target photo includes images of at least two different motion states of the same moving object located on the same background area.
  • the image acquisition module includes:
  • the first shooting sub-module is configured to acquire n frames of images by the fast continuous shooting mode, and the fast continuous shooting mode is a mode of capturing one image every predetermined time interval.
  • the image acquisition module includes:
  • a second shooting sub-module configured to capture a video
  • An image extraction sub-module configured to extract n frames of images from the video.
  • the device further includes:
  • Detecting a stationary module configured to detect whether the electronic device is currently in a stationary state
  • the image acquisition module is configured to perform the step of acquiring an n-frame image when the detection still module detects that the electronic device is currently in a stationary state.
  • detecting a stationary module includes:
  • a first detection sub-module configured to acquire sensor data collected by a sensor disposed on the electronic device, the sensor comprising a gravity acceleration sensor and/or a gyroscope and/or an electronic compass sensor; detecting whether the sensor data changes, the sensor data is not Characterizing the electronic device to be in a stationary state when a change occurs;
  • the second detecting submodule is configured to detect whether a background area collected by the image sensor in the electronic device changes, and the electronic device is in a stationary state when the background area does not change.
  • the image recognition module includes:
  • a background recognition submodule configured to identify a background area in the n frame image
  • the speed detecting sub-module is configured to detect a moving object whose moving speed reaches a preset threshold on the background area according to the adjacent image.
  • the photo synthesis module includes:
  • the same background recognition sub-module configured to identify the same background area in the n-frame image
  • a first extraction from the module configured to extract, for the same moving object, at least two images of the moving object that do not overlap each other in the n-frame image, or extract at least two of the overlapping portions of the moving object in the n-frame image that do not exceed a predetermined threshold Image
  • the first generation sub-module is configured to synthesize the target photo according to the same background area and at least two images of the same moving object.
  • the photo synthesis module includes:
  • the background splicing sub-module is configured to splicing the target background area according to the background area in which the intersection of the n-frame images exists;
  • a second extraction sub-module configured to extract, for the same moving object, at least two images of the moving object that do not overlap each other in the n-frame image, or extract at least two of the overlapping portions of the moving object in the n-frame image that do not exceed a predetermined threshold Image
  • the second generation sub-module is configured to synthesize the target photo according to the target background area and the at least two images of the same moving object.
  • n frames of images n ⁇ 2; identifying background regions and moving objects in the n-frame image; according to the background region and The animal body synthesizes a target photo, which includes images of at least two different motion states of the same moving object located on the same background area; in the related art, due to the cumbersome and professional operation, ordinary users cannot capture high-quality motion trajectories The problem of the photo; the effect of taking high-quality trajectory photos without the user's cumbersome operation during the shooting.
  • FIG. 1 is a flowchart of a method of a photo acquisition method according to an exemplary embodiment
  • FIG. 2 is a flowchart of a method of a photo acquisition method according to another exemplary embodiment
  • FIG. 3 is a schematic diagram of an implementation of a photo acquisition method according to another exemplary embodiment
  • FIG. 4 is a schematic diagram of an implementation of a photo acquisition method according to another exemplary embodiment
  • FIG. 5 is a schematic diagram of an implementation of a photo acquisition method according to another exemplary embodiment
  • FIG. 6 is a schematic diagram of an implementation of a photo acquisition method according to another exemplary embodiment
  • FIG. 7 is a schematic diagram of an implementation of a photo acquisition method according to another exemplary embodiment.
  • FIG. 8 is a flowchart of a method of a photo acquisition method according to another exemplary embodiment
  • FIG. 9 is a schematic diagram of an implementation of a photo acquisition method according to another exemplary embodiment.
  • FIG. 10 is a block diagram showing the structure of a photo taking device according to an exemplary embodiment
  • FIG. 11 is a block diagram showing the structure of a photo taking device according to another exemplary embodiment.
  • FIG. 12 is a block diagram showing the structure of an electronic device according to an exemplary embodiment.
  • the photo acquisition method provided by the various embodiments of the present invention may be powered by an image processing capability and an image capturing capability.
  • Sub-devices are implemented.
  • the electronic device can be a smartphone, a tablet, an e-book reader, and a laptop portable computer (camera, video camera), and the like.
  • FIG. 1 is a flowchart of a method for acquiring a photo according to an exemplary embodiment.
  • the photo is obtained by using the photo acquisition method in an electronic device having image processing capability and image capturing capability. Including the following steps.
  • step 102 an n-frame image is acquired, n ⁇ 2.
  • step 104 the background area and the moving object in the n-frame image are identified.
  • a target photo is synthesized based on the background area and the moving object, the target photo including images of at least two different motion states of the same moving object located on the same background area.
  • the photo acquisition method acquires an n-frame image, n ⁇ 2; identifies a background region and a moving object in the n-frame image; and synthesizes the target photo according to the background region and the moving object, the target
  • the photo includes images of at least two different motion states of the same moving object on the same background area; solving the cumbersome and professional operation, the ordinary user cannot take high-quality photos of the moving track; the user does not need to perform the shooting process.
  • the cumbersome operation can also produce high-quality motion track photos.
  • FIG. 2 is a flowchart of a method for acquiring a photo according to an exemplary embodiment.
  • the present embodiment is described in the electronic device having image processing capability and image capturing capability.
  • the photo acquisition method may include the following steps:
  • step 201 it is detected whether the electronic device is currently in a stationary state.
  • step 201 can be implemented by any one or a combination of the two.
  • the electronic device acquires sensor data collected by a sensor disposed on the electronic device, the sensor includes a gravity acceleration sensor and/or a gyroscope and/or an electronic compass sensor; the electronic device detects whether the sensor data changes, and the sensor data does not occur. Characterizing the electronic device at rest when changing
  • the electronic device detects whether the background area collected by the image sensor in the electronic device changes, and the electronic device is in a stationary state when the background area does not change.
  • the first detection mode may be performed first, and when the sensor data does not change, the second detection mode is performed.
  • step 201 is repeated.
  • step 202 when the electronic device is in a stationary state, an n-frame image is acquired, n ⁇ 2.
  • Step 202 can include the following sub-steps:
  • the electronic device first takes a video
  • the electronic device extracts n frames of images from the video.
  • the electronic device can extract each frame of the image in the video to obtain an n-frame image.
  • the n-frame image is usually an image having the same or similar background regions arranged from front to back in accordance with the shooting time.
  • the electronic device may also extract an image frame in the video and acquire an n-frame image by extracting one frame of image frames every predetermined frame.
  • the video has a total of 24 frames
  • the electronic device can extract each frame of the image frame, and extract a total of 24 frames of images; the electronic device can also extract a total of 6 frames according to the method of extracting one frame of image frames every 4 frames.
  • the electronic device can also capture n frames of images by using a fast continuous shooting mode, which is a mode of capturing an image every predetermined time interval.
  • a fast continuous shooting mode which is a mode of capturing an image every predetermined time interval.
  • step 203 a background area in the n-frame image is identified.
  • step 203 may include the following sub-steps:
  • the electronic device performs differential operation on the adjacent two frames of images to obtain a difference image
  • the electronic device Since the gradation and position of the pixel in the background area generally do not change, the electronic device obtains a difference image obtained by performing differential operation on two adjacent frames, that is, an image of the moving object.
  • the electronic device performs a difference operation between the two frames of images and the difference image to obtain a background image corresponding to the two frame images.
  • the two frames of images are respectively subjected to a difference algorithm with the difference image, and the electronic device can obtain a background image corresponding to the two frames of images.
  • step 204 a moving object whose moving speed reaches a preset threshold on the background area is detected based on the adjacent image.
  • Step 204 can include the following sub-steps:
  • the electronic device recognizes a moving object in the n-frame image
  • the electronic device first detects moving objects in the n-frame image according to foreground detection techniques and/or moving target detection techniques.
  • the electronic device acquires an image on the image of the moving object in one frame of the image frame.
  • the coordinates of the pixel point 33 on the image 32 of the moving object in the image frame 31 are acquired.
  • the electronic device acquires coordinates of corresponding pixel points on the image of the moving object in the adjacent image frame of the image frame;
  • the coordinates of the corresponding pixel point 36 on the image 35 of the moving object in the image frame 34 adjacent to the image frame 31 are acquired.
  • the electronic device calculates the velocity of the moving object based on the difference between the two coordinates.
  • the electronic device calculates a difference between the coordinates of the pixel 35 and the corresponding pixel 36, and calculates the velocity of the moving object based on the difference and the time difference of the adjacent image frames.
  • the electronic device compares the calculated speed of the moving object with a preset threshold.
  • the moving object is a moving object whose moving speed reaches a preset threshold on the background area.
  • step 205 the same background area in the n-frame image is identified.
  • the electronic device can also identify the same background area in the n-frame image, and use the background area as the background area of the motion track picture to be generated.
  • the electronic device can recognize the background area 41 in the image by performing a difference operation on the image.
  • step 206 for the same moving object, at least two images of the moving object that do not overlap each other in the n-frame image are extracted, or at least two images in which the overlapping portion of the moving object does not exceed a predetermined threshold in the n-frame image are extracted.
  • step 206 may Including the following steps:
  • the electronic device respectively acquires a coordinate set corresponding to the image of the moving object in the two frames of images
  • the electronic device acquires the coordinate set A of the moving object image 52 in the image 51, and acquires the coordinate set B of the moving object image 54 in the image 53.
  • the electronic device detects whether the same coordinates exist in the two coordinate sets; if present, the two images are superimposed and one of the images is discarded; if not, two images are simultaneously used.
  • the electronic device detects whether the coordinate set A and the coordinate set B have the same coordinates. For example, the coordinate combination A and the coordinate set B do not have the same coordinates, that is, the representation moving object image 52 and the moving object image 54 do not overlap.
  • the electronic device respectively acquires a coordinate set corresponding to the image of the moving object in the two frames of images
  • the electronic device acquires the coordinate set A of the moving object image 62 in the image 61, and acquires the coordinate set B of the moving object image 64 in the image 63.
  • the electronic device calculates the proportion of the same coordinates in the two coordinate sets
  • the electronic device extracts an image of the moving object in two frames of images.
  • the preset threshold value is 10%
  • the ratio of the same coordinate in the coordinate set A of the moving object image 62 and the coordinate set B of the moving object image 64 is 5%
  • the electronic device extracts the moving object image. 72 and moving object image 64.
  • the electronic device extracts one image of the moving object in the two frames of images, and discards the other image.
  • step 207 the target photo is synthesized based on the same background area and at least two images of the same moving object.
  • the electronic device synthesizes the target photo, that is, the motion trajectory photo, according to the same background region in the n-frame image identified in step 208, and at least two images of the same moving object extracted in step 207.
  • the same background area 81 among the five frames of images recognized by the electronic device, five images 72 of the same moving object extracted by the electronic device, and finally the target picture 73 are synthesized according to the background area 71 and the five images 72.
  • the moving object herein may be a moving object whose speed of motion selected by the electronic device in step 204 exceeds a predetermined threshold.
  • the electronic device first uses the same background area as the background area of the target photo. Then, for different images of the same moving object, the electronic device copies the image to the corresponding position in the same background region according to the original relative position of each image in the n-frame image and the background region, and finally obtains the target photo.
  • the photo acquisition method acquires an n-frame image, n ⁇ 2; identifies a background region and a moving object in the n-frame image; and synthesizes the target photo according to the background region and the moving object, the target
  • the photograph includes images of at least two different motion states of the same moving object located on the same background area; solving the related art problem that the ordinary user cannot photograph the high-quality motion track due to the cumbersome operation and professionalism; No need for users to carry out cumbersome operations, but also to capture the effect of high-quality motion track photos.
  • the present exemplary embodiment also detects whether the electronic device is in a stationary state, and acquires an n-frame image when the electronic device is in a stationary state, thereby ensuring the quality of the generated motion track photo.
  • the present exemplary embodiment further solves the problem by extracting at least two images in which the moving objects do not overlap each other in the n-frame image, or extracting at least two images in which the overlapping portion of the moving object does not exceed a predetermined threshold in the n-frame image.
  • the problem of serious image overlap in the motion picture has improved the quality of the generated motion picture.
  • the electronic device can also obtain a target background region similar to the panoramic photo by splicing the background regions where the intersection exists, and then according to The target background area and at least two image composite motion trajectories of the same moving object will be described below using an exemplary embodiment.
  • FIG. 8 is a flowchart of a method of a photo acquisition method according to an exemplary embodiment. This embodiment continues to be explained using the photo acquisition method for an electronic device having image processing capability and image capturing capability.
  • the photo acquisition method may include the following steps:
  • step 801 an n-frame image is acquired, n ⁇ 2.
  • Step 202 can include the following sub-steps:
  • the electronic device first takes a video
  • the electronic device extracts n frames of images from the video.
  • the electronic device can extract each frame of the image in the video to obtain an n-frame image.
  • the n-frame image is usually an image having the same or similar background regions arranged from front to back in accordance with the shooting time.
  • the electronic device may also extract an image frame in the video and acquire an n-frame image by extracting one frame of image frames every predetermined frame.
  • the video has a total of 24 frames
  • the electronic device can extract each frame of the image frame, and extract a total of 24 frames of images; the electronic device can also extract a total of 6 frames according to the method of extracting one frame of image frames every 4 frames.
  • the electronic device can also capture n frames of images by using a fast continuous shooting mode, which is a mode of capturing an image every predetermined time interval.
  • a fast continuous shooting mode which is a mode of capturing an image every predetermined time interval.
  • step 802 a background area in the n-frame image is identified.
  • step 802 can include the following sub-steps:
  • the electronic device performs differential operation on the adjacent two frames of images to obtain a difference image
  • the electronic device Since the gradation and position of the pixel in the background area generally do not change, the electronic device obtains a difference image obtained by performing differential operation on two adjacent frames, that is, an image of the moving object.
  • the electronic device performs a difference operation between the two frames of images and the difference image to obtain a background image corresponding to the two frame images.
  • the two frames of images are respectively subjected to a difference algorithm with the difference image, and the electronic device can obtain a background image corresponding to the two frames of images.
  • step 803 a moving object whose moving speed reaches a preset threshold on the background area is detected based on the adjacent image.
  • Step 803 can include the following sub-steps:
  • the electronic device recognizes a moving object in the n-frame image
  • the electronic device first detects moving objects in the n-frame image according to foreground detection techniques and/or moving target detection techniques.
  • the electronic device acquires coordinates of a pixel on the image of the moving object in one frame of the image frame;
  • the coordinates of the pixel point 33 on the image 32 of the moving object in the image frame 31 are acquired.
  • the electronic device acquires coordinates of corresponding pixel points on the image of the moving object in the adjacent image frame of the image frame;
  • the coordinates of the corresponding pixel point 36 on the image 35 of the moving object in the image frame 34 adjacent to the image frame 31 are acquired.
  • the electronic device calculates the velocity of the moving object based on the difference between the two coordinates.
  • the electronic device calculates a difference between the coordinates of the pixel 35 and the corresponding pixel 36, and calculates the velocity of the moving object based on the difference and the time difference of the adjacent image frames.
  • the electronic device compares the calculated speed of the moving object with a preset threshold.
  • the moving object is a moving object whose moving speed reaches a preset threshold on the background area.
  • step 804 the target background region is obtained according to the background region in which the intersection exists in the n-frame image.
  • n frames of images may be taken in a non-stationary state or in a relatively stationary state (such as when riding a car), the background areas corresponding to the n frames of images may not be identical.
  • the electronic device may splicing the background regions according to the intersection region to obtain the target background region.
  • the image 91, the image 92, and the image 93 correspond to the same background area 94
  • the image 95 and the image 96 correspond to the same background area 97
  • the background area 94 and the background area 97 are not identical.
  • the background area 94 and the background area 97 have an intersection area 98, and the electronic device will splicing the background area 97 and the background area 98 according to the intersection area 94 to obtain the target background area 99.
  • step 805 for the same moving object, at least two images of the moving object that do not overlap each other in the n-frame image are extracted, or at least two images in which the overlapping portion of the moving object does not exceed a predetermined threshold in the n-frame image are extracted.
  • step 805 may Including the following steps:
  • the electronic device respectively acquires a coordinate set corresponding to the image of the moving object in the two frames of images
  • the electronic device acquires the coordinate set A of the moving object image 52 in the image 51, and acquires the coordinate set B of the moving object image 54 in the image 53.
  • the electronic device detects whether the same coordinates exist in the two coordinate sets. If present, the two images are superimposed and one of the images is discarded; if not, two images are simultaneously used.
  • the electronic device detects whether the coordinate set A and the coordinate set B have the same coordinates. For example, the coordinate combination A and the coordinate set B do not have the same coordinates, that is, the representation moving object image 52 and the moving object image 54 do not overlap.
  • the electronic device can extract at least two images in which the overlapping portion of the moving object does not exceed a predetermined threshold in the n-frame image, and the sub-steps can be as follows:
  • the electronic device respectively acquires a coordinate set corresponding to the image of the moving object in the two frames of images
  • the electronic device acquires the coordinate set A of the moving object image 62 in the image 61, and acquires the coordinate set B of the moving object image 64 in the image 63.
  • the electronic device calculates the proportion of the same coordinates in the two coordinate sets
  • the electronic device extracts an image of the moving object in two frames of images.
  • the preset threshold value is 10%, and the ratio of the same coordinate in the coordinate set A of the moving object image 62 and the coordinate set B of the moving object image 64 is 5%, and the moving object image 72 is extracted. Moving object image 64.
  • the electronic device extracts one image of the moving object in the two frames of images, and discards the other image.
  • a target photo is synthesized based on the target background area and at least two images of the same moving object.
  • the electronic device synthesizes the target photo, that is, the motion trajectory photo, according to the target background region spliced in step 804, at least two images of the same moving object extracted by the electronic device in step 805.
  • the moving object herein may be a moving object whose speed of motion selected by the electronic device in step 803 exceeds a predetermined threshold.
  • the electronic device first uses the target background area as the background area of the target photo. Then, for different images of the same moving object, the electronic device copies the image to the corresponding position in the target background region according to the original relative position of each image in the n-frame image and the background region, and finally obtains the target photo.
  • the electronic device obtains the target background area 71 by splicing the background area where the intersection exists, the five images 72 of the same moving object extracted by the electronic device, and finally synthesizes the target photo according to the background area 71 and the five images 72. 73.
  • the photo acquisition method acquires an n-frame image, n ⁇ 2; identifies a background region and a moving object in the n-frame image; and synthesizes the target photo according to the background region and the moving object, the target
  • the photo includes images of at least two different motion states of the same moving object on the same background area; It is more cumbersome and professional, and the average user can't take the problem of high-quality motion track photos; it can achieve the effect of high-quality motion track photos without the user's cumbersome operation during the shooting process.
  • the exemplary embodiment further obtains a target background region by merging the background regions in the n-frame image according to the intersection of the background regions, and synthesizes the motion trajectory photos according to the target background region and the at least two images of the same moving object, so as to generate motion.
  • the effect of the track panorama is not limited to:
  • FIG. 10 is a block diagram showing the structure of a photo obtaining apparatus according to an exemplary embodiment, which may be implemented as part or all of an electronic device having image processing capability by software, hardware, or a combination of both.
  • the photo acquisition device can include:
  • the image acquisition module 1020 is configured to acquire an n-frame image, n ⁇ 2;
  • the image recognition module 1040 is configured to identify a background area and a moving object in the n-frame image
  • the photo composition module 1060 is configured to synthesize a target photo based on the background area and the moving object, the target photo including images of at least two different motion states of the same moving object on the same background area.
  • the photo acquisition apparatus acquires an n-frame image, n ⁇ 2; identifies a background area and a moving object in the n-frame image; and synthesizes the target photo according to the background area and the moving object, the target
  • the photograph includes images of at least two different motion states of the same moving object located on the same background area; solving the related art problem that the ordinary user cannot photograph the high-quality motion track due to the cumbersome operation and professionalism; No need for users to carry out cumbersome operations, but also to capture the effect of high-quality motion track photos.
  • FIG. 11 is a block diagram showing the structure of a photo obtaining apparatus according to another exemplary embodiment, which may be implemented as part or all of an electronic device having image processing capability by software, hardware, or a combination of both.
  • the photo acquisition device can include:
  • the image acquisition module 1020 is configured to acquire an n-frame image, n ⁇ 2;
  • the image recognition module 1040 is configured to identify a background area and a moving object in the n-frame image
  • the photo composition module 1060 is configured to synthesize a target photo based on the background area and the moving object, the target photo including images of at least two different motion states of the same moving object on the same background area.
  • the image obtaining module 1020 includes:
  • the first photographing sub-module 1021 is configured to take an n-frame image by shooting in a fast continuous shooting mode, which is a mode of capturing one image every predetermined time interval.
  • the image obtaining module 1020 includes:
  • a second shooting sub-module 1022 configured to capture a video
  • the image extraction sub-module 1023 is configured to extract n frames of images from the video.
  • the device further includes:
  • Detecting the stationary module 1010 configured to detect whether the electronic device is currently in a stationary state
  • the image acquisition module 1020 is configured to perform the step of acquiring an n-frame image when detecting that the stationary module detects that the electronic device is currently in a stationary state.
  • detecting the stationary module 1010 includes:
  • the first detecting sub-module 1011 is configured to acquire sensor data collected by a sensor disposed on the electronic device, the sensor includes a gravity acceleration sensor and/or a gyroscope and/or an electronic compass sensor; detecting whether the sensor data changes, the sensor data Characterizing the electronic device to be in a stationary state when there is no change;
  • the second detecting sub-module 1012 is configured to detect whether a background area collected by the image sensor in the electronic device changes, and the electronic device is in a stationary state when the background area does not change.
  • the image recognition module 1040 includes:
  • a background recognition sub-module 1041 configured to identify a background area in the n-frame image
  • the speed detecting sub-module 1042 is configured to detect a moving object whose moving speed reaches a preset threshold on the background area according to the adjacent image.
  • the photo synthesis module 1060 includes:
  • the same background recognition sub-module 1061 is configured to identify the same background area in the n-frame image
  • the first extraction sub-module 1062 is configured to extract, for the same moving object, at least two images that the moving objects do not overlap each other in the n-frame image, or extract at least the overlapping portion of the moving object in the n-frame image does not exceed a predetermined threshold. Two images;
  • the first generation sub-module 1063 is configured to synthesize a target photo based on the same background area and at least two images of the same moving object.
  • the photo synthesis module 1060 includes:
  • the background splicing sub-module 1064 is configured to splicing the target background area according to the background area in which the intersection exists in the n-frame image;
  • the second extraction sub-module 1065 is configured to extract, for the same moving object, at least two images that the moving objects do not overlap each other in the n-frame image, or extract at least the overlapping portion of the moving object in the n-frame image does not exceed a predetermined threshold. Two images;
  • the second generation sub-module 1066 is configured to synthesize the target photo according to the target background area and at least two images of the same moving object.
  • the photo acquisition apparatus acquires an n-frame image, n ⁇ 2; identifies a background area and a moving object in the n-frame image; and synthesizes the target photo according to the background area and the moving object, the target
  • the photograph includes images of at least two different motion states of the same moving object located on the same background area; solving the related art problem that the ordinary user cannot photograph the high-quality motion track due to the cumbersome operation and professionalism; No need for users to carry out cumbersome operations, but also to capture the effect of high-quality motion track photos.
  • the present exemplary embodiment also detects by detecting whether the electronic device is in a stationary state, and acquires an n-frame image when the electronic device is in a stationary state, ensuring the quality of the generated motion track photo.
  • the present exemplary embodiment further solves the problem by extracting at least two images in which the moving objects do not overlap each other in the n-frame image, or extracting at least two images in which the overlapping portion of the moving object does not exceed a predetermined threshold in the n-frame image.
  • the problem of serious image overlap in the motion picture has improved the quality of the generated motion picture.
  • FIG. 12 is a block diagram of a photo capture device 1200, according to an exemplary embodiment.
  • device 1600 can be an electronic device or the like having image processing capabilities.
  • apparatus 1200 can include one or more of the following components: processing component 1202, memory 1204, power component 1206, multimedia component 1208, audio component 1210, input/output (I/O) interface 1212, sensor component 1214, And a communication component 1216.
  • Processing component 1202 typically controls the overall operation of device 1200, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations.
  • Processing component 1202 can include one or more processors 1220 to execute instructions to perform all or part of the steps described above.
  • processing component 1202 can include one or more modules to facilitate interaction between component 1202 and other components.
  • processing component 1202 can include a multimedia module to facilitate interaction between multimedia component 1208 and processing component 1202.
  • Memory 1204 is configured to store various types of data to support operation at device 1200. Examples of such data include instructions for any application or method operating on device 1200, contact data, phone book data, messages, pictures, videos, and the like.
  • the memory 1204 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read only memory (EEPROM), erasable Programmable Read Only Memory (EPROM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), Magnetic Memory, flash memory, disk or CD.
  • SRAM static random access memory
  • EEPROM electrically erasable programmable read only memory
  • EPROM erasable Programmable Read Only Memory
  • PROM Programmable Read Only Memory
  • ROM Read Only Memory
  • Magnetic Memory flash memory, disk or CD.
  • Power component 1206 provides power to various components of device 1200.
  • Power component 1206 can include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power for device 1200.
  • Multimedia component 1208 includes a screen between the device 1200 and a user that provides an output interface.
  • the screen can include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen can be implemented as a touch screen to receive input signals from the user.
  • the touch panel includes one or more touch sensors to sense touches, slides, and gestures on the touch panel. The touch sensor may sense not only the boundary of the touch or sliding action, but also the duration and pressure associated with the touch or slide operation.
  • the multimedia component 1208 includes a front camera and/or a rear camera. When the device 1200 is in an operation mode, such as a shooting mode or a video mode, the front camera and/or the rear camera can receive external multimedia data. Each front and rear camera can be a fixed optical lens system or have focal length and optical zoom capabilities.
  • the audio component 1210 is configured to output and/or input an audio signal.
  • audio component 1210 includes a microphone (MIC) that is configured to receive an external audio signal when device 1200 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode.
  • the received audio signal may be further stored in memory 1204 or transmitted via communication component 1216.
  • audio component 1210 also includes a speaker for outputting an audio signal.
  • the I/O interface 1212 provides an interface between the processing component 1202 and the peripheral interface module, which may be a keyboard, a click wheel, a button, or the like. These buttons may include, but are not limited to, a home button, a volume button, a start button, and a lock button.
  • Sensor assembly 1214 includes one or more sensors for providing status assessment of various aspects to device 1200.
  • sensor assembly 1214 can detect an open/closed state of device 1200, relative positioning of components, such as the display and keypad of device 1200, and sensor component 1214 can also detect changes in position of one component of device 1200 or device 1200. The presence or absence of contact by the user with the device 1200, the orientation or acceleration/deceleration of the device 1200 and the temperature change of the device 1200.
  • Sensor assembly 1214 can include a proximity sensor configured to detect the presence of nearby objects without any physical contact.
  • Sensor assembly 1214 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications.
  • the sensor assembly 1214 can also include an acceleration sensor, a gyro sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
  • Communication component 1216 is configured to facilitate wired or wireless communication between device 1200 and other devices.
  • the device 1200 can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof.
  • communication component 1216 receives broadcast signals or broadcast associated information from an external broadcast management system via a broadcast channel.
  • the communication component 1216 also includes a near field communication (NFC) module to facilitate short range communication.
  • NFC near field communication
  • the NFC module can be based on radio frequency identification (RFID) technology, the Infrared Data Association (IrDA) technology.
  • IrDA Infrared Data Association
  • UWB ultra-wideband
  • Bluetooth Bluetooth
  • device 1200 may be implemented by one or more application specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable A gate array (FPGA), controller, microcontroller, microprocessor, or other electronic component implementation for performing the above methods.
  • ASICs application specific integrated circuits
  • DSPs digital signal processors
  • DSPDs digital signal processing devices
  • PLDs programmable logic devices
  • FPGA field programmable A gate array
  • controller microcontroller, microprocessor, or other electronic component implementation for performing the above methods.
  • non-transitory computer readable storage medium comprising instructions, such as a memory 1204 comprising instructions executable by processor 1220 of apparatus 1200 to perform the above method.
  • the non-transitory computer readable storage medium may be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, and an optical data storage device.
  • a non-transitory computer readable storage medium when instructions in the storage medium are executed by a processor of the apparatus 1200, enables the apparatus 1200 to perform an electronic device photo acquisition method applied to an image processing capability.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Studio Devices (AREA)
  • Image Processing (AREA)
  • Image Analysis (AREA)

Abstract

本公开是关于一种照片获取方法及装置,属于图像处理领域。所述方法包括:获取n帧图像,n≥2;识别所述n帧图像中的背景区域和运动物体;根据所述背景区域和所述运动物体合成目标照片,所述目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。本公开解决相关技术中由于操作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片的问题;达到了拍摄过程中无需用户进行繁琐的操作,也能拍摄出高质量的运动轨迹照片的效果。

Description

照片获取方法及装置
相关申请的交叉引用
本申请基于申请号为CN 201410438203.9、申请日为2014年8月29日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此引入本申请作为参考。
技术领域
本公开涉及图像处理领域,特别涉及一种照片获取方法及装置。
背景技术
运动轨迹照片是一种能够显示出运动物体的运动轨迹的照片。运动轨迹照片能够带给用户一种新奇的视觉效果。
相关技术中通常由用户采用专业的拍摄技巧来拍摄运动轨迹,拍摄过程大多需要三脚架来固定相机,并根据运动物体的运动速度来配合相应的快门速度进行拍摄,才能得到高质量的运动轨迹照片。但是由于操作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片。
发明内容
为了解决相关技术中由于操作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片的问题,本公开实施例提供了一种照片获取方法及装置,所述技术方案如下:
根据本公开实施例的第一方面,提供一种照片获取方法,所述方法包括:
获取n帧图像,n≥2;
识别n帧图像中的背景区域和运动物体;
根据背景区域和运动物体合成目标照片,目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。
在一个实施例中,获取n帧图像,包括:
通过快速连拍模式拍摄得到n帧图像,快速连拍模式是每隔预定时间间隔拍摄一张图像的模式。
在一个实施例中,获取n帧图像,包括:
拍摄视频;
从视频中提取出n帧图像。
在一个实施例中,该方法,还包括:
检测电子设备当前是否处于静止状态;
若电子设备当前处于静止状态,则执行获取n帧图像的步骤。
在一个实施例中,检测电子设备当前是否处于静止状态,包括:
获取设置在电子设备上的传感器所采集的传感器数据,传感器包括重力加速度传感器和/或陀螺仪和/或电子罗盘传感器;检测传感器数据是否发生变化,传感器数据未发生变化时表征电子设备处于静止状态;
和/或,
检测电子设备中的图像传感器所采集的背景区域是否发生变化,背景区域不发生变化时表征电子设备处于静止状态。
在一个实施例中,识别n帧图像中的背景区域和运动物体,包括:
识别n帧图像中的背景区域;
根据相邻图像检测在背景区域上运动速度达到预设阈值的运动物体。
在一个实施例中,根据背景区域和运动物体合成目标照片,包括:
识别n帧图像中相同的背景区域;
对于同一运动物体,提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像;
根据相同的背景区域和同一运动物体的至少两个影像合成目标照片。
在一个实施例中,根据背景区域和运动物体合成目标照片,包括:
根据n帧图像中存在交集的背景区域拼接得到目标背景区域;
对于同一运动物体,提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像;
根据目标背景区域和同一运动物体的至少两个影像合成目标照片。
根据本公开实施例的第二方面,提供一种照片获取装置,所述装置包括:
图像获取模块,被配置为获取n帧图像,n≥2;
图像识别模块,被配置为识别n帧图像中的背景区域和运动物体;
照片合成模块,被配置为根据背景区域和运动物体合成目标照片,目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。
在一个实施例中,图像获取模块,包括:
第一拍摄子模块,被配置为通过快速连拍模式拍摄得到n帧图像,快速连拍模式是每隔预定时间间隔拍摄一张图像的模式。
在一个实施例中,图像获取模块,包括:
第二拍摄子模块,被配置为拍摄视频;
图像提取子模块,被配置为从视频中提取出n帧图像。
在一个实施例中,该装置,还包括:
检测静止模块,被配置为检测电子设备当前是否处于静止状态;
图像获取模块,被配置为当检测静止模块检测出电子设备当前处于静止状态时,执行获取n帧图像的步骤。
在一个实施例中,检测静止模块,包括:
第一检测子模块,被配置为获取设置在电子设备上的传感器所采集的传感器数据,传感器包括重力加速度传感器和/或陀螺仪和/或电子罗盘传感器;检测传感器数据是否发生变化,传感器数据未发生变化时表征电子设备处于静止状态;
和/或,
第二检测子模块,被配置为检测电子设备中的图像传感器所采集的背景区域是否发生变化,背景区域不发生变化时表征电子设备处于静止状态。
在一个实施例中,图像识别模块,包括:
背景识别子模块,被配置为识别n帧图像中的背景区域;
速度检测子模块,被配置为根据相邻图像检测在背景区域上运动速度达到预设阈值的运动物体。
在一个实施例中,照片合成模块,包括:
相同背景识别子模块,被配置为识别n帧图像中相同的背景区域;
第一提取自模块,被配置为对于同一运动物体,提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像;
第一生成子模块,被配置为根据相同的背景区域和同一运动物体的至少两个影像合成目标照片。
在一个实施例中,照片合成模块,包括:
背景拼接子模块,被配置为根据n帧图像中存在交集的背景区域拼接得到目标背景区域;
第二提取子模块,被配置为对于同一运动物体,提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像;
第二生成子模块,被配置为根据目标背景区域和同一运动物体的至少两个影像合成目标照片。
本公开实施例提供的技术方案可以包括以下有益效果:
通过获取n帧图像,n≥2;识别n帧图像中的背景区域和运动物体;根据背景区域和运 动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像;解决相关技术中由于操作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片的问题;达到了拍摄过程中无需用户进行繁琐的操作,也能拍摄出高质量的运动轨迹照片的效果。
应当理解的是,以上的一般描述和后文的细节描述仅是示例性和解释性的,并不能限制本公开。
附图说明
此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本公开的实施例,并与说明书一起用于解释本公开的原理。
图1是根据一示例性实施例示出的照片获取方法的方法流程图;
图2是根据另一示例性实施例示出的照片获取方法的方法流程图;
图3是根据另一示例性实施例示出的照片获取方法的实施示意图;
图4是根据另一示例性实施例示出的照片获取方法的实施示意图;
图5是根据另一示例性实施例示出的照片获取方法的实施示意图;
图6是根据另一示例性实施例示出的照片获取方法的实施示意图;
图7是根据另一示例性实施例示出的照片获取方法的实施示意图;
图8是根据另一示例性实施例示出的照片获取方法的方法流程图;
图9是根据另一示例性实施例示出的照片获取方法的实施示意图;
图10是根据一示例性实施例示出的照片获取装置的结构方框图;
图11是根据另一示例性实施例示出的照片获取装置的结构方框图;
图12是根据一示例性实施例示出的一种电子设备的结构方框图。
通过上述附图,已示出本公开明确的实施例,后文中将有更详细的描述。这些附图和文字描述并不是为了通过任何方式限制本公开构思的范围,而是通过参考特定实施例为本领域技术人员说明本公开的概念。
具体实施方式
这里将详细地对示例性实施例进行说明,其示例表示在附图中。下面的描述涉及附图时,除非另有表示,不同附图中的相同数字表示相同或相似的要素。以下示例性实施例中所描述的实施方式并不代表与本公开相一致的所有实施方式。相反,它们仅是与如所附权利要求书中所详述的、本公开的一些方面相一致的装置和方法的例子。
本发明各个实施例提供的照片获取方法,可以由具有图像处理能力和图像拍摄能力的电 子设备来实现。该电子设备可以是智能手机、平板电脑、电子书阅读器和膝上型便携计算机(相机、摄像机)等等。
为了简化描述,下文中仅以照片获取方法由具有图像处理能力和图像拍摄能力的电子设备执行来举例说明,但对此不构成限定。
图1是根据一示例性实施例示出的照片获取方法的方法流程图,本实施例以该照片获取方法用于具有图像处理能力和图像拍摄能力的电子设备中来进行说明,该照片获取方法可以包括如下步骤。
在步骤102中,获取n帧图像,n≥2。
在步骤104中,识别n帧图像中的背景区域和运动物体。
在步骤106中,根据背景区域和运动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。
综上所述,本示例性实施例提供的照片获取方法,通过获取n帧图像,n≥2;识别n帧图像中的背景区域和运动物体;根据背景区域和运动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像;解决了由于操作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片;达到了拍摄过程中无需用户进行繁琐的操作,也能拍摄出高质量的运动轨迹照片的效果。
图2是根据一示例性实施例示出的照片获取方法的方法流程图,本实施例以该照片获取方法用于具有图像处理能力和图像拍摄能力的电子设备中来进行说明。该照片获取方法可以包括如下步骤:
在步骤201中,检测电子设备当前是否处于静止状态。
当电子设备开启拍摄功能时,电子设备会检测其当前是否处于静止状态,步骤201可以由下述两种方式中的任意一种或两种的组合进行实现。
第一种,电子设备获取设置在电子设备上的传感器所采集的传感器数据,传感器包括重力加速度传感器和/或陀螺仪和/或电子罗盘传感器;电子设备检测传感器数据是否发生变化,传感器数据未发生变化时表征电子设备处于静止状态
第二种,电子设备检测电子设备中的图像传感器所采集的背景区域是否发生变化,背景区域不发生变化时表征电子设备处于静止状态。
当两种方式结合实施时,可以先执行第一种检测方式,在传感器数据未发生变化时,再执行第二种检测方式。
当检测结果为该电子设备处于静止状态时,进入步骤202,当该电子设备处于非静止状态时,重复步骤201。
在步骤202中,当该电子设备处于静止状态时,获取n帧图像,n≥2。
在当前电子设备处于静止状态时,获取n帧图像。步骤202可以包括如下子步骤:
一、电子设备首先拍摄视频;
二、电子设备从该视频中提取出n帧图像。
电子设备可以提取该视频中的每帧图像帧,得到n帧图像。该n帧图像通常是按照拍摄时间从前到后排列,具有相同或相似背景区域的图像。电子设备也可以按照每隔预定帧提取一帧图像帧的方式,提取视频中的图像帧,获取n帧图像。
比如,该视频共24帧,电子设备可以提取每一帧图像帧,总共提取24帧图像;电子设备也可以按照每隔4帧提取一帧图像帧的方式,总共提取6帧图像。
作为另一种可能的实现方式,电子设备也可以通过快速连拍模式拍摄得到n帧图像,快速连拍模式是每隔预定时间间隔拍摄一张图像的模式。
在步骤203中,识别n帧图像中的背景区域。
电子设备需要识别n帧图像中的背景区域。可选地,步骤203可以包括如下子步骤:
一、电子设备对相邻两帧图像做差分运算得到差分图像;
由于背景区域中的像素点的灰度和位置通常不会发生改变,因此电子设备通过对相邻两帧图像做差分运算得到的差分图像即运动物体的图像。
二、电子设备将两帧图像分别与该差分图像做差分运算,得到两帧图像对应的背景图像。
由于得到的差分图像即运动物体的图像,所以将两帧图像分别与差分图像做差分算法,电子设备即可得到两帧图像对应的背景图像。
需要说明的是,上述方式仅为示例性说明,本实施例对电子设备如何识别n帧图像的背景区域不做限定。
在步骤204中,根据相邻图像检测在背景区域上运动速度达到预设阈值的运动物体。
当运动物体的运动速度过低时,在生成的运动轨迹照片中将会出现较多运动物体的影像,导致运动物体影像的覆盖,影响运动轨迹照片的质量。其中,运动物体的影像是运动物体在图像中所对应的区域。作为可选步骤,电子设备可以对运动物体的运动速度进行检测。步骤204可以包括如下子步骤:
一、电子设备识别n帧图像中的运动物体;
电子设备首先根据前景检测技术和/或运动目标检测技术检测出n帧图像中的运动物体。
二、对于任一运动物体,电子设备获取一帧图像帧中该运动物体的影像上的一个像 素点的坐标;
比如,如图3所示,获取图像帧31中运动物体的影像32上的像素点33的坐标。
三、电子设备获取该图像帧的相邻图像帧中运动物体的影像上对应像素点的坐标;
比如,如图3所示,获取图像帧31相邻的图像帧34中运动物体的影像35上对应的像素点36的坐标。
四、电子设备根据两个坐标的差值,计算运动物体的速度。
电子设备计算像素点35和对应像素点36的坐标的差值,根据该差值和相邻图像帧的时间差,计算出运动物体的速度。
电子设备将计算出的运动物体的速度与预设阈值进行比较,当该运动物体的速度大于等于预设阈值时,则该运动物体为背景区域上运动速度达到预设阈值的运动物体。
在步骤205中,识别n帧图像中相同的背景区域。
由于n帧图像是在静止状态下拍摄的,所以这n帧图像具有相同或相似的背景区域。电子设备在识别出n帧图像的背景区域之后,还可以识别出n帧图像中相同的背景区域,将该背景区域作为即将生成的运动轨迹图片的背景区域。
如图4所示,共5帧图像,由于背景区域中的像素点的灰度和位置不会发生改变,因此通过对图像做差分运算,电子设备可以识别出图像中的背景区域41。
在步骤206中,对于同一运动物体,提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像。
作为本步骤的一种可能实现,运动物体在n帧图像中的影像可能会出现重叠,影响生成的运动轨迹照片的质量,因此电子设备需要提取n帧图像中互不重叠的影像,步骤206可以包括如下步骤:
一、电子设备分别获取运动物体在两帧图像中影像对应的坐标集合;
如图5所示,电子设备获取图像51中运动物体影像52的坐标集合A,获取图像53中运动物体影像54的坐标集合B。
二、电子设备检测两个坐标集合中是否存在相同的坐标;若存在,表征两个影像重叠,弃用其中1个影像;若不存在,则同时采用2个影像。
如图5所示,电子设备检测坐标集合A合坐标集合B是否存在相同的坐标,比如坐标结合A和坐标集合B不存在相同的坐标,即表征运动物体影像52和运动物体影像54不重叠。
作为本步骤的另一种可能实现,当运动物体在n帧图像中重叠部分较小时,也不会影响生成的运动轨迹照片的质量。因此,电子设备可以提取运动物体在n帧图像中重叠部分不超 过预定阈值的至少两个影像,其子步骤可以如下:
一、电子设备分别获取运动物体在两帧图像中影像对应的坐标集合;
如图6所示,电子设备获取图像61中运动物体影像62的坐标集合A,获取图像63中运动物体影像64的坐标集合B。
二、电子设备计算两个坐标集合中相同坐标所占的比例;
获取两个坐标集合中相同坐标的个数,并计算相同坐标在坐标集合中所占的比例。
三、当该比例小于或等于预设阈值时,电子设备提取运动物体在两帧图像中的影像。
如图6所示,预设的阀值为10%,运动物体影像62的坐标集合A和运动物体影像64的坐标集合B中相同坐标所占的比例为5%,则电子设备提取运动物体影像72和运动物体影像64。当然,如果该比例大于预设阈值时,电子设备提取运动物体在两帧图像中的1个影像,弃用另一个影像。
在步骤207中,根据相同的背景区域和同一运动物体的至少两个影像合成目标照片。
电子设备根据步骤208中识别出的n帧图像中相同的背景区域,步骤207中提取的同一运动物体的至少两个影像,合成目标照片,即运动轨迹照片。
如图7所示,电子设备识别出的5帧图像中相同的背景区域81,电子设备提取的同一运动物体的5个影像72,最后根据背景区域71和5个影像72,合成目标照片73。
此处的运动物体可以是电子设备在步骤204中选择出的运动速度超过预定阈值的运动物体。在合成过程中,电子设备首先将相同的背景区域作为目标照片的背景区域。然后对于同一运动物体的不同影像,电子设备根据每个影像在n帧图像中与背景区域的原始相对位置,将该影像复制到该相同的背景区域中相应的位置中,最终合成得到目标照片。
综上所述,本示例性实施例提供的照片获取方法,通过获取n帧图像,n≥2;识别n帧图像中的背景区域和运动物体;根据背景区域和运动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像;解决相关技术中由于操作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片的问题;达到了拍摄过程中无需用户进行繁琐的操作,也能拍摄出高质量的运动轨迹照片的效果。
本示例性实施例还通过对电子设备是否处于静止状态进行检测,当电子设备处于静止状态时,才会获取n帧图像,保证了生成的运动轨迹照片的质量。
本示例性实施例还通过提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像,解决了生成的运动轨迹图片中影像重叠严重的问题,提高了生成的运动轨迹图片的质量。
在实施过程中,如果n帧图像的背景不是完全相同,而是互相有较大的交集,电子设备还可以通过对存在交集的背景区域进行拼接,得到类似于全景照片的目标背景区域,然后根据该目标背景区域和同一运动物体的至少两个影像合成运动轨迹照片,下面将采用一示例性实施例进行说明。
图8是根据一示例性实施例示出的照片获取方法的方法流程图。本实施例继续以该照片获取方法用于具有图像处理能力和图像拍摄能力的电子设备中来进行说明。该照片获取方法可以包括如下步骤:
在步骤801中,获取n帧图像,n≥2。
在当前电子设备处于静止状态时,获取n帧图像。步骤202可以包括如下子步骤:
一、电子设备首先拍摄视频;
二、电子设备从该视频中提取出n帧图像。
电子设备可以提取该视频中的每帧图像帧,得到n帧图像。该n帧图像通常是按照拍摄时间从前到后排列,具有相同或相似背景区域的图像。电子设备也可以按照每隔预定帧提取一帧图像帧的方式,提取视频中的图像帧,获取n帧图像。
比如,该视频共24帧,电子设备可以提取每一帧图像帧,总共提取24帧图像;电子设备也可以按照每隔4帧提取一帧图像帧的方式,总共提取6帧图像。
作为另一种可能的实现方式,电子设备也可以通过快速连拍模式拍摄得到n帧图像,快速连拍模式是每隔预定时间间隔拍摄一张图像的模式。
在步骤802中,识别n帧图像中的背景区域。
电子设备需要识别n帧图像中的背景区域。可选地步骤802可以包括如下子步骤:
一、电子设备对相邻两帧图像做差分运算得到差分图像;
由于背景区域中的像素点的灰度和位置通常不会发生改变,因此电子设备通过对相邻两帧图像做差分运算得到的差分图像即运动物体的图像。
二、电子设备将两帧图像分别与该差分图像做差分运算,得到两帧图像对应的背景图像。
由于得到的差分图像即运动物体的图像,所以将两帧图像分别与差分图像做差分算法,电子设备即可得到两帧图像对应的背景图像。
需要说明的是,上述方式仅为示例性说明,本实施例对电子设备如何识别n帧图像的背景区域不做限定。
在步骤803中,根据相邻图像检测在背景区域上运动速度达到预设阈值的运动物体。
当运动物体的运动速度过低时,在生成的运动轨迹照片中将会出现较多运动物体的影像,导致运动物体影像的覆盖,影响运动轨迹照片的质量。其中,运动物体的影像是运动物 体在图像中所对应的区域。作为可选步骤,电子设备可以对运动物体的运动速度进行检测。步骤803可以包括如下子步骤:
一、电子设备识别n帧图像中的运动物体;
电子设备首先根据前景检测技术和/或运动目标检测技术检测出n帧图像中的运动物体。
二、对于任一运动物体,电子设备获取一帧图像帧中该运动物体的影像上的一个像素点的坐标;
比如,如图3所示,获取图像帧31中运动物体的影像32上的像素点33的坐标。
三、电子设备获取该图像帧的相邻图像帧中运动物体的影像上对应像素点的坐标;
比如,如图3所示,获取图像帧31相邻的图像帧34中运动物体的影像35上对应的像素点36的坐标。
四、电子设备根据两个坐标的差值,计算运动物体的速度。
电子设备计算像素点35和对应像素点36的坐标的差值,根据该差值和相邻图像帧的时间差,计算出运动物体的速度。
电子设备将计算出的运动物体的速度与预设阈值进行比较,当该运动物体的速度大于等于预设阈值时,则该运动物体为背景区域上运动速度达到预设阈值的运动物体。
在步骤804中,根据n帧图像中存在交集的背景区域拼接得到目标背景区域。
由于n帧图像可能是在非静止状态下或者相对静止状态(比如在乘车时)拍摄的,所以这n帧图像对应的背景区域可能不完全相同。当n帧图像对应的背景区域不完全相同,但存在交集区域时,电子设备可以根据该交集区域,将背景区域进行拼接,得到目标背景区域。
如图9所示,图像91、图像92和图像93对应的背景区域94相同,图像95和图像96对应的背景区域97相同,但是背景区域94和背景区域97不完全相同。其中背景区域94和背景区域97存在交集区域98,电子设备将根据该交集区域94将对背景区域97和背景区域98进行拼接,得到目标背景区域99。
在步骤805中,对于同一运动物体,提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像。
作为本步骤的一种可能实现,运动物体在n帧图像中的影像可能会出现重叠,影响生成的运动轨迹照片的质量,因此电子设备需要提取n帧图像中互不重叠的影像,步骤805可以包括如下步骤:
一、电子设备分别获取运动物体在两帧图像中影像对应的坐标集合;
如图5所示,电子设备获取图像51中运动物体影像52的坐标集合A,获取图像53中运动物体影像54的坐标集合B。
二、电子设备检测两个坐标集合中是否存在相同的坐标,若存在,表征两个影像重叠,弃用其中1个影像;若不存在,则同时采用2个影像。
如图5所示,电子设备检测坐标集合A合坐标集合B是否存在相同的坐标,比如坐标结合A和坐标集合B不存在相同的坐标,即表征运动物体影像52和运动物体影像54不重叠。
作为本步骤的另一种可能实现,当运动物体在n帧图像中重叠部分较小时,也不会影响生成的运动轨迹照片的质量。因此,电子设备可以提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像,其子步骤可以如下:
一、电子设备分别获取运动物体在两帧图像中影像对应的坐标集合;
如图6所示,电子设备获取图像61中运动物体影像62的坐标集合A,获取图像63中运动物体影像64的坐标集合B。
二、电子设备计算两个坐标集合中相同坐标所占的比例;
获取两个坐标集合中相同坐标的个数,并计算相同坐标在坐标集合中所占的比例。
三、当该比例小于或等于预设阈值时,电子设备提取运动物体在两帧图像中的影像。
如图6所示,预设的阀值为10%,运动物体影像62的坐标集合A和运动物体影像64的坐标集合B中相同坐标所占的比例为5%,则提取运动物体影像72和运动物体影像64。当然,如果该比例大于预设阈值时,电子设备提取运动物体在两帧图像中的1个影像,弃用另一个影像。
在步骤806中,根据目标背景区域和同一运动物体的至少两个影像合成目标照片。
电子设备根据步骤804中拼接得到的目标背景区域,步骤805中电子设备提取的同一运动物体的至少两个影像,合成目标照片,即运动轨迹照片。
此处的运动物体可以是电子设备在步骤803中选择出的运动速度超过预定阈值的运动物体。在合成过程中,电子设备首先将目标背景区域作为目标照片的背景区域。然后对于同一运动物体的不同影像,电子设备根据每个影像在n帧图像中与背景区域的原始相对位置,将该影像复制到该目标背景区域中相应的位置中,最终合成得到目标照片。
如图7所示,电子设备通过对存在交集的背景区域进行拼接得到目标背景区域71,电子设备提取的同一运动物体的5个影像72,最后根据背景区域71和5个影像72,合成目标照片73。
综上所述,本示例性实施例提供的照片获取方法,通过获取n帧图像,n≥2;识别n帧图像中的背景区域和运动物体;根据背景区域和运动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像;解决相关技术中由于操 作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片的问题;达到了拍摄过程中无需用户进行繁琐的操作,也能拍摄出高质量的运动轨迹照片的效果。
本示例性实施例还通过电子设备根据n帧图像中存在交集的背景区域拼接得到目标背景区域,并根据该目标背景区域和同一运动物体的至少两个影像合成运动轨迹照片,达到了能够生成运动轨迹全景图的效果。
下述为本公开装置实施例,可以用于执行本公开方法实施例。对于本公开装置实施例中未披露的细节,请参照本公开方法实施例。
图10是根据一示例性实施例示出的照片获取装置的结构方框图,该照片获取装置可以通过软件、硬件或者两者的结合实现成为具有图像处理能力的电子设备的部分或者全部。该照片获取装置可以包括:
图像获取模块1020,被配置为获取n帧图像,n≥2;
图像识别模块1040,被配置为识别n帧图像中的背景区域和运动物体;
照片合成模块1060,被配置为根据背景区域和运动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。
综上所述,本示例性实施例提供的照片获取装置,通过获取n帧图像,n≥2;识别n帧图像中的背景区域和运动物体;根据背景区域和运动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像;解决相关技术中由于操作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片的问题;达到了拍摄过程中无需用户进行繁琐的操作,也能拍摄出高质量的运动轨迹照片的效果。
图11是根据另一示例性实施例示出的照片获取装置的结构方框图,该照片获取装置可以通过软件、硬件或者两者的结合实现成为具有图像处理能力的电子设备的部分或者全部。该照片获取装置可以包括:
图像获取模块1020,被配置为获取n帧图像,n≥2;
图像识别模块1040,被配置为识别n帧图像中的背景区域和运动物体;
照片合成模块1060,被配置为根据背景区域和运动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。
可选地,图像获取模块1020,包括:
第一拍摄子模块1021,被配置为通过快速连拍模式拍摄得到n帧图像,快速连拍模式是每隔预定时间间隔拍摄一张图像的模式。
可选地,图像获取模块1020,包括:
第二拍摄子模块1022,被配置为拍摄视频;
图像提取子模块1023,被配置为从视频中提取出n帧图像。
可选地,该装置,还包括:
检测静止模块1010,被配置为检测电子设备当前是否处于静止状态;
图像获取模块1020,被配置为当检测静止模块检测到电子设备当前处于静止状态时,执行获取n帧图像的步骤。
可选地,检测静止模块1010,包括:
第一检测子模块1011,被配置为获取设置在电子设备上的传感器所采集的传感器数据,传感器包括重力加速度传感器和/或陀螺仪和/或电子罗盘传感器;检测传感器数据是否发生变化,传感器数据未发生变化时表征电子设备处于静止状态;
和/或,
第二检测子模块1012,被配置为检测电子设备中的图像传感器所采集的背景区域是否发生变化,背景区域不发生变化时表征电子设备处于静止状态。
可选地,图像识别模块1040,包括:
背景识别子模块1041,被配置为识别n帧图像中的背景区域;
速度检测子模块1042,被配置为根据相邻图像检测在背景区域上运动速度达到预设阈值的运动物体。
可选地,照片合成模块1060,包括:
相同背景识别子模块1061,被配置为识别n帧图像中相同的背景区域;
第一提取子模块1062,被配置为对于同一运动物体,提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像;
第一生成子模块1063,被配置为根据相同的背景区域和同一运动物体的至少两个影像合成目标照片。
可选地,照片合成模块1060,包括:
背景拼接子模块1064,被配置为根据n帧图像中存在交集的背景区域拼接得到目标背景区域;
第二提取子模块1065,被配置为对于同一运动物体,提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像;
第二生成子模块1066,被配置为根据目标背景区域和同一运动物体的至少两个影像合成目标照片。
综上所述,本示例性实施例提供的照片获取装置,通过获取n帧图像,n≥2;识别n帧图像中的背景区域和运动物体;根据背景区域和运动物体合成目标照片,该目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像;解决相关技术中由于操作较为繁琐和专业,普通用户无法拍摄出高质量的运动轨迹照片的问题;达到了拍摄过程中无需用户进行繁琐的操作,也能拍摄出高质量的运动轨迹照片的效果。
本示例性实施例还通过检测电子设备是否处于静止状态进行检测,当电子设备处于静止状态时,才会获取n帧图像,保证了生成的运动轨迹照片的质量。
本示例性实施例还通过提取运动物体在n帧图像中互不重叠的至少两个影像,或,提取运动物体在n帧图像中重叠部分不超过预定阈值的至少两个影像,解决了生成的运动轨迹图片中影像重叠严重的问题,提高了生成的运动轨迹图片的质量。
关于上述实施例中的装置,其中各个模块执行操作的具体方式已经在有关该方法的实施例中进行了详细描述,此处将不做详细阐述说明。
图12是根据一示例性实施例示出的照片获取装置1200的框图。例如,装置1600可以是具有图像处理能力的电子设备等。
参照图12,装置1200可以包括以下一个或多个组件:处理组件1202,存储器1204,电源组件1206,多媒体组件1208,音频组件1210,输入/输出(I/O)的接口1212,传感器组件1214,以及通信组件1216。
处理组件1202通常控制装置1200的整体操作,诸如与显示,电话呼叫,数据通信,相机操作和记录操作相关联的操作。处理组件1202可以包括一个或多个处理器1220来执行指令,以完成上述的方法的全部或部分步骤。此外,处理组件1202可以包括一个或多个模块,便于处理组件1202和其他组件之间的交互。例如,处理组件1202可以包括多媒体模块,以方便多媒体组件1208和处理组件1202之间的交互。
存储器1204被配置为存储各种类型的数据以支持在装置1200的操作。这些数据的示例包括用于在装置1200上操作的任何应用程序或方法的指令,联系人数据,电话簿数据,消息,图片,视频等。存储器1204可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁 存储器,快闪存储器,磁盘或光盘。
电源组件1206为装置1200的各种组件提供电力。电源组件1206可以包括电源管理系统,一个或多个电源,及其他与为装置1200生成、管理和分配电力相关联的组件。
多媒体组件1208包括在所述装置1200和用户之间的提供一个输出接口的屏幕。在一些实施例中,屏幕可以包括液晶显示器(LCD)和触摸面板(TP)。如果屏幕包括触摸面板,屏幕可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。在一些实施例中,多媒体组件1208包括一个前置摄像头和/或后置摄像头。当装置1200处于操作模式,如拍摄模式或视频模式时,前置摄像头和/或后置摄像头可以接收外部的多媒体数据。每个前置摄像头和后置摄像头可以是一个固定的光学透镜系统或具有焦距和光学变焦能力。
音频组件1210被配置为输出和/或输入音频信号。例如,音频组件1210包括一个麦克风(MIC),当装置1200处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器1204或经由通信组件1216发送。在一些实施例中,音频组件1210还包括一个扬声器,用于输出音频信号。
I/O接口1212为处理组件1202和外围接口模块之间提供接口,上述外围接口模块可以是键盘,点击轮,按钮等。这些按钮可包括但不限于:主页按钮、音量按钮、启动按钮和锁定按钮。
传感器组件1214包括一个或多个传感器,用于为装置1200提供各个方面的状态评估。例如,传感器组件1214可以检测到装置1200的打开/关闭状态,组件的相对定位,例如所述组件为装置1200的显示器和小键盘,传感器组件1214还可以检测装置1200或装置1200一个组件的位置改变,用户与装置1200接触的存在或不存在,装置1200方位或加速/减速和装置1200的温度变化。传感器组件1214可以包括接近传感器,被配置用来在没有任何的物理接触时检测附近物体的存在。传感器组件1214还可以包括光传感器,如CMOS或CCD图像传感器,用于在成像应用中使用。在一些实施例中,该传感器组件1214还可以包括加速度传感器,陀螺仪传感器,磁传感器,压力传感器或温度传感器。
通信组件1216被配置为便于装置1200和其他设备之间有线或无线方式的通信。装置1200可以接入基于通信标准的无线网络,如WiFi,2G或3G,或它们的组合。在一个示例性实施例中,通信组件1216经由广播信道接收来自外部广播管理系统的广播信号或广播相关信息。在一个示例性实施例中,所述通信组件1216还包括近场通信(NFC)模块,以促进短程通信。例如,在NFC模块可基于射频识别(RFID)技术,红外数据协会(IrDA)技 术,超宽带(UWB)技术,蓝牙(BT)技术和其他技术来实现。
在示例性实施例中,装置1200可以被一个或多个应用专用集成电路(ASIC)、数字信号处理器(DSP)、数字信号处理设备(DSPD)、可编程逻辑器件(PLD)、现场可编程门阵列(FPGA)、控制器、微控制器、微处理器或其他电子元件实现,用于执行上述方法。
在示例性实施例中,还提供了一种包括指令的非临时性计算机可读存储介质,例如包括指令的存储器1204,上述指令可由装置1200的处理器1220执行以完成上述方法。例如,所述非临时性计算机可读存储介质可以是ROM、随机存取存储器(RAM)、CD-ROM、磁带、软盘和光数据存储设备等。
一种非临时性计算机可读存储介质,当所述存储介质中的指令由装置1200的处理器执行时,使得装置1200能够执行应用于具有图像处理能力的电子设备照片获取方法。
本领域技术人员在考虑说明书及实践这里公开的发明后,将容易想到本公开的其它实施方案。本申请旨在涵盖本公开的任何变型、用途或者适应性变化,这些变型、用途或者适应性变化遵循本公开的一般性原理并包括本公开未公开的本技术领域中的公知常识或惯用技术手段。说明书和实施例仅被视为示例性的,本公开的真正范围和精神由下面的权利要求指出。
应当理解的是,本公开并不局限于上面已经描述并在附图中示出的精确结构,并且可以在不脱离其范围进行各种修改和改变。本公开的范围仅由所附的权利要求来限制。

Claims (17)

  1. 一种照片获取方法,其特征在于,所述方法包括:
    获取n帧图像,n≥2;
    识别所述n帧图像中的背景区域和运动物体;
    根据所述背景区域和所述运动物体合成目标照片,所述目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。
  2. 根据权利要求1所述的方法,其特征在于,所述获取n帧图像,包括:
    通过快速连拍模式拍摄得到所述n帧图像,所述快速连拍模式是每隔预定时间间隔拍摄一张图像的模式。
  3. 根据权利要求1所述的方法,其特征在于,所述获取n帧图像,包括:
    拍摄视频;
    从所述视频中提取出所述n帧图像。
  4. 根据权利要求1至3任一所述的方法,其特征在于,所述方法,还包括:
    检测电子设备当前是否处于静止状态;
    若所述电子设备当前处于静止状态,则执行所述获取n帧图像的步骤。
  5. 根据权利要求4所述的方法,其特征在于,所述检测电子设备当前是否处于静止状态,包括:
    获取设置在所述电子设备上的传感器所采集的传感器数据,所述传感器包括重力加速度传感器和/或陀螺仪和/或电子罗盘传感器;检测所述传感器数据是否发生变化,所述传感器数据未发生变化时表征所述电子设备处于静止状态;
    和/或,
    检测所述电子设备中的图像传感器所采集的背景区域是否发生变化,所述背景区域不发生变化时表征所述电子设备处于静止状态。
  6. 根据权利要求1至3任一所述的方法,其特征在于,所述识别所述n帧图像中的背景区域和运动物体,包括:
    识别所述n帧图像中的背景区域;
    根据所述相邻图像检测在所述背景区域上运动速度达到预设阈值的运动物体。
  7. 根据权利要求1至3任一所述的方法,其特征在于,所述根据所述背景区域和所述运动物体合成目标照片,包括:
    识别所述n帧图像中相同的背景区域;
    对于同一运动物体,提取所述运动物体在所述n帧图像中互不重叠的至少两个影像,或, 提取所述运动物体在所述n帧图像中重叠部分不超过预定阈值的至少两个影像;
    根据所述相同的背景区域和同一运动物体的所述至少两个影像合成所述目标照片。
  8. 根据权利要求1至3任一所述的方法,其特征在于,所述根据所述背景区域和所述运动物体合成目标照片,包括:
    根据所述n帧图像中存在交集的背景区域拼接得到目标背景区域;
    对于同一运动物体,提取所述运动物体在所述n帧图像中互不重叠的至少两个影像,或,提取所述运动物体在所述n帧图像中重叠部分不超过预定阈值的至少两个影像;
    根据所述目标背景区域和同一运动物体的所述至少两个影像合成所述目标照片。
  9. 一种照片获取装置,其特征在于,所述装置包括:
    图像获取模块,被配置为获取n帧图像,n≥2;
    图像识别模块,被配置为识别所述n帧图像中的背景区域和运动物体;
    照片合成模块,被配置为根据所述背景区域和所述运动物体合成目标照片,所述目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。
  10. 根据权利要求9所述的装置,其特征在于,所述图像获取模块,包括:
    第一拍摄子模块,被配置为通过快速连拍模式拍摄得到所述n帧图像,所述快速连拍模式是每隔预定时间间隔拍摄一张图像的模式。
  11. 根据权利要求9所述的装置,其特征在于,所述图像获取模块,包括:
    第二拍摄子模块,被配置为拍摄视频;
    图像提取子模块,被配置为从所述视频中提取出所述n帧图像。
  12. 根据权利要求9至11任一所述的装置,其特征在于,所述装置,还包括:
    检测静止模块,被配置为检测电子设备当前是否处于静止状态;
    所述图像获取模块,被配置为当所述检测静止模块检测到所述电子设备当前处于静止状态时,执行所述获取n帧图像的步骤。
  13. 根据权利要求12所述的装置,其特征在于,所述检测静止模块,包括:
    第一检测子模块,被配置为获取设置在所述电子设备上的传感器所采集的传感器数据,所述传感器包括重力加速度传感器和/或陀螺仪和/或电子罗盘传感器;检测所述传感器数据是否发生变化,所述传感器数据未发生变化时表征所述电子设备处于静止状态;
    和/或,
    第二检测子模块,被配置为检测所述电子设备中的图像传感器所采集的背景区域是否发生变化,所述背景区域不发生变化时表征所述电子设备处于静止状态。
  14. 根据权利要求9至11任一所述的装置,其特征在于,所述图像识别模块,包括:
    背景识别子模块,被配置为识别所述n帧图像中的背景区域;
    速度检测子模块,被配置为根据所述相邻图像检测在所述背景区域上运动速度达到预设阈值的运动物体。
  15. 根据权利要求9至11任一所述的装置,其特征在于,所述照片合成模块,包括:
    相同背景识别子模块,被配置为识别所述n帧图像中相同的背景区域;
    第一提取子模块,被配置为对于同一运动物体,提取所述运动物体在所述n帧图像中互不重叠的至少两个影像,或,提取所述运动物体在所述n帧图像中重叠部分不超过预定阈值的至少两个影像;
    第一生成子模块,被配置为根据所述相同的背景区域和同一运动物体的所述至少两个影像合成所述目标照片。
  16. 根据权利要求9至11任一所述的装置,其特征在于,所述照片合成模块,包括:
    背景拼接子模块,被配置为根据所述n帧图像中存在交集的背景区域拼接得到目标背景区域;
    第二提取子模块,被配置为对于同一运动物体,提取所述运动物体在所述n帧图像中互不重叠的至少两个影像,或,提取所述运动物体在所述n帧图像中重叠部分不超过预定阈值的至少两个影像;
    第二生成子模块,被配置为根据所述目标背景区域和同一运动物体的所述至少两个影像合成所述目标照片。
  17. 一种照片获取装置,其特征在于,包括:
    处理器;
    用于存储所述处理器的可执行指令的存储器;
    其中,所述处理器被配置为:
    获取n帧图像,n≥2;
    识别所述n帧图像中的背景区域和运动物体;
    根据所述背景区域和所述运动物体合成目标照片,所述目标照片包括位于同一背景区域上的同一运动物体的至少两个不同运动状态的影像。
PCT/CN2015/071358 2014-08-29 2015-01-22 照片获取方法及装置 WO2016029641A1 (zh)

Priority Applications (6)

Application Number Priority Date Filing Date Title
JP2016544716A JP6198958B2 (ja) 2014-08-29 2015-01-22 写真を取得するための方法、装置、コンピュータプログラム、及び、コンピュータ可読記憶媒体
BR112015010286A BR112015010286A2 (pt) 2014-08-29 2015-01-22 método e aparelho para obter uma fotografia
RU2015116616A RU2634907C2 (ru) 2014-08-29 2015-01-22 Метод и устройство для получения фотографии
KR1020157011766A KR101772177B1 (ko) 2014-08-29 2015-01-22 사진을 획득하기 위한 방법 및 장치
MX2015005029A MX354121B (es) 2014-08-29 2015-01-22 Método y aparato para obtener una fotografía.
US14/707,186 US9674395B2 (en) 2014-08-29 2015-05-08 Methods and apparatuses for generating photograph

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201410438203.9A CN104243819B (zh) 2014-08-29 2014-08-29 照片获取方法及装置
CN201410438203.9 2014-08-29

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US14/707,186 Continuation US9674395B2 (en) 2014-08-29 2015-05-08 Methods and apparatuses for generating photograph

Publications (1)

Publication Number Publication Date
WO2016029641A1 true WO2016029641A1 (zh) 2016-03-03

Family

ID=52231073

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/071358 WO2016029641A1 (zh) 2014-08-29 2015-01-22 照片获取方法及装置

Country Status (9)

Country Link
US (1) US9674395B2 (zh)
EP (1) EP3010226B1 (zh)
JP (1) JP6198958B2 (zh)
KR (1) KR101772177B1 (zh)
CN (1) CN104243819B (zh)
BR (1) BR112015010286A2 (zh)
MX (1) MX354121B (zh)
RU (1) RU2634907C2 (zh)
WO (1) WO2016029641A1 (zh)

Families Citing this family (34)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104243819B (zh) * 2014-08-29 2018-02-23 小米科技有限责任公司 照片获取方法及装置
US9727949B1 (en) * 2014-11-19 2017-08-08 Google Inc. Providing secure digital images
CN104469172B (zh) * 2014-12-31 2018-05-08 小米科技有限责任公司 延时拍摄方法及装置
CN106210496B (zh) * 2015-05-06 2019-12-13 小米科技有限责任公司 照片拍摄方法及装置
CN104954689B (zh) * 2015-06-30 2018-06-26 努比亚技术有限公司 一种利用双摄像头获得照片的方法及拍摄装置
CN105049674A (zh) * 2015-07-01 2015-11-11 中科创达软件股份有限公司 一种视频图像处理方法和系统
CN105488756B (zh) * 2015-11-26 2019-03-29 努比亚技术有限公司 图片合成方法及装置
CN105827946B (zh) * 2015-11-26 2019-02-22 东莞市步步高通信软件有限公司 一种全景图像的生成和播放方法及移动终端
CN106713656B (zh) * 2017-01-13 2020-03-31 努比亚技术有限公司 一种拍摄方法和移动终端
CN108573467A (zh) * 2017-03-09 2018-09-25 南昌黑鲨科技有限公司 基于图像的轨迹合成方法、装置及终端
CN106851128A (zh) * 2017-03-20 2017-06-13 努比亚技术有限公司 一种基于双摄像头的视频数据处理方法和装置
CN107087106A (zh) * 2017-04-19 2017-08-22 深圳市金立通信设备有限公司 一种拍摄方法和终端
CN108521823A (zh) * 2017-06-30 2018-09-11 深圳市大疆创新科技有限公司 一种图像处理方法、装置及电子设备
CN107395824A (zh) * 2017-09-11 2017-11-24 爱德华·斯沃博达 适用于移动设备的全方位拍摄设备及方法
CN107734269B (zh) * 2017-10-16 2020-09-22 维沃移动通信有限公司 一种图像处理方法及移动终端
CN108391050B (zh) * 2018-02-12 2020-04-14 维沃移动通信有限公司 一种图像处理方法及移动终端
JP7119425B2 (ja) * 2018-03-01 2022-08-17 ソニーグループ株式会社 画像処理装置、符号化装置、復号化装置、画像処理方法、プログラム、符号化方法及び復号化方法
CN108769634B (zh) * 2018-07-06 2020-03-17 Oppo(重庆)智能科技有限公司 一种图像处理方法、图像处理装置及终端设备
CN108989673B (zh) * 2018-07-26 2020-11-20 江苏百工造物文化科技有限公司 一种图像合成处理方法及移动终端
CN109215004B (zh) * 2018-07-26 2021-11-19 努比亚技术有限公司 一种图像合成方法、移动终端及计算机可读存储介质
CN109447929B (zh) * 2018-10-18 2020-12-04 北京小米移动软件有限公司 图像合成方法及装置
CN109241956B (zh) * 2018-11-19 2020-12-22 Oppo广东移动通信有限公司 合成图像的方法、装置、终端及存储介质
CN109495683B (zh) * 2018-11-30 2021-08-03 努比亚技术有限公司 一种间隔拍摄方法、设备及计算机可读存储介质
CN109903260B (zh) * 2019-01-30 2023-05-23 华为技术有限公司 图像处理方法及图像处理装置
CN110536087A (zh) * 2019-05-06 2019-12-03 珠海全志科技股份有限公司 电子设备及其运动轨迹照片合成方法、装置和嵌入式装置
CN110276841B (zh) * 2019-06-27 2023-11-24 北京小米移动软件有限公司 应用于增强现实设备的运动轨迹确定方法、装置及终端
CN110611768B (zh) 2019-09-27 2021-06-29 北京小米移动软件有限公司 多重曝光摄影方法及装置
CN111586296B (zh) 2020-04-27 2021-11-16 北京小米移动软件有限公司 图像拍摄方法、图像拍摄装置及存储介质
CN113810587B (zh) * 2020-05-29 2023-04-18 华为技术有限公司 一种图像处理方法及装置
CN112672056A (zh) * 2020-12-25 2021-04-16 维沃移动通信有限公司 图像处理方法及装置
CN116830594A (zh) * 2021-02-20 2023-09-29 Oppo广东移动通信有限公司 图像处理方法、图像处理装置、电子设备及存储介质
CN112969037B (zh) * 2021-02-26 2022-03-15 北京卓视智通科技有限责任公司 一种视频图像侧向融合拼接方法、电子设备及存储介质
CN113569625A (zh) * 2021-06-11 2021-10-29 阿里巴巴新加坡控股有限公司 口腔图像处理方法、装置及电子设备
CN115037992A (zh) * 2022-06-08 2022-09-09 中央广播电视总台 视频处理方法、装置和存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103209292A (zh) * 2012-09-26 2013-07-17 顾红波 一种获取稳定成像的智能拍照系统和方法
CN103312969A (zh) * 2012-03-12 2013-09-18 卡西欧计算机株式会社 图像合成装置以及图像合成方法
CN103327253A (zh) * 2013-06-26 2013-09-25 深圳市中兴移动通信有限公司 多重曝光方法和摄像装置
CN104243819A (zh) * 2014-08-29 2014-12-24 小米科技有限责任公司 照片获取方法及装置

Family Cites Families (30)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3793258B2 (ja) * 1995-10-03 2006-07-05 日本放送協会 動画像処理装置および方法
JP4110560B2 (ja) * 1998-05-20 2008-07-02 カシオ計算機株式会社 画像処理方法及びその装置
RU2187904C1 (ru) * 2000-12-19 2002-08-20 Многопрофильное предприятие ООО "Элсис" Способ и устройство преобразования изображения
JP2007259477A (ja) * 2002-09-30 2007-10-04 Toshiba Corp 画像合成方法、画像合成装置、画像合成プログラム
JP2005311674A (ja) * 2004-04-21 2005-11-04 Toshiba Corp 映像記録表示装置および映像記録表示方法
JP4596929B2 (ja) * 2005-01-19 2010-12-15 株式会社インク 背景画像生成装置及び背景画像生成プログラム
US7952612B2 (en) * 2006-06-22 2011-05-31 Nokia Corporation Method and system for image construction using multiple exposures
JP4830828B2 (ja) 2006-12-06 2011-12-07 カシオ計算機株式会社 画像合成装置、画像合成プログラム及び画像合成方法
JP4877154B2 (ja) * 2007-08-24 2012-02-15 カシオ計算機株式会社 画像処理装置、撮像装置、画像処理方法、および、プログラム
US9251423B2 (en) * 2008-03-21 2016-02-02 Intel Corporation Estimating motion of an event captured using a digital video camera
US8170278B2 (en) * 2008-08-06 2012-05-01 Sri International System and method for detecting and tracking an object of interest in spatio-temporal space
JP4591576B2 (ja) * 2008-08-18 2010-12-01 ソニー株式会社 画像処理装置、画像処理方法、プログラム
JP5520463B2 (ja) * 2008-09-04 2014-06-11 株式会社ソニー・コンピュータエンタテインメント 画像処理装置、対象物追跡装置および画像処理方法
JP5181948B2 (ja) 2008-09-09 2013-04-10 カシオ計算機株式会社 画像処理装置、画像処理方法、及びプログラム
JP4735742B2 (ja) * 2008-12-18 2011-07-27 カシオ計算機株式会社 撮像装置、ストロボ画像生成方法、および、プログラム
JP4877319B2 (ja) * 2008-12-24 2012-02-15 カシオ計算機株式会社 画像生成装置、プログラム、画像表示方法、及び、撮像方法
JP5683851B2 (ja) * 2009-08-20 2015-03-11 株式会社ザクティ 撮像装置及び画像処理装置
JP5495760B2 (ja) * 2009-12-17 2014-05-21 オリンパスイメージング株式会社 撮像装置
JP5446847B2 (ja) * 2009-12-25 2014-03-19 カシオ計算機株式会社 画像処理装置及び方法、並びにプログラム
JP2010200360A (ja) * 2010-04-26 2010-09-09 Casio Computer Co Ltd 撮像装置、ストロボ画像生成方法、および、プログラム
US20120002112A1 (en) * 2010-07-02 2012-01-05 Sony Corporation Tail the motion method of generating simulated strobe motion videos and pictures using image cloning
JP2012099876A (ja) * 2010-10-29 2012-05-24 Sanyo Electric Co Ltd 画像処理装置、撮像装置、画像処理方法、プログラム
US9147260B2 (en) * 2010-12-20 2015-09-29 International Business Machines Corporation Detection and tracking of moving objects
JP2012134775A (ja) * 2010-12-21 2012-07-12 Nikon Systems Inc 画像処理装置、撮像装置、および画像処理プログラム
US9036031B2 (en) * 2010-12-23 2015-05-19 Samsung Electronics Co., Ltd. Digital image stabilization method with adaptive filtering
US20120243802A1 (en) * 2011-03-25 2012-09-27 William Vernon Fintel Composite image formed from an image sequence
JP5803467B2 (ja) * 2011-09-14 2015-11-04 株式会社リコー 画像処理装置および撮像装置、ならびに画像処理方法
JP5978580B2 (ja) * 2011-09-26 2016-08-24 日本電気株式会社 電子機器、その制御方法及びプログラム
JP5945425B2 (ja) * 2012-02-02 2016-07-05 オリンパス株式会社 撮像装置及びその撮像方法
US8830356B2 (en) * 2012-05-22 2014-09-09 Blackberry Limited Method and device for composite image creation

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103312969A (zh) * 2012-03-12 2013-09-18 卡西欧计算机株式会社 图像合成装置以及图像合成方法
CN103209292A (zh) * 2012-09-26 2013-07-17 顾红波 一种获取稳定成像的智能拍照系统和方法
CN103327253A (zh) * 2013-06-26 2013-09-25 深圳市中兴移动通信有限公司 多重曝光方法和摄像装置
CN104243819A (zh) * 2014-08-29 2014-12-24 小米科技有限责任公司 照片获取方法及装置

Also Published As

Publication number Publication date
KR20160041842A (ko) 2016-04-18
EP3010226B1 (en) 2018-10-10
EP3010226A3 (en) 2016-07-27
JP6198958B2 (ja) 2017-09-20
KR101772177B1 (ko) 2017-08-25
US9674395B2 (en) 2017-06-06
RU2634907C2 (ru) 2017-11-08
CN104243819A (zh) 2014-12-24
JP2016535552A (ja) 2016-11-10
RU2015116616A (ru) 2016-11-20
US20160065785A1 (en) 2016-03-03
CN104243819B (zh) 2018-02-23
MX2015005029A (es) 2016-04-27
EP3010226A2 (en) 2016-04-20
BR112015010286A2 (pt) 2017-07-11
MX354121B (es) 2018-02-14

Similar Documents

Publication Publication Date Title
WO2016029641A1 (zh) 照片获取方法及装置
US20170304735A1 (en) Method and Apparatus for Performing Live Broadcast on Game
US9661223B2 (en) Method and device for photographing including camera shake
CN105991930B (zh) 双摄像头的变焦处理方法、装置和移动终端
KR102018887B1 (ko) 신체 부위 검출을 이용한 이미지 프리뷰
WO2015184723A1 (zh) 拍摄控制方法、装置及终端
EP3136391B1 (en) Method, device and terminal device for video effect processing
WO2017031901A1 (zh) 人脸识别方法、装置及终端
WO2016090829A1 (zh) 图像拍摄方法及装置
CN106210496B (zh) 照片拍摄方法及装置
WO2017096782A1 (zh) 防止拍照遮挡的方法及装置
WO2017092128A1 (zh) 预览图像的显示方法和装置
KR101906748B1 (ko) 홍채 이미지 획득 방법 및 장치, 및 홍채 인식 장치
WO2016192325A1 (zh) 视频文件的标识处理方法及装置
WO2017124899A1 (zh) 一种信息处理方法及装置、电子设备
WO2019006769A1 (zh) 无人机跟拍方法及装置
JP6333990B2 (ja) パノラマ写真の生成方法および装置
JP7167244B2 (ja) 遮蔽された画像の検出方法、装置、及び媒体
WO2018098860A1 (zh) 照片合成方法及装置
WO2018053722A1 (zh) 全景照片拍摄方法及装置
US20170244891A1 (en) Method for automatically capturing photograph, electronic device and medium
US11252341B2 (en) Method and device for shooting image, and storage medium
CN113315903A (zh) 图像获取方法和装置、电子设备、存储介质

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: MX/A/2015/005029

Country of ref document: MX

ENP Entry into the national phase

Ref document number: 2015116616

Country of ref document: RU

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 20157011766

Country of ref document: KR

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2016544716

Country of ref document: JP

Kind code of ref document: A

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 15836666

Country of ref document: EP

Kind code of ref document: A1

REG Reference to national code

Ref country code: BR

Ref legal event code: B01A

Ref document number: 112015010286

Country of ref document: BR

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 112015010286

Country of ref document: BR

Kind code of ref document: A2

Effective date: 20150506

122 Ep: pct application non-entry in european phase

Ref document number: 15836666

Country of ref document: EP

Kind code of ref document: A1