WO2019134505A1 - 图像虚化方法、存储介质及电子设备 - Google Patents

图像虚化方法、存储介质及电子设备 Download PDF

Info

Publication number
WO2019134505A1
WO2019134505A1 PCT/CN2018/121815 CN2018121815W WO2019134505A1 WO 2019134505 A1 WO2019134505 A1 WO 2019134505A1 CN 2018121815 W CN2018121815 W CN 2018121815W WO 2019134505 A1 WO2019134505 A1 WO 2019134505A1
Authority
WO
WIPO (PCT)
Prior art keywords
image
preset
blurred
preset image
area
Prior art date
Application number
PCT/CN2018/121815
Other languages
English (en)
French (fr)
Inventor
陈岩
刘耀勇
Original Assignee
Oppo广东移动通信有限公司
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 Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Publication of WO2019134505A1 publication Critical patent/WO2019134505A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/04Context-preserving transformations, e.g. by using an importance map
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/13Edge detection
    • 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
    • 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/45Cameras or camera modules comprising electronic image sensors; Control thereof for generating image signals from two or more image sensors being of different type or operating in different modes, e.g. with a CMOS sensor for moving images in combination with a charge-coupled device [CCD] for still images

Definitions

  • the present invention relates to the field of image processing technologies, and in particular, to an image blurring method, a storage medium, and an electronic device.
  • Background blur can make the captured photos highlight the key targets, and the stereoscopic effect is stronger, which is an important user experience. Many current electronic devices achieve background blur, but the background blur effect is not good.
  • Embodiments of the present invention provide an image blurring method, a storage medium, and an electronic device, which can reduce noise and improve image quality of background blur.
  • an embodiment of the present invention provides an image blurring method, which is applied to an electronic device, and the method includes:
  • the area to be blurred is blurred.
  • an embodiment of the present application provides a storage medium on which a computer program is stored, and when the computer program runs on a computer, causes the computer to execute the image blurring method described above.
  • an embodiment of the present application provides an electronic device, including a processor and a memory, where the memory has a computer program, and the processor is configured to execute the image blurring method by calling the computer program.
  • FIG. 1 is a schematic diagram of a scene of an image blurring apparatus according to an embodiment of the present invention.
  • FIG. 2 is a schematic diagram of a first flow of an image blurring method according to an embodiment of the present invention.
  • FIG. 3 is a second schematic flowchart of an image blurring method according to an embodiment of the present invention.
  • FIG. 4 is another schematic diagram of an image blurring apparatus according to an embodiment of the present invention.
  • FIG. 5 is a third schematic flowchart of an image blurring method according to an embodiment of the present invention.
  • FIG. 6 is a fourth schematic flowchart of an image blurring method according to an embodiment of the present invention.
  • FIG. 7 is a schematic diagram of a first structure of an image blurring apparatus according to an embodiment of the present invention.
  • FIG. 8 is a schematic diagram of a second structure of an image blurring apparatus according to an embodiment of the present invention.
  • FIG. 9 is a third schematic structural diagram of an image blurring apparatus according to an embodiment of the present invention.
  • FIG. 10 is a fourth structural diagram of an image blurring apparatus according to an embodiment of the present invention.
  • FIG. 11 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
  • FIG. 12 is another schematic structural diagram of an electronic device according to an embodiment of the present invention.
  • the embodiment of the present application provides an image blurring method, which is applied to an electronic device, and the method includes:
  • the area to be blurred is blurred.
  • the detecting the contour edge of the target image in the foreground image may specifically include:
  • contour edge of the target image in the foreground image may be:
  • the boundary is tracked using a hysteresis algorithm to obtain a contoured edge of the target image in the foreground image.
  • the preset image includes a first preset image acquired by the first camera and a second preset image acquired by the second preset camera;
  • Deviating the area to be blurred may specifically include:
  • the method may further include:
  • the blurred preset image is displayed.
  • the preset image includes a first preset image acquired by the first camera and a second preset image acquired by the second preset camera;
  • Deviating the area to be blurred may specifically include:
  • the area to be blurred is blurred according to the first ambiguity coefficient
  • the area to be blurred is blurred according to a second blurring coefficient, wherein the first blurring coefficient is greater than the second blurring coefficient.
  • the preset image further includes a background image; and the blurring the area to be blurred may specifically include:
  • the first area to be blurred is blurred according to a third blurring coefficient
  • the second area to be blurred is blurred according to a fourth blurring parameter.
  • the embodiment of the present application further provides a storage medium, wherein the storage medium stores a plurality of instructions, the instructions being adapted to be loaded by a processor to perform the image blurring method according to any one of the above.
  • the embodiment of the present application further provides an electronic device, including a processor and a memory, where the memory stores a computer program, the processor is connected to the memory, and the processor calls the computer program, the processing Execution:
  • the area to be blurred is blurred.
  • the processor further performs:
  • the processor In scanning the foreground image based on the edge detection operator to obtain a contour edge of the target image in the foreground image, the processor further performs:
  • the boundary is tracked using a hysteresis algorithm to obtain a contoured edge of the target image in the foreground image.
  • the processor further performs:
  • the preset image includes a first preset image acquired by the first camera and a second preset image acquired by the second preset camera;
  • the processor further performs:
  • the processor further performs:
  • the preset image includes a first preset image acquired by the first camera and a second preset image acquired by the second preset camera;
  • the processor further performs:
  • the processor further performs:
  • the area to be blurred is blurred according to the first ambiguity coefficient
  • the area to be blurred is blurred according to a second blurring coefficient, wherein the first blurring coefficient is greater than the second blurring coefficient.
  • the preset image further includes a background image; in the blurring the area to be blurred, the processor further performs:
  • the first area to be blurred is blurred according to a third blurring coefficient
  • the second area to be blurred is blurred according to a fourth blurring parameter.
  • FIG. 1 is a schematic diagram of an application scenario of an image blurring device according to an embodiment of the present disclosure.
  • the image blurring device acquires a preset image captured by the dual camera; calculates a depth of field of each pixel in the preset image, and obtains a foreground image in the preset image according to the depth of field of each pixel; and detects the target image in the foreground image.
  • the contour edge; the area outside the contour edge of the target image is set as the area to be blurred; the area to be blurred is blurred.
  • the embodiment of the present application provides an image blurring method
  • the execution body of the image blurring method may be an image blurring device provided by an embodiment of the present application, or an electronic device integrated with the image blurring device, wherein the image blurring
  • the device can be implemented in hardware or software.
  • the executive body of the embodiment of the present application may be a terminal device such as a smart phone or a tablet computer.
  • the image blurring method comprises: acquiring a preset image captured by the dual camera; calculating a depth of field of each pixel in the preset image, and obtaining a foreground image in the preset image according to the depth of field of each pixel; and detecting the target image in the foreground image
  • the contour edge; the area outside the contour edge of the target image is set as the area to be blurred; the area to be blurred is blurred.
  • FIG. 2 is a schematic diagram of a first flow of an image blurring method according to an embodiment of the present application.
  • the image blurring method provided by the embodiment of the present application is applied to an electronic device, and the specific process may be as follows:
  • Dual cameras can be placed sideways adjacent to each other or vertically adjacent.
  • the dual camera can be a dual rear camera or a dual front camera for an electronic device such as a smart phone.
  • the dual camera can be a color camera and the other is a black and white camera.
  • the dual camera can also use a camera with a different focal length. Of course, the dual camera can also use the same camera.
  • the preset image captured by the dual camera can be obtained through the local electronic device, and the preset image acquired by the dual camera of other electronic devices can be obtained through the network or the Bluetooth.
  • the depth of field of each pixel in the preset image is calculated.
  • Two preset images can be obtained through the dual camera, and then the depth of field of each pixel of any one of the two preset images is calculated according to the difference between the two preset image capturing angles, the focus position, the shooting position, and the shooting height. .
  • FIG. 3 is a schematic diagram of a second flow of an image blurring method according to an embodiment of the present application.
  • the step of calculating the depth of field of each pixel in the preset image provided by the embodiment of the present application further includes the following process:
  • the preset image includes a first preset image acquired by the first camera and a second preset image acquired by the second preset camera.
  • the dual camera includes a first camera and a second camera.
  • the first camera captures a first preset image
  • the second camera captures a second preset image.
  • the first preset image and the second preset image can be combined into a preset. image.
  • a feature point of the first preset image is extracted to form a first feature point based on a Scale-Invariant Feature Transform (SIFT) or a Speeded Up Robust Feature (SURF) set.
  • SIFT Scale-Invariant Feature Transform
  • SURF Speeded Up Robust Feature
  • the feature points of the second preset image are extracted to form a second feature point set based on the scale invariant feature transform algorithm or the accelerated robust feature algorithm.
  • the pixel points of the first preset image and the second preset image need to be matched to determine the first preset image and The pixel point corresponding to the second preset image.
  • the depth of field of each pixel point may be obtained by subtracting the luminance values between each of the corresponding pixels in the first preset image and the second preset image.
  • At least one of the shooting angle, the focus position, the shooting position, and the shooting height of the two preset images may also be different by acquiring two preset images. Then, through the difference between the two preset images, the depth of field of each pixel in any one of the two preset images is calculated.
  • the edge information in the foreground image is obtained based on a preset algorithm, and the target image is selected by the edge information, thereby obtaining a contour edge of the target image.
  • the step of detecting a contour edge of the target image in the foreground image further includes the following process:
  • the foreground image is scanned based on the edge detection operator to obtain the contour edge of the target image in the foreground image.
  • the edge detection operator (Canny) is constructed first, and then the foreground image is scanned based on the edge detection operator to obtain the contour edge of the target image in the foreground image.
  • Gaussian filtering is first applied to smooth the foreground image to remove noise; then, the intensity gradients of the foreground image are sought; then the non-maximum suppression technique is applied to eliminate the edge false detection; then the double threshold method is applied.
  • the contour edge of the target image in the foreground image is obtained.
  • the target image may be a foreground image, and the target image may also be a sub-image in the foreground image.
  • the foreground image includes the image of the user A
  • the target image may be the entire foreground image or the image of the user A in the foreground image.
  • the area outside the edge of the contour of the target image is set as the area to be blurred, and the image in the edge of the contour of the target image is not blurred.
  • the target image may be a foreground image, and the target image may also be a sub-image in the foreground image.
  • the foreground image includes the image of the user A
  • the target image may be the entire foreground image or the image of the user A in the foreground image.
  • the area to be blurred is blurred.
  • the area to be blurred is blurred according to a preset algorithm, such as blurring the area to be blurred according to a Gaussian filtering algorithm.
  • the first preset image and the second preset image may be processed during the image acquisition by the dual camera, and the image blurred by the area to be blurred is displayed to the user. After the first preset image and the preset image synthesized by the second preset image are obtained, the area to be blurred in the preset image is identified, and the area to be blurred is blurred to form a new image.
  • FIG. 4 is a schematic diagram of another scenario of an image blurring method according to an embodiment of the present application.
  • the preset image 201 is acquired first, then the depth of field of each pixel in the preset image 201 is calculated, and the foreground image 202 of the preset image 201 is obtained according to the depth of field of each pixel, and then the contour of the target image in the foreground image is detected.
  • the area outside the contour edge of the target image is set as the area to be blurred 203, and finally the area 203 to be blurred is blurred.
  • FIG. 5 is a schematic diagram of a third process of an image blurring method according to an embodiment of the present application.
  • the step of blurring the area to be blurred provided by the embodiment of the present application further includes the following process:
  • the area to be blurred is blurred according to the first blurring coefficient
  • the target image is not a character image
  • the area to be blurred is blurred according to the second blurring coefficient.
  • the target image is a character image
  • a higher blurring coefficient can be set, and other images, such as landscape images and articles.
  • FIG. 6 is a schematic diagram of a fourth process of the image blurring method according to an embodiment of the present application.
  • the step of blurring the area to be blurred provided by the embodiment of the present application further includes the following process:
  • the area to be blurred is divided into a first to be blurred area located in the foreground image and a second to be blurred area located in the back view image;
  • the first area to be blurred is blurred according to the third blurring coefficient
  • the second area to be blurred is blurred according to the fourth blurring parameter.
  • the area to be blurred includes a first to be blurred area located in the foreground image and a second to be blurred area located in the background image, and then the first to be blurred area and the second to be blurred area are performed according to different blurring coefficients. Blurring. For example, if the ambiguity coefficient of the first area to be falsified is smaller than the ambiguity coefficient of the second area to be falsified, that is, the ambiguity of the first area to be falsified is smaller than the area of the second area to be falsified, the blur transition of the image is better.
  • the image blurring method obtaineds the preset image captured by the dual camera; calculates the depth of field of each pixel in the preset image, and obtains the depth of the image according to the depth of field of each pixel.
  • a foreground image detecting a contour edge of the target image in the foreground image; setting a region outside the contour edge of the target image as a region to be blurred; blurring the region to be blurred.
  • the foreground image is obtained by the depth of field of each pixel, and then the contour edge of the target image in the foreground image is detected, and the area to be blurred is accurately extracted according to the edge of the contour, the target image is accurately extracted, the key is highlighted, and the stereoscopic effect is enhanced.
  • FIG. 7 is a schematic diagram of a first structure of an image blurring apparatus according to an embodiment of the present application.
  • the image blurring device 500 is applied to an electronic device, and the image blurring device 500 includes a preset image acquiring module 501, a foreground image acquiring module 502, a contour edge acquiring module 503, a to be blurred region acquiring module 504, and a blurring module 505. . among them:
  • the preset image obtaining module 501 is configured to acquire a preset image captured by the dual camera.
  • Dual cameras can be placed sideways adjacent to each other or vertically adjacent.
  • the dual camera can be a dual rear camera or a dual front camera for an electronic device such as a smart phone.
  • the dual camera can be a color camera and the other is a black and white camera.
  • the dual camera can also use a camera with a different focal length. Of course, the dual camera can also use the same camera.
  • the preset image captured by the dual camera can be obtained through the local electronic device, and the preset image acquired by the dual camera of other electronic devices can be obtained through the network or the Bluetooth.
  • the foreground image obtaining module 502 is configured to calculate a depth of field of each pixel in the preset image, and obtain a foreground image in the preset image according to the depth of field of each pixel.
  • the depth of field of each pixel in the preset image is calculated.
  • Two preset images can be obtained through the dual camera, and then the depth of field of each pixel of any one of the two preset images is calculated according to the difference between the two preset image capturing angles, the focus position, the shooting position, and the shooting height. .
  • At least one of the shooting angle, the focus position, the shooting position, and the shooting height of the two preset images may also be different by acquiring two preset images. Then, through the difference between the two preset images, the depth of field of each pixel in any one of the two preset images is calculated.
  • the contour edge acquiring module 503 is configured to detect a contour edge of the target image in the foreground image.
  • the edge information in the foreground image is obtained based on a preset algorithm, and the target image is selected by the edge information, thereby obtaining a contour edge of the target image.
  • the area to be blurred is used to obtain an area outside the contour edge of the target image as a region to be blurred.
  • the area outside the edge of the contour of the target image is set as the area to be blurred, and the image in the edge of the contour of the target image is not blurred.
  • the target image may be a foreground image, and the target image may also be a sub-image in the foreground image.
  • the foreground image includes the image of the user A
  • the target image may be the entire foreground image or the image of the user A in the foreground image.
  • the blurring module 505 is configured to blur the area to be blurred.
  • the area to be blurred is blurred according to a preset algorithm, such as blurring the area to be blurred according to a Gaussian filtering algorithm.
  • the first preset image and the second preset image may be processed during the image acquisition by the dual camera, and the image blurred by the area to be blurred is displayed to the user. After the first preset image and the preset image synthesized by the second preset image are obtained, the area to be blurred in the preset image is identified, and the area to be blurred is blurred to form a new image.
  • FIG. 8 is a schematic diagram of a second structure of an image blurring apparatus according to an embodiment of the present disclosure.
  • the preset image includes a first preset image acquired by the first camera and a second preset image acquired by the second preset camera.
  • the dual camera includes a first camera and a second camera. The first camera captures a first preset image, and the second camera captures a second preset image. The first preset image and the second preset image can be combined into a preset. image.
  • the foreground image acquisition module 502 includes a feature point set acquisition sub-module 5021, a matching sub-module 5022, and a pixel point depth of field acquisition sub-module 5023. among them:
  • the feature point set obtaining sub-module 5021 is configured to extract a first feature point set of the first preset image and a second feature point set of the second preset image.
  • a feature point of the first preset image is extracted to form a first feature point based on a Scale-Invariant Feature Transform (SIFT) or a Speeded Up Robust Feature (SURF) set.
  • SIFT Scale-Invariant Feature Transform
  • SURF Speeded Up Robust Feature
  • the feature points of the second preset image are extracted to form a second feature point set based on the scale invariant feature transform algorithm or the accelerated robust feature algorithm.
  • the matching sub-module 5022 is configured to match the feature points in the first feature point set and the second feature point set to obtain a matching result.
  • the pixel points of the first preset image and the second preset image need to be matched to determine the first preset image and The pixel point corresponding to the second preset image.
  • the pixel depth of field acquisition sub-module 5023 is configured to perform pixel progressive scanning according to the matching result, and calculate a depth of field of each pixel in the first preset image and/or the second preset image.
  • the depth of field of each pixel point may be obtained by subtracting the luminance values between each of the corresponding pixels in the first preset image and the second preset image.
  • At least one of the shooting angle, the focus position, the shooting position, and the shooting height of the two preset images may also be different by acquiring two preset images. Then, through the difference between the two preset images, the depth of field of each pixel in any one of the two preset images is calculated.
  • FIG. 9 is a schematic diagram of a third structure of an image blurring apparatus according to an embodiment of the present application.
  • the contour edge acquisition module 503 includes a construction sub-module 5031 and a contour edge acquisition sub-module 5032. among them:
  • the contour edge acquisition sub-module 5032 is configured to scan the foreground image based on the edge detection operator to obtain a contour edge of the target image in the foreground image.
  • the edge detection operator (Canny) is constructed first, and then the foreground image is scanned based on the edge detection operator to obtain the contour edge of the target image in the foreground image.
  • Gaussian filtering is first applied to smooth the foreground image to remove noise; then, the intensity gradients of the foreground image are sought; then the non-maximum suppression technique is applied to eliminate the edge false detection; then the double threshold method is applied.
  • the contour edge of the target image in the foreground image is obtained.
  • the target image may be a foreground image, and the target image may also be a sub-image in the foreground image.
  • the foreground image includes the image of the user A
  • the target image may be the entire foreground image or the image of the user A in the foreground image.
  • the blurring module 505 includes a determining submodule 5051, a first blurring submodule 5052, and a second blurring submodule 5053. among them:
  • a determining sub-module 5051 configured to determine whether the target image is a character image
  • the first blurring sub-module 5052 is configured to: if the target image is a character image, blur the area to be blurred according to the first blurring coefficient;
  • the second blurring sub-module 5053 is configured to blur the area to be blurred according to the second blurring coefficient if the target image is not a character image.
  • the target image is a character image
  • a higher blurring coefficient can be set, and other images, such as landscape images and articles.
  • the blurring module may further include a dividing sub-module and a blurring processing sub-module.
  • the sub-module is configured to divide the area to be blurred into a first to-be-converted area located in the foreground image and a second to-be-converted area located in the background image.
  • the imaginary processing sub-module is used for blurring the first ambiguous area according to the third imaginary coefficient, and the second area to be blunt is blurred by the fourth imaginary parameter.
  • the area to be blurred includes a first to be blurred area located in the foreground image and a second to be blurred area located in the background image, and then the first to be blurred area and the second to be blurred area are performed according to different blurring coefficients. Blurring. For example, if the ambiguity coefficient of the first area to be falsified is smaller than the ambiguity coefficient of the second area to be falsified, that is, the ambiguity of the first area to be falsified is smaller than the area of the second area to be falsified, the blur transition of the image is better.
  • the image blurring device obtains a preset image captured by the dual camera; calculates the depth of field of each pixel in the preset image, and obtains the depth of the image according to the depth of field of each pixel.
  • a foreground image detecting a contour edge of the target image in the foreground image; setting a region outside the contour edge of the target image as a region to be blurred; blurring the region to be blurred.
  • the foreground image is obtained by the depth of field of each pixel, and then the contour edge of the target image in the foreground image is detected, and the area to be blurred is accurately extracted according to the edge of the contour, the target image is accurately extracted, the key is highlighted, and the stereoscopic effect is enhanced.
  • the foregoing modules may be implemented as a separate entity, or may be implemented in any combination, and may be implemented as the same or a plurality of entities.
  • the foregoing modules refer to the foregoing method embodiments, and details are not described herein again.
  • the image blurring device belongs to the same concept as the image blurring method in the above embodiment, and any method provided in the embodiment of the image blurring method can be run on the image blurring device, and the specific implementation process thereof For details, refer to the embodiment of the image blurring method, which is not described here.
  • the electronic device 600 includes a processor 601 and a memory 602.
  • the processor 601 is electrically connected to the memory 602.
  • the processor 600 is a control center of the electronic device 600, which connects various parts of the entire electronic device using various interfaces and lines, executes the electronic by running or loading a computer program stored in the memory 602, and calling data stored in the memory 602.
  • the various functions of device 600 and processing data enable overall monitoring of electronic device 600.
  • the memory 602 can be used to store software programs and units, and the processor 601 executes various functional applications and data processing by running computer programs and units stored in the memory 602.
  • the memory 602 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, a computer program required for at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may be stored according to Data created by the use of electronic devices, etc.
  • memory 602 can include high speed random access memory, and can also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, memory 602 can also include a memory controller to provide processor 601 access to memory 602.
  • the processor 601 in the electronic device 600 loads the instructions corresponding to the process of one or more computer programs into the memory 602 according to the following steps, and is stored in the memory 602 by the processor 601.
  • the computer program in which to implement various functions, as follows:
  • the processor 601 is further configured to perform the following steps:
  • the foreground image is scanned based on the edge detection operator to obtain the contour edge of the target image in the foreground image.
  • the processor 601 is further configured to perform the following steps:
  • the preset image includes a first preset image acquired by the first camera and a second preset image acquired by the second preset camera;
  • the processor 601 is further configured to perform the following steps:
  • the preset image includes a first preset image acquired by the first camera and a second preset image acquired by the second preset camera;
  • the processor 601 is further configured to perform the following steps:
  • the area to be blurred is blurred according to the first ambiguity coefficient
  • the area to be blurred is blurred by the second blurring factor.
  • the processor 601 is further configured to perform the following steps:
  • the first area to be blurred is blurred according to the third blurring coefficient
  • the second area to be blurred is blurred according to the fourth blurring parameter
  • the electronic device obtains the preset image captured by the dual camera; calculates the depth of field of each pixel in the preset image, and obtains the foreground image in the preset image according to the depth of field of each pixel. Detecting the contour edge of the target image in the foreground image; setting the region outside the contour edge of the target image as the region to be blurred; blurring the region to be blurred.
  • the foreground image is obtained by the depth of field of each pixel, and then the contour edge of the target image in the foreground image is detected, and the area to be blurred is accurately extracted according to the edge of the contour, the target image is accurately extracted, the key is highlighted, and the stereoscopic effect is enhanced.
  • the electronic device 600 may further include: a display 603, a radio frequency circuit 604, an audio circuit 605, and a power source 606.
  • the display 603, the radio frequency circuit 604, the audio circuit 605, and the power source 606 are electrically connected to the processor 601, respectively.
  • Display 603 can be used to display information entered by a user or information provided to a user, as well as various graphical user interfaces, which can be composed of graphics, text, icons, video, and any combination thereof.
  • the display 603 can include a display panel.
  • the display panel can be configured in the form of a liquid crystal display (LCD), or an organic light-emitting diode (OLED).
  • LCD liquid crystal display
  • OLED organic light-emitting diode
  • the radio frequency circuit 604 can be used to transmit and receive radio frequency signals to establish wireless communication with network devices or other electronic devices through wireless communication, and to transmit and receive signals with network devices or other electronic devices.
  • the audio circuit 605 can be used to provide an audio interface between the user and the electronic device through the speaker and the microphone.
  • Power source 606 can be used to power various components of electronic device 600.
  • the power source 606 can be logically coupled to the processor 601 through a power management system to enable functions such as managing charging, discharging, and power management through the power management system.
  • the electronic device 600 may further include a camera, a Bluetooth unit, and the like, and details are not described herein again.
  • the electronic device of the embodiment of the present application may be a terminal device such as a smart phone or a tablet computer.
  • the embodiment of the present application further provides a storage medium, where the storage medium stores a computer program, and when the computer program runs on the computer, causes the computer to perform the image blurring method in any of the above embodiments, for example, by acquiring a dual camera.
  • the area is set to be the area to be blurred; the area to be blurred is blurred.
  • the storage medium may be a magnetic disk, an optical disk, a read only memory (ROM), or a random access memory (RAM).
  • ROM read only memory
  • RAM random access memory
  • the computer program can be stored in a computer readable storage medium, such as in a memory of the electronic device, and executed by at least one processor within the electronic device, and can include, for example, an image blurring method during execution.
  • the storage medium may be a magnetic disk, an optical disk, a read only memory, a random access memory, or the like.
  • each functional unit may be integrated into one processing chip, or each unit may exist physically separately, or two or more units may be integrated into one unit.
  • the above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
  • the integrated unit if implemented in the form of a software functional unit and sold or used as a stand-alone product, may also be stored in a computer readable storage medium such as a read only memory, a magnetic disk or an optical disk.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Studio Devices (AREA)
  • Image Processing (AREA)
  • Image Analysis (AREA)

Abstract

一种图像虚化方法、存储介质及电子设备,所述方法包括:获取双摄像头拍摄的预设图像(101);计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像(102);检测前景图像中目标图像的轮廓边缘(103);将目标图像的轮廓边缘外的区域设为待虚化区域(104);将待虚化区域虚化(105)。

Description

图像虚化方法、存储介质及电子设备
本申请要求于2018年01月05日提交中国专利局、申请号为201810012080.0、申请名称为“图像虚化方法、装置、存储介质及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本发明涉及图像处理技术领域,尤其涉及一种图像虚化方法、存储介质及电子设备。
背景技术
背景虚化可以使拍摄的照片突出重点目标,立体感更强,是一项重要的用户体验。目前的很多电子设备实现背景虚化,但是背景虚化效果不好。
发明内容
本发明实施例提供一种图像虚化方法、存储介质及电子设备,可以减少噪点,提升背景虚化的图像画质。
第一方面,本发明实施例提供一种图像虚化方法,应用于电子设备,所述方法包括:
获取双摄像头拍摄的预设图像;
计算所述预设图像中各个像素点的景深,并根据所述各个像素点的景深,得到所述预设图像中的前景图像;
检测所述前景图像中目标图像的轮廓边缘;
将所述目标图像的轮廓边缘外的区域设为待虚化区域;
将所述待虚化区域虚化。
第二方面,本申请实施例提供一种存储介质,其上存储有计算机程序,当所述计算机程序在计算机上运行时,使得所述计算机执行上述的图像虚化方法。
第三方面,本申请实施例提供一种电子设备,包括处理器和存储器,所述存储器有计算机程序,所述处理器通过调用所述计算机程序,用于执行上述的图像虚化方法。
附图说明
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本发明实施例提供的图像虚化装置的场景示意图。
图2是本发明实施例提供的图像虚化方法的第一种流程示意图。
图3是本发明实施例提供的图像虚化方法的第二种流程示意图。
图4是本发明实施例提供的图像虚化装置的另一场景示意图。
图5是本发明实施例提供的图像虚化方法的第三种流程示意图。
图6是本发明实施例提供的图像虚化方法的第四种流程示意图。
图7是本发明实施例提供的图像虚化装置的第一种结构示意图。
图8是本发明实施例提供的图像虚化装置的第二种结构示意图。
图9是本发明实施例提供的图像虚化装置的第三种结构示意图。
图10是本发明实施例提供的图像虚化装置的第四种结构示意图。
图11是本发明实施例提供的电子设备的一种结构示意图。
图12是本发明实施例提供的电子设备的另一种结构示意图。
具体实施方式
请参照图式,其中相同的组件符号代表相同的组件,本申请的原理是以实施在一适当的运算环境中来举例说明。以下的说明是基于所例示的本申请具体实施例,其不应被视为限制本申请未在此详述的其它具体实施例。
本申请实施例提供一种图像虚化方法,应用于电子设备,所述方法包括:
获取双摄像头拍摄的预设图像;
计算所述预设图像中各个像素点的景深,并根据所述各个像素点的景深,得到所述预设图像中的前景图像;
检测所述前景图像中目标图像的轮廓边缘;
将所述目标图像的轮廓边缘外的区域设为待虚化区域;
将所述待虚化区域虚化。
检测所述前景图像中目标图像的轮廓边缘具体可以包括:
构建边缘检测算子;
基于所述边缘检测算子扫描所述前景图像,得到所述前景图像中目标图像的轮廓边缘。
基于所述边缘检测算子扫描所述前景图像,得到所述前景图像中目标图像的轮廓边缘具体可以包括:
应用高斯滤波平滑所述前景图像;
获取高斯滤波后的前景图像的强度梯度;
对获取强度梯度后的前景图像应用非最大抑制算法;
应用双阈值算法决定非最大抑制算法处理后的前景图像的边界;
利用滞后算法跟踪所述边界,得到所述前景图像中目标图像的轮廓边缘。
计算所述预设图像中各个像素点的景深具体可以包括:
所述预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
提取所述第一预设图像的第一特征点集合,以及所述第二预设图像的第二特征点集合;
将所述第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
根据所述匹配结果进行像素逐行扫描,计算得到所述第一预设图像和/或所述第二预设图像中各个像素点的景深。
将所述待虚化区域虚化具体可以包括:
将所述第一预设图像和所述第二预设图像合成后的预设图像显示;
获取所述预设图像中的待虚化区域,将所述预设图像的所述待虚化区域虚化显示。
将所述待虚化区域虚化之后还可以包括:
将虚化后的预设图像显示。
计算所述预设图像中各个像素点的景深具体可以包括:
所述预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
基于尺度不变特征变换算法或加速稳健特征算法,提取所述第一预设图像的第一特征点集合,以及所述第二预设图像的第二特征点集合;
基于近似最近邻算法将所述第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
根据所述匹配结果进行像素逐行扫描,计算得到所述第一预设图像和/或所述第二预设图像中各个像素点的景深。
计算所述预设图像中各个像素点的景深具体可以包括:
通过所述双摄像头中第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
根据所述第一摄像头和所述第二摄像头不同的拍摄角度、焦点位置、拍摄位置和拍摄高度中的至少一项,计算得到所述第一预设图像和所述第二预设图像中各个像素点的景深。
将所述待虚化区域虚化具体可以包括:
判断所述目标图像是否为人物图像;
若是,则将所述待虚化区域按第一虚化系数虚化;
若否,则将所述待虚化区域按第二虚化系数虚化,其中,第一虚化系数大于所述第二虚化系数。
预设图像还包括后景图像;将所述待虚化区域虚化具体可以包括:
将所述待虚化区域划分为位于所述前景图像中的第一待虚化区域和位于所述后景图像的第二待虚化区域;
所述第一待虚化区域按第三虚化系数虚化,所述第二待虚化区域按第四虚化参数虚化。本申请实施例还提供一种存储介质,其中,所述存储介质中存储有多条指令,所述指令适于由处理器加载以执行上述任一项所述的图像虚化方法。
本申请实施例还提供一种电子设备,其包括处理器和存储器,所述存储器存储有计算机程序,所述处理器与所述存储器连接,所述处理器通过调用所述计算机程序,所述处理器执行:
获取双摄像头拍摄的预设图像;
计算所述预设图像中各个像素点的景深,并根据所述各个像素点的景深,得到所述预设图像中的前景图像;
检测所述前景图像中目标图像的轮廓边缘;
将所述目标图像的轮廓边缘外的区域设为待虚化区域;
将所述待虚化区域虚化。
在检测所述前景图像中目标图像的轮廓边缘中,所述处理器还执行:
构建边缘检测算子;
基于所述边缘检测算子扫描所述前景图像,得到所述前景图像中目标图像的轮廓边缘。
在基于所述边缘检测算子扫描所述前景图像,得到所述前景图像中目标图像的轮廓边缘中,所述处理器还执行:
应用高斯滤波平滑所述前景图像;
获取高斯滤波后的前景图像的强度梯度;
对获取强度梯度后的前景图像应用非最大抑制算法;
应用双阈值算法决定非最大抑制算法处理后的前景图像的边界;
利用滞后算法跟踪所述边界,得到所述前景图像中目标图像的轮廓边缘。
在计算所述预设图像中各个像素点的景深中,所述处理器还执行:
所述预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
提取所述第一预设图像的第一特征点集合,以及所述第二预设图像的第二特征点集合;
将所述第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
根据所述匹配结果进行像素逐行扫描,计算得到所述第一预设图像和/或所述第二预设图像中各个像素点的景深。
在将所述待虚化区域虚化中,所述处理器还执行:
将所述第一预设图像和所述第二预设图像合成后的预设图像显示;
获取所述预设图像中的待虚化区域,将所述预设图像的所述待虚化区域虚化显示。
在计算所述预设图像中各个像素点的景深中,所述处理器还执行:
所述预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
基于尺度不变特征变换算法或加速稳健特征算法,提取所述第一预设图像的第一特征点集合,以及所述第二预设图像的第二特征点集合;
基于近似最近邻算法将所述第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
根据所述匹配结果进行像素逐行扫描,计算得到所述第一预设图像和/或所述第二预设图像中各个像素点的景深。
在计算所述预设图像中各个像素点的景深中,所述处理器还执行:
通过所述双摄像头中第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
根据所述第一摄像头和所述第二摄像头不同的拍摄角度、焦点位置、拍摄位置和拍摄高度中的至少一项,计算得到所述第一预设图像和所述第二预设图像中各个像素点的景深。
在将所述待虚化区域虚化中,所述处理器还执行:
判断所述目标图像是否为人物图像;
若是,则将所述待虚化区域按第一虚化系数虚化;
若否,则将所述待虚化区域按第二虚化系数虚化,其中,第一虚化系数大于所述第二虚化系数。
在预设图像还包括后景图像;将所述待虚化区域虚化中,所述处理器还执行:
将所述待虚化区域划分为位于所述前景图像中的第一待虚化区域和位于所述后景图像的第二待虚化区域;
所述第一待虚化区域按第三虚化系数虚化,所述第二待虚化区域按第四虚化参数虚化。
请参阅图1,图1为本申请实施例提供的图像虚化装置的应用场景示意图。例如,图像虚化装置获取双摄像头拍摄的预设图像;计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像;检测前景图像中目标图像的轮廓边缘;将目标图像的轮廓边缘外的区域设为待虚化区域;将待虚化区域虚化。
本申请实施例提供一种图像虚化方法,该图像虚化方法的执行主体可以是本申请实施例提供的图像虚化装置,或者集成了该图像虚化装置的电子设备,其中该图像虚化装置可以采用硬件或者软件的方式实现。可以理解的是,本申请实施例的执行主体可以是诸如智能手机或平板电脑等的终端设备。
本申请实施例将从图像虚化装置的角度进行描述,该图像虚化装置具体可以集成在电子设备中。该图像虚化方法包括:获取双摄像头拍摄的预设图像;计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像;检测前景图像中目标图像的轮廓边缘;将目标图像的轮廓边缘外的区域设为待虚化区域;将待虚化区域虚化。
请参阅图2,图2为本申请实施例提供的图像虚化方法的第一种流程示意图。本申请实施例提供的图像虚化方法应用于电子设备,具体流程可以如下:
101、获取双摄像头拍摄的预设图像。
双摄像头可以横向相邻设置在一起,也可以竖向相邻设置。双摄像头可以为电子设备如智能手机的双后置摄像头或双前置摄像头。双摄像头可以一个为彩色摄像头另一个为黑白摄像头,双摄像头也可以采用焦距不一样的摄像头,当然双摄像头也可以采用一样的摄像头。
可以通过本地电子设备获取双摄像头拍摄的预设图像,也可以通过网络、蓝牙的途径获取其他电子设备双摄像头拍摄获取的预设图像。
102、计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像。
得到预设图像后,计算预设图像中各个像素点的景深。可以通过双摄像头获取两个预设图像,然后根据两个预设图像拍摄角度、焦点位置、拍摄位置、拍摄高度等区别,计算得到两个预设图像中任意一个预设图像各个像素点的景深。
请参阅图3,图3为本申请实施例提供的图像虚化方法的第二种流程示意图。本申请实施例提供的计算预设图像中各个像素点的景深的步骤,还包括如下流程:
1021、预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像。
双摄摄像头包括第一摄像头和第二摄像头,第一摄像头拍摄获取第一预设图像,第二摄像头拍摄获取第二预设图像,第一预设图像和第二预设图像可以合成为预设图像。
1022、提取第一预设图像的第一特征点集合,以及第二预设图像的第二特征点集合。
提取第一预设图像中的特征点形成第一特征点集合,提取第二预设图像中的特征点形成第二特征点集合。
在一些实施例中,基于尺度不变特征变换算法(Scale-invariant feature transform,SIFT)或加速稳健特征算法(Speeded Up Robust Features,SURF),提取第一预设图像的特征点形成第一特征点集合。
在一些实施例中,基于尺度不变特征变换算法或加速稳健特征算法,提取第二预设图像的特征点形成第二特征点集合。
1023、将第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果。
然后将第一特征点集合和第二特征点集合中的特征点进行匹配,确定出第一预设图像和第二预设图像对应的像素点,在某些情况下,在利用双摄像头拍摄第一预设图像和第二预设图像的时候,无法保证第一预设图像与第二预设图像的拍摄位置、拍摄角度和拍摄高度完全相同,可能会存在一定的偏差,所以在此情况下,为了保证第一预设图像与第二预设图像中每个像素点相互对应,需要对第一预设图像和第二预设图像的像素点进行匹配,以确定出第一预设图像与第二预设图像对应的像素点。
1024、根据匹配结果进行像素逐行扫描,计算得到第一预设图像和/或第二预设图像中各个像素点的景深。
确定出第一预设图像与第二预设图像对应的像素点后,对这些像素点进行像素点逐行扫描,计算得到第一预设图像和/或第二预设图像中各个像素点的景深。可以通过对第一预设图像与第二预设图像中每个对应的像素点之间的亮度值进行减法运算得到各个像素点的景深。
在一些实施例中,还可以通过获取两张预设图像,两张预设图像的拍摄角度、焦点位置、拍摄位置、拍摄高度中至少有一项不一样。然后通过两张预设图像的差异,计算得到两张预设图像中任意一张预设图像中各个像素点的景深。
103、检测前景图像中目标图像的轮廓边缘。
获取前景图像后,基于预设算法得到该前景图像中的边缘信息,通过该边缘信息选出目标图像,进而得到目标图像的轮廓边缘。
在一些实施例中,检测前景图像中目标图像的轮廓边缘的步骤,还包括如下流程:
构建边缘检测算子;
基于边缘检测算子扫描前景图像,得到前景图像中目标图像的轮廓边缘。
先构建边缘检测算子(Canny),然后基于该边缘检测算子扫描前景图像,得到前景图像中目标图像的轮廓边缘。具体的,先应用高斯滤波来平滑前景图像去除噪声;然后找寻前景图像的强度梯度(intensity gradients);再应用非最大抑制(non-maximum suppression)技术来消除边误检;接着应用双阈值的方法来决定可能的(潜在的)边界;最后利用滞后技术来跟踪边界。从而得到前景图像中目标图像的轮廓边缘。
需要说明的是,目标图像可以为前景图像,目标图像也可以为前景图像中的一个子图像。例如,前景图像中包括用户A的图像,目标图像可以为整个前景图像,也可以为前景图像中用户A的图像。
104、将目标图像的轮廓边缘外的区域设为待虚化区域。
得到目标图像的轮廓边缘后,将目标图像轮廓边缘外的区域设为待虚化区域,目标图像轮廓边缘内的图像不做虚化处理。
需要说明的是,目标图像可以为前景图像,目标图像也可以为前景图像中的一个子图像。例如,前景图像中包括用户A的图像,目标图像可以为整个前景图像,也可以为前景图像中用户A的图像。
105、将待虚化区域虚化。
根据预设算法将待虚化区域虚化,如根据高斯滤波算法将待虚化区域虚化。可以在双摄像头获取图像过程中,将第一预设图像和第二预设图像进行处理,将待虚化区域虚化后的图像展示给用户。也可以先获取第一预设图像和第二预设图像合成后的预设图像后,识别该预设图像中的待虚化区域后,将该待虚化区域虚化形成新的图像。
请参阅图4,图4为本申请实施例提供的图像虚化方法的另一种场景示意图。例如,先获取预设图像201,然后计算预设图像201中各个像素点的景深,并根据各个像素点的景深,得到预设图像中201的前景图像202,然后检测前景图像中目标图像的轮廓边缘,将目标图像的轮廓边缘外的区域设为待虚化区域203,最后将待虚化区域203虚化。
请参阅图5,图5为本申请实施例提供的图像虚化方法的第三种流程示意图。本申请实施例提供的将待虚化区域虚化的步骤,还包括如下流程:
1051、判断目标图像是否为人物图像;
1052、若目标图像为人物图像,则将待虚化区域按第一虚化系数虚化;
1053、若目标图像不为人物图像,则将待虚化区域按第二虚化系数虚化。
通过人脸识别技术是吧目标图像是否为人物图像,因为人物图像与其他区域的关联度较小,为了更加突出人物图像,可以设置较高的虚化系数,而其他图像,如风景图像、物品图像,可以设置较低的虚化系数。即目标图像为人物图像的虚化效果比其他的图像虚化效果更强,针对不同的目标图像按照不同的虚化系数进行虚化。
请参阅图6,图6为本申请实施例提供的图像虚化方法的第四种流程示意图。本申请实施例提供的将待虚化区域虚化的步骤,还包括如下流程:
1054、将待虚化区域划分为位于前景图像中的第一待虚化区域和位于后景图像的第二待虚化区域;
1055、第一待虚化区域按第三虚化系数虚化,第二待虚化区域按第四虚化参数虚化。
待虚化区域包括位于前景图像中的第一待虚化区域和位于后景图像的第二待虚化区域,然后将第一待虚化区域和第二待虚化区域按不同虚化系数进行虚化。如第一待虚化区域的虚化系数小于第二待虚化区域的虚化系数,即第一待虚化区域的虚化强度小于第二待虚化区域,图像的虚化过渡更好。
由上可知,本申请实施例提供的图像虚化方法,通过获取双摄像头拍摄的预设图像;计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像;检测前景图像中目标图像的轮廓边缘;将目标图像的轮廓边缘外的区域设为待虚化区域;将待虚化区域虚化。先通过各个像素点的景深,得到前景图像,再检测前景图像中目标图像的轮廓边缘,根据轮廓边缘进行精确提取待虚化区域,准确的提取目标图像,突出重点,增强立体感。
请参阅图7,图7为本申请实施例提供的图像虚化装置的第一种结构示意图。其中该图像虚化装置500应用于电子设备,该图像虚化装置500包括预设图像获取模块501、前景图像获取模块502、轮廓边缘获取模块503、待虚化区域获取模块504和虚化模块505。其中:
预设图像获取模块501,用于获取双摄像头拍摄的预设图像。
双摄像头可以横向相邻设置在一起,也可以竖向相邻设置。双摄像头可以为电子设备如智能手机的双后置摄像头或双前置摄像头。双摄像头可以一个为彩色摄像头另一个为黑白摄像头,双摄像头也可以采用焦距不一样的摄像头,当然双摄像头也可以采用一样的摄像头。
可以通过本地电子设备获取双摄像头拍摄的预设图像,也可以通过网络、蓝牙的途径获取其他电子设备双摄像头拍摄获取的预设图像。
前景图像获取模块502,用于计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像。
得到预设图像后,计算预设图像中各个像素点的景深。可以通过双摄像头获取两个预设图像,然后根据两个预设图像拍摄角度、焦点位置、拍摄位置、拍摄高度等区别,计算得到两个预设图像中任意一个预设图像各个像素点的景深。
在一些实施例中,还可以通过获取两张预设图像,两张预设图像的拍摄角度、焦点位置、拍摄位置、拍摄高度中至少有一项不一样。然后通过两张预设图像的差异,计算得到两张预设图像中任意一张预设图像中各个像素点的景深。
轮廓边缘获取模块503,用于检测前景图像中目标图像的轮廓边缘。
获取前景图像后,基于预设算法得到该前景图像中的边缘信息,通过该边缘信息选出目标图像,进而得到目标图像的轮廓边缘。
待虚化区域获取模块504,用于将目标图像的轮廓边缘外的区域设为待虚化区域。
得到目标图像的轮廓边缘后,将目标图像轮廓边缘外的区域设为待虚化区域,目标图像轮廓边缘内的图像不做虚化处理。
需要说明的是,目标图像可以为前景图像,目标图像也可以为前景图像中的一个子图像。例如,前景图像中包括用户A的图像,目标图像可以为整个前景图像,也可以为前景图像中用户A的图像。
虚化模块505,用于将待虚化区域虚化。
根据预设算法将待虚化区域虚化,如根据高斯滤波算法将待虚化区域虚化。可以在双摄像头获取图像过程中,将第一预设图像和第二预设图像进行处理,将待虚化区域虚化后的图像展示给用户。也可以先获取第一预设图像和第二预设图像合成后的预设图像后,识别该预设图像中的待虚化区域后,将该待虚化区域虚化形成新的图像。
请参阅图8,图8为本申请实施例提供的图像虚化装置的第二种结构示意图。该实施例中,预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像。双摄摄像头包括第一摄像头和第二摄像头,第一摄像头拍摄获取第一预设图像,第二摄像头拍摄获取第二预设图像,第一预设图像和第二预设图像可以合成为预设图像。
前景图像获取模块502包括特征点集合获取子模块5021、匹配子模块5022和像素点景深获取子模块5023。其中:
特征点集合获取子模块5021,用于提取第一预设图像的第一特征点集合,以及第二预设图像的第二特征点集合。
提取第一预设图像中的特征点形成第一特征点集合,提取第二预设图像中的特征点形成第二特 征点集合。
在一些实施例中,基于尺度不变特征变换算法(Scale-invariant feature transform,SIFT)或加速稳健特征算法(Speeded Up Robust Features,SURF),提取第一预设图像的特征点形成第一特征点集合。
在一些实施例中,基于尺度不变特征变换算法或加速稳健特征算法,提取第二预设图像的特征点形成第二特征点集合。
匹配子模块5022,用于将第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果。
然后将第一特征点集合和第二特征点集合中的特征点进行匹配,确定出第一预设图像和第二预设图像对应的像素点,在某些情况下,在利用双摄像头拍摄第一预设图像和第二预设图像的时候,无法保证第一预设图像与第二预设图像的拍摄位置、拍摄角度和拍摄高度完全相同,可能会存在一定的偏差,所以在此情况下,为了保证第一预设图像与第二预设图像中每个像素点相互对应,需要对第一预设图像和第二预设图像的像素点进行匹配,以确定出第一预设图像与第二预设图像对应的像素点。
像素点景深获取子模块5023,用于根据匹配结果进行像素逐行扫描,计算得到第一预设图像和/或第二预设图像中各个像素点的景深。
确定出第一预设图像与第二预设图像对应的像素点后,对这些像素点进行像素点逐行扫描,计算得到第一预设图像和/或第二预设图像中各个像素点的景深。可以通过对第一预设图像与第二预设图像中每个对应的像素点之间的亮度值进行减法运算得到各个像素点的景深。
在一些实施例中,还可以通过获取两张预设图像,两张预设图像的拍摄角度、焦点位置、拍摄位置、拍摄高度中至少有一项不一样。然后通过两张预设图像的差异,计算得到两张预设图像中任意一张预设图像中各个像素点的景深。
请参阅图9,图9为本申请实施例提供的图像虚化装置的第三种结构示意图。该实施例中,轮廓边缘获取模块503包括构建子模块5031和轮廓边缘获取子模块5032。其中:
构建子模块5031,用于构建边缘检测算子;
轮廓边缘获取子模块5032,用于基于边缘检测算子扫描前景图像,得到前景图像中目标图像的轮廓边缘。
先构建边缘检测算子(Canny),然后基于该边缘检测算子扫描前景图像,得到前景图像中目标图像的轮廓边缘。具体的,先应用高斯滤波来平滑前景图像去除噪声;然后找寻前景图像的强度梯度(intensity gradients);再应用非最大抑制(non-maximum suppression)技术来消除边误检;接着 应用双阈值的方法来决定可能的(潜在的)边界;最后利用滞后技术来跟踪边界。从而得到前景图像中目标图像的轮廓边缘。
需要说明的是,目标图像可以为前景图像,目标图像也可以为前景图像中的一个子图像。例如,前景图像中包括用户A的图像,目标图像可以为整个前景图像,也可以为前景图像中用户A的图像。
请参阅图10,图10为本申请实施例提供的图像虚化装置的第四种结构示意图。该实施例中,虚化模块505包括判断子模块5051、第一虚化子模块5052和第二虚化子模块5053。其中:
判断子模块5051,用于判断目标图像是否为人物图像;
第一虚化子模块5052,用于若目标图像为人物图像,则将待虚化区域按第一虚化系数虚化;
第二虚化子模块5053,用于若目标图像不为人物图像,则将待虚化区域按第二虚化系数虚化。
通过人脸识别技术是吧目标图像是否为人物图像,因为人物图像与其他区域的关联度较小,为了更加突出人物图像,可以设置较高的虚化系数,而其他图像,如风景图像、物品图像,可以设置较低的虚化系数。即目标图像为人物图像的虚化效果比其他的图像虚化效果更强,针对不同的目标图像按照不同的虚化系数进行虚化。
在一些实施例中,虚化模块还可以包括划分子模块和虚化处理子模块。其中划分子模块,用于将待虚化区域划分为位于前景图像中的第一待虚化区域和位于后景图像的第二待虚化区域。虚化处理子模块,用于第一待虚化区域按第三虚化系数虚化,第二待虚化区域按第四虚化参数虚化。
待虚化区域包括位于前景图像中的第一待虚化区域和位于后景图像的第二待虚化区域,然后将第一待虚化区域和第二待虚化区域按不同虚化系数进行虚化。如第一待虚化区域的虚化系数小于第二待虚化区域的虚化系数,即第一待虚化区域的虚化强度小于第二待虚化区域,图像的虚化过渡更好。
由上可知,本申请实施例提供的图像虚化装置,通过获取双摄像头拍摄的预设图像;计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像;检测前景图像中目标图像的轮廓边缘;将目标图像的轮廓边缘外的区域设为待虚化区域;将待虚化区域虚化。先通过各个像素点的景深,得到前景图像,再检测前景图像中目标图像的轮廓边缘,根据轮廓边缘进行精确提取待虚化区域,准确的提取目标图像,突出重点,增强立体感。
具体实施时,以上各个模块可以作为独立的实体来实现,也可以进行任意组合,作为同一或若干个实体来实现,以上各个模块的具体实施可参见前面的方法实施例,在此不再赘述。
本申请实施例中,图像虚化装置与上文实施例中的图像虚化方法属于同一构思,在图像虚化 装置上可以运行图像虚化方法实施例中提供的任一方法,其具体实现过程详见图像虚化方法的实施例,此处不再赘述。
本申请实施例还提供一种电子设备。请参阅图11,电子设备600包括处理器601以及存储器602。其中,处理器601与存储器602电性连接。
处理器600是电子设备600的控制中心,利用各种接口和线路连接整个电子设备的各个部分,通过运行或加载存储在存储器602内的计算机程序,以及调用存储在存储器602内的数据,执行电子设备600的各种功能并处理数据,从而对电子设备600进行整体监控。
存储器602可用于存储软件程序以及单元,处理器601通过运行存储在存储器602的计算机程序以及单元,从而执行各种功能应用以及数据处理。存储器602可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作***、至少一个功能所需的计算机程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据电子设备的使用所创建的数据等。此外,存储器602可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。相应地,存储器602还可以包括存储器控制器,以提供处理器601对存储器602的访问。
在本申请实施例中,电子设备600中的处理器601会按照如下的步骤,将一个或一个以上的计算机程序的进程对应的指令加载到存储器602中,并由处理器601运行存储在存储器602中的计算机程序,从而实现各种功能,如下:
获取双摄像头拍摄的预设图像;
计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像;
检测前景图像中目标图像的轮廓边缘;
将目标图像的轮廓边缘外的区域设为待虚化区域;
将待虚化区域虚化。
在一些实施方式中,处理器601还用于执行以下步骤:
构建边缘检测算子;
基于边缘检测算子扫描前景图像,得到前景图像中目标图像的轮廓边缘。
在一些实施方式中,处理器601还用于执行以下步骤:
预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
提取第一预设图像的第一特征点集合,以及第二预设图像的第二特征点集合;
将第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
根据匹配结果进行像素逐行扫描,计算得到第一预设图像和/或第二预设图像中各个像素点的景深。
处理器601还用于执行以下步骤:
预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
基于尺度不变特征变换算法或加速稳健特征算法,提取第一预设图像的第一特征点集合,以及第二预设图像的第二特征点集合;
基于近似最近邻算法将第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
根据匹配结果进行像素逐行扫描,计算得到第一预设图像和/或第二预设图像中各个像素点的景深。
在一些实施方式中,处理器601还用于执行以下步骤:
判断目标图像是否为人物图像;
若是,则将待虚化区域按第一虚化系数虚化;
若否,则将待虚化区域按第二虚化系数虚化。
在一些实施方式中,处理器601还用于执行以下步骤:
将待虚化区域划分为位于前景图像中的第一待虚化区域和位于后景图像的第二待虚化区域;
第一待虚化区域按第三虚化系数虚化,第二待虚化区域按第四虚化参数虚化。
由上述可知,本申请实施例提供的电子设备,通过获取双摄像头拍摄的预设图像;计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像;检测前景图像中目标图像的轮廓边缘;将目标图像的轮廓边缘外的区域设为待虚化区域;将待虚化区域虚化。先通过各个像素点的景深,得到前景图像,再检测前景图像中目标图像的轮廓边缘,根据轮廓边缘进行精确提取待虚化区域,准确的提取目标图像,突出重点,增强立体感。
请一并参阅图12,在一些实施方式中,电子设备600还可以包括:显示器603、射频电路604、音频电路605以及电源606。其中,其中,显示器603、射频电路604、音频电路605以及电源606分别与处理器601电性连接。
显示器603可以用于显示由用户输入的信息或提供给用户的信息以及各种图形用户接口,这些图形用户接口可以由图形、文本、图标、视频和其任意组合来构成。显示器603可以包括显示面板,在一些实施方式中,可以采用液晶显示器(Liquid Crystal Display,LCD)、或者有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板。
射频电路604可以用于收发射频信号,以通过无线通信与网络设备或其他电子设备建立无线 通讯,与网络设备或其他电子设备之间收发信号。
音频电路605可以用于通过扬声器、传声器提供用户与电子设备之间的音频接口。
电源606可以用于给电子设备600的各个部件供电。在一些实施方式中,电源606可以通过电源管理***与处理器601逻辑相连,从而通过电源管理***实现管理充电、放电、以及功耗管理等功能。
尽管图12中未示出,电子设备600还可以包括摄像头、蓝牙单元等,在此不再赘述。
可以理解的是,本申请实施例的电子设备可以是诸如智能手机或平板电脑等终端设备。
本申请实施例还提供一种存储介质,存储介质存储有计算机程序,当计算机程序在计算机上运行时,使得计算机执行上述任一实施例中的图像虚化方法,比如:通过获取双摄像头拍摄的预设图像;计算预设图像中各个像素点的景深,并根据各个像素点的景深,得到预设图像中的前景图像;检测前景图像中目标图像的轮廓边缘;将目标图像的轮廓边缘外的区域设为待虚化区域;将待虚化区域虚化。
在本申请实施例中,存储介质可以是磁碟、光盘、只读存储器(Read Only Memory,ROM)、或者随机存取记忆体(Random Access Memory,RAM)等。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。
需要说明的是,对本申请实施例的图像虚化方法而言,本领域普通测试人员可以理解实现本申请实施例图像虚化方法的全部或部分流程,是可以通过计算机程序来控制相关的硬件来完成,计算机程序可存储于一计算机可读取存储介质中,如存储在电子设备的存储器中,并被该电子设备内的至少一个处理器执行,在执行过程中可包括如图像虚化方法的实施例的流程。其中,的存储介质可为磁碟、光盘、只读存储器、随机存取记忆体等。
对本申请实施例的图像虚化装置而言,其各功能单元可以集成在一个处理芯片中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,也可以存储在一个计算机可读取存储介质中,存储介质譬如为只读存储器,磁盘或光盘等。
以上对本发明实施例所提供的一种图像虚化方法、存储介质及电子设备进行了详细介绍,本文中应用程序了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想;同时,对于本领域的技术人员,依据本发明的思想,在具体实施 方式及应用程序范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。

Claims (20)

  1. 一种图像虚化方法,应用于电子设备,其中,所述方法包括:
    获取双摄像头拍摄的预设图像;
    计算所述预设图像中各个像素点的景深,并根据所述各个像素点的景深,得到所述预设图像中的前景图像;
    检测所述前景图像中目标图像的轮廓边缘;
    将所述目标图像的轮廓边缘外的区域设为待虚化区域;
    将所述待虚化区域虚化。
  2. 如权利要求1所述的图像虚化方法,其中,所述检测所述前景图像中目标图像的轮廓边缘包括:
    构建边缘检测算子;
    基于所述边缘检测算子扫描所述前景图像,得到所述前景图像中目标图像的轮廓边缘。
  3. 如权利要求2所述的图像虚化方法,其中,所述基于所述边缘检测算子扫描所述前景图像,得到所述前景图像中目标图像的轮廓边缘包括:
    应用高斯滤波平滑所述前景图像;
    获取高斯滤波后的前景图像的强度梯度;
    对获取强度梯度后的前景图像应用非最大抑制算法;
    应用双阈值算法决定非最大抑制算法处理后的前景图像的边界;
    利用滞后算法跟踪所述边界,得到所述前景图像中目标图像的轮廓边缘。
  4. 如权利要求1所述的图像虚化方法,其中,所述计算所述预设图像中各个像素点的景深包括:
    所述预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
    提取所述第一预设图像的第一特征点集合,以及所述第二预设图像的第二特征点集合;
    将所述第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
    根据所述匹配结果进行像素逐行扫描,计算得到所述第一预设图像和/或所述第二预设图像中各个像素点的景深。
  5. 如权利要求4所述的图像虚化方法,其中,所述将所述待虚化区域虚化包括:
    将所述第一预设图像和所述第二预设图像合成后的预设图像显示;
    获取所述预设图像中的待虚化区域,将所述预设图像的所述待虚化区域虚化显示。
  6. 如权利要求1所述的图像虚化方法,其中,所述将所述待虚化区域虚化之后还包括:
    将虚化后的预设图像显示。
  7. 如权利要求1所述的图像虚化方法,其中,所述计算所述预设图像中各个像素点的景深包括:
    所述预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
    基于尺度不变特征变换算法或加速稳健特征算法,提取所述第一预设图像的第一特征点集合,以及所述第二预设图像的第二特征点集合;
    基于近似最近邻算法将所述第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
    根据所述匹配结果进行像素逐行扫描,计算得到所述第一预设图像和/或所述第二预设图像中各个像素点的景深。
  8. 如权利要求1所述的图像虚化方法,其中,所述计算所述预设图像中各个像素点的景深包括:
    通过所述双摄像头中第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
    根据所述第一摄像头和所述第二摄像头不同的拍摄角度、焦点位置、拍摄位置和拍摄高度中的至少一项,计算得到所述第一预设图像和所述第二预设图像中各个像素点的景深。
  9. 如权利要求1所述的图像虚化方法,其中,所述将所述待虚化区域虚化包括:
    判断所述目标图像是否为人物图像;
    若是,则将所述待虚化区域按第一虚化系数虚化;
    若否,则将所述待虚化区域按第二虚化系数虚化,其中,第一虚化系数大于所述第二虚化系数。
  10. 如权利要求1所述的图像虚化方法,其中,所述预设图像还包括后景图像;将所述待虚化区域虚化包括:
    将所述待虚化区域划分为位于所述前景图像中的第一待虚化区域和位于所述后景图像的第二待虚化区域;
    所述第一待虚化区域按第三虚化系数虚化,所述第二待虚化区域按第四虚化参数虚化。
  11. 一种存储介质,其中,所述存储介质中存储有多条指令,所述指令适于由处理器加载以执行如权利要求1-10中任一项所述的图像虚化方法。
  12. 一种电子设备,包括处理器和存储器,所述存储器存储有计算机程序,所述处理器与所述存储器连接,所述处理器通过调用所述计算机程序,所述处理器执行:
    获取双摄像头拍摄的预设图像;
    计算所述预设图像中各个像素点的景深,并根据所述各个像素点的景深,得到所述预设图像中的前景图像;
    检测所述前景图像中目标图像的轮廓边缘;
    将所述目标图像的轮廓边缘外的区域设为待虚化区域;
    将所述待虚化区域虚化。
  13. 根据权利要求12所述的电子设备,其中,在检测所述前景图像中目标图像的轮廓边缘中,所述处理器还执行:
    构建边缘检测算子;
    基于所述边缘检测算子扫描所述前景图像,得到所述前景图像中目标图像的轮廓边缘。
  14. 根据权利要求13所述的电子设备,其中,在基于所述边缘检测算子扫描所述前景图像,得到所述前景图像中目标图像的轮廓边缘中,所述处理器还执行:
    应用高斯滤波平滑所述前景图像;
    获取高斯滤波后的前景图像的强度梯度;
    对获取强度梯度后的前景图像应用非最大抑制算法;
    应用双阈值算法决定非最大抑制算法处理后的前景图像的边界;
    利用滞后算法跟踪所述边界,得到所述前景图像中目标图像的轮廓边缘。
  15. 根据权利要求12所述的电子设备,其中,在计算所述预设图像中各个像素点的景深中,所述处理器还执行:
    所述预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
    提取所述第一预设图像的第一特征点集合,以及所述第二预设图像的第二特征点集合;
    将所述第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
    根据所述匹配结果进行像素逐行扫描,计算得到所述第一预设图像和/或所述第二预设图像中各个像素点的景深。
  16. 根据权利要求15所述的电子设备,其中,在将所述待虚化区域虚化中,所述处理器还执行:
    将所述第一预设图像和所述第二预设图像合成后的预设图像显示;
    获取所述预设图像中的待虚化区域,将所述预设图像的所述待虚化区域虚化显示。
  17. 根据权利要求12所述的电子设备,其中,在计算所述预设图像中各个像素点的景深中,所述处理器还执行:
    所述预设图像包括第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
    基于尺度不变特征变换算法或加速稳健特征算法,提取所述第一预设图像的第一特征点集合,以及所述第二预设图像的第二特征点集合;
    基于近似最近邻算法将所述第一特征点集合和第二特征点集合中的特征点进行匹配,得到匹配结果;
    根据所述匹配结果进行像素逐行扫描,计算得到所述第一预设图像和/或所述第二预设图像中各个像素点的景深。
  18. 根据权利要求12所述的电子设备,其中,在计算所述预设图像中各个像素点的景深中,所述处理器还执行:
    通过所述双摄像头中第一摄像头获取的第一预设图像,以及第二预设摄像头获取的第二预设图像;
    根据所述第一摄像头和所述第二摄像头不同的拍摄角度、焦点位置、拍摄位置和拍摄高度中的至少一项,计算得到所述第一预设图像和所述第二预设图像中各个像素点的景深。
  19. 根据权利要求12所述的电子设备,其中,在将所述待虚化区域虚化中,所述处理器还执行:
    判断所述目标图像是否为人物图像;
    若是,则将所述待虚化区域按第一虚化系数虚化;
    若否,则将所述待虚化区域按第二虚化系数虚化,其中,第一虚化系数大于所述第二虚化系数。
  20. 根据权利要求12所述的电子设备,其中,在预设图像还包括后景图像;将所述待虚化区域虚化中,所述处理器还执行:
    将所述待虚化区域划分为位于所述前景图像中的第一待虚化区域和位于所述后景图像的第二待虚化区域;
    所述第一待虚化区域按第三虚化系数虚化,所述第二待虚化区域按第四虚化参数虚化。
PCT/CN2018/121815 2018-01-05 2018-12-18 图像虚化方法、存储介质及电子设备 WO2019134505A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810012080.0 2018-01-05
CN201810012080.0A CN110009555B (zh) 2018-01-05 2018-01-05 图像虚化方法、装置、存储介质及电子设备

Publications (1)

Publication Number Publication Date
WO2019134505A1 true WO2019134505A1 (zh) 2019-07-11

Family

ID=67144046

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/121815 WO2019134505A1 (zh) 2018-01-05 2018-12-18 图像虚化方法、存储介质及电子设备

Country Status (2)

Country Link
CN (1) CN110009555B (zh)
WO (1) WO2019134505A1 (zh)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113965663A (zh) * 2020-07-21 2022-01-21 深圳Tcl新技术有限公司 一种图像画质优化方法、智能终端及存储介质
CN113344997B (zh) * 2021-06-11 2022-07-26 方天圣华(北京)数字科技有限公司 快速获取只含有目标对象的高清前景图的方法及***
CN113489903A (zh) * 2021-07-02 2021-10-08 惠州Tcl移动通信有限公司 一种拍摄方法、装置、终端设备及存储介质
CN113610884A (zh) * 2021-07-08 2021-11-05 Oppo广东移动通信有限公司 图像处理方法、装置、电子设备及计算机可读存储介质
CN114339071A (zh) * 2021-12-28 2022-04-12 维沃移动通信有限公司 图像处理电路、图像处理方法及电子设备

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105245774A (zh) * 2015-09-15 2016-01-13 努比亚技术有限公司 一种图片处理方法及终端
CN105979165A (zh) * 2016-06-02 2016-09-28 广东欧珀移动通信有限公司 虚化照片生成方法、装置和移动终端
WO2017016050A1 (zh) * 2015-07-24 2017-02-02 青岛海信移动通信技术股份有限公司 一种图像的预览方法、装置及终端
CN106899781A (zh) * 2017-03-06 2017-06-27 宇龙计算机通信科技(深圳)有限公司 一种图像处理方法及电子设备

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101764925B (zh) * 2008-12-25 2011-07-13 华晶科技股份有限公司 数字图像的浅景深模拟方法
US9124762B2 (en) * 2012-12-20 2015-09-01 Microsoft Technology Licensing, Llc Privacy camera
CN104751405B (zh) * 2015-03-11 2018-11-13 百度在线网络技术(北京)有限公司 一种用于对图像进行虚化的方法和装置
CN107454332B (zh) * 2017-08-28 2020-03-10 厦门美图之家科技有限公司 图像处理方法、装置及电子设备

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017016050A1 (zh) * 2015-07-24 2017-02-02 青岛海信移动通信技术股份有限公司 一种图像的预览方法、装置及终端
CN105245774A (zh) * 2015-09-15 2016-01-13 努比亚技术有限公司 一种图片处理方法及终端
CN105979165A (zh) * 2016-06-02 2016-09-28 广东欧珀移动通信有限公司 虚化照片生成方法、装置和移动终端
CN106899781A (zh) * 2017-03-06 2017-06-27 宇龙计算机通信科技(深圳)有限公司 一种图像处理方法及电子设备

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
CHEN, ZHAOXIA: "Hough (The Application of Hough Transform in Human Head Detection)", JOURNAL OF JIAMUSI UNIVERSITY ( NATURAL SCIENCE EDITION ), vol. 26, no. 6, 30 November 2008 (2008-11-30), pages 756, ISSN: 1008-1402 *

Also Published As

Publication number Publication date
CN110009555A (zh) 2019-07-12
CN110009555B (zh) 2020-08-14

Similar Documents

Publication Publication Date Title
WO2019134505A1 (zh) 图像虚化方法、存储介质及电子设备
EP3614334B1 (en) Method for image processing and electronic device
US11410277B2 (en) Method and device for blurring image background, storage medium and electronic apparatus
EP3614333B1 (en) Image processing method, storage medium, and electronic apparatus
US9071745B2 (en) Automatic capturing of documents having preliminarily specified geometric proportions
JP6392468B2 (ja) 領域認識方法及び装置
CN110691193B (zh) 摄像头切换方法、装置、存储介质及电子设备
WO2017107700A1 (zh) 一种实现图像配准的方法及终端
US10853927B2 (en) Image fusion architecture
WO2019071613A1 (zh) 一种图像处理方法及装置
US11138709B2 (en) Image fusion processing module
US11538175B2 (en) Method and apparatus for detecting subject, electronic device, and computer readable storage medium
EP3644599A1 (en) Video processing method and apparatus, electronic device, and storage medium
WO2013145589A1 (ja) 画像処理装置、撮像装置および画像処理方法
KR20110124965A (ko) 아웃 포커싱 촬영에서 빛망울 효과를 생성하기 위한 장치 및 방법
US20130201358A1 (en) Efficient Line Detection Method
CN105578023A (zh) 一种快速拍摄图像方法及装置
CN109726613B (zh) 一种用于检测的方法和装置
CN111885371A (zh) 图像遮挡检测方法、装置、电子设备和计算机可读介质
CN106469446B (zh) 深度图像的分割方法和分割装置
JP2018189536A (ja) 画像処理装置、実寸法表示方法、及び実寸法表示処理プログラム
CN110012208B (zh) 拍照对焦方法、装置、存储介质及电子设备
TWI526987B (zh) 基於涵蓋視覺內容最大化之即時影像拼接方法
CN114119609B (zh) 图像污点浓度的检测方法、装置、设备及存储介质
CN113327290B (zh) 双目模组标定方法、装置、存储介质及电子设备

Legal Events

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

Ref document number: 18898620

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18898620

Country of ref document: EP

Kind code of ref document: A1