WO2022001648A1 - Image processing method and apparatus, and device and medium - Google Patents

Image processing method and apparatus, and device and medium Download PDF

Info

Publication number
WO2022001648A1
WO2022001648A1 PCT/CN2021/100019 CN2021100019W WO2022001648A1 WO 2022001648 A1 WO2022001648 A1 WO 2022001648A1 CN 2021100019 W CN2021100019 W CN 2021100019W WO 2022001648 A1 WO2022001648 A1 WO 2022001648A1
Authority
WO
WIPO (PCT)
Prior art keywords
area
image
target object
change trend
contrast value
Prior art date
Application number
PCT/CN2021/100019
Other languages
French (fr)
Chinese (zh)
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 维沃移动通信有限公司
Publication of WO2022001648A1 publication Critical patent/WO2022001648A1/en

Links

Images

Classifications

    • 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
    • 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

Definitions

  • the present application belongs to the technical field of image processing, and in particular relates to an image processing method, apparatus, device and medium.
  • Matting is one of the most common operations in image processing, which is to separate a certain part of an image from the image.
  • a lasso tool, a marquee tool, a magic wand tool, a pen tool, etc. are usually used to manually cut out the image.
  • the purpose of the embodiments of the present application is to provide an image processing method, apparatus, device, and medium, which can solve the problem of inaccurate matting.
  • an embodiment of the present application provides an image processing method, including:
  • N images are images captured by the image acquisition component at different focusing distances
  • the pixel contrast value determine the coordinate information of the target object in the target image, wherein the target image is an image in N images;
  • an image processing apparatus including:
  • a first acquisition module configured to acquire N images, wherein the N images are images captured by the image acquisition component at different focusing distances;
  • a division module for dividing each of the N images into M regions
  • the second acquisition module is used to acquire the pixel contrast value of each area of each image
  • a determining module configured to determine the coordinate information of the target object in the target image according to the pixel contrast value, wherein the target image is an image in N images;
  • the third acquiring module is used for acquiring the target object in the target image according to the coordinate information.
  • embodiments of the present application provide an electronic device, the electronic device includes a processor, a memory, and a program or instruction stored on the memory and executable on the processor, the program or instruction being The processor implements the steps of the method according to the first aspect when executed.
  • an embodiment of the present application provides a computer-readable storage medium, where a program or an instruction is stored on the computer-readable storage medium, and when the program or instruction is executed by a processor, the method according to the first aspect is implemented A step of.
  • an embodiment of the present application provides a chip, the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is configured to run a program or an instruction, and implement the first aspect the steps of the method.
  • each of the N images is divided into M areas, and the coordinate information of the target object in the target image is determined according to the pixel contrast value of each area of each image, and according to the coordinate information, Obtaining the target object in the target image is to realize the matting of the target object.
  • the embodiment of the present application can automatically cut out the target object, which can improve the accuracy of the image cutout.
  • FIG. 1 is a schematic flowchart of an image processing method provided by an embodiment of the present application.
  • FIG. 2 is a schematic diagram of a target shooting scene provided by an embodiment of the present application.
  • FIG. 3 is a schematic diagram of N images provided by an embodiment of the present application.
  • FIG. 6 is a schematic diagram of sub-regional display of objects provided by an embodiment of the present application.
  • FIG. 7 is a schematic diagram of a processed target image provided by an embodiment of the present application.
  • FIG. 8 is a schematic structural diagram of an image processing apparatus provided by an embodiment of the present application.
  • FIG. 9 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application.
  • FIG. 1 is a schematic flowchart of an image processing method provided by an embodiment of the present application. As shown in Figure 1, the image processing method may include:
  • S101 Acquire N images, where the N images are images captured by the image acquisition component at different focusing distances;
  • S104 determine the coordinate information of the target object in the target image according to the pixel contrast value, wherein the target image is the image in the N images;
  • S105 Acquire the target object in the target image according to the coordinate information.
  • the execution subject may be an image processing apparatus, or a control module in the image processing apparatus for executing the image processing method.
  • an image processing method performed by an image processing apparatus is used as an example to describe the image processing method provided by the embodiments of the present application.
  • the image processing device acquires N images; divides each image in the N images into M areas; acquires the pixel contrast value of each area of each image; determines the coordinates of the target object in the target image according to the pixel contrast value information; obtain the target object in the target image according to the coordinate information.
  • each of the N images is divided into M areas, and the coordinate information of the target object in the target image is determined according to the pixel contrast value of each area of each image, and according to the coordinate information, Obtaining the target object in the target image is to realize the matting of the target object.
  • the embodiment of the present application can automatically cut out the target object, which can improve the accuracy of the image cutout.
  • the image acquisition component may be a single image acquisition component.
  • a single image acquisition component is used to collect N images of the target shooting scene in the process of gradually changing the focus distance, and each image in the N images is divided into M areas;
  • the pixel contrast value of each area determines the coordinate information of the target object in the target image, and obtains the target object in the target image according to the coordinate information. That is, the matting of the target object is realized, and the accuracy of the matting can be improved.
  • the change trend of the focus distance may be a gradual change from small to large, or a gradual change from large to small.
  • Focusing distance refers to the distance between objects and images, which is the sum of the distance from the lens to the object and the distance from the lens to the photosensitive element.
  • FIG. 2 is a schematic diagram of a target shooting scene provided by an embodiment of the present application.
  • N images of the scene captured by the target shown in FIG. 2 in the process of gradually changing the focus distance are collected by using the image collection component, as shown in FIG. 3 .
  • FIG. 3 is a schematic diagram of N images provided by an embodiment of the present application. Among them, Figure 3 shows four schematic diagrams of images.
  • FIG. 4 is a schematic diagram of area division provided by an embodiment of the present application. Among them, each square in Figure 4 represents an area.
  • each of the multiple regions obtained by dividing in S102 may include multiple pixels.
  • the pixel contrast value of the area may be the sum of the pixel contrast values of each pixel in the multiple pixels included in the area.
  • the pixel contrast value refers to the color difference between adjacent pixels.
  • each of the multiple regions obtained by dividing in S102 may include only one pixel.
  • the pixel contrast value of the area may be the pixel contrast value of one pixel included in the area.
  • each area includes only one pixel, that is, the image is divided according to the pixel granularity, so that the coordinates of the target object in the target object can be more accurate, and thus the accuracy of the map can be achieved.
  • S104 may include: classifying the M regions according to the change trend of the pixel contrast value and the change trend of the focus distance, and obtain a classification result; according to the classification result, determine that the target object is in the target image coordinate information in .
  • the change trend of the pixel contrast value includes but is not limited to: from large to small, from small to large, from large to small and then from small to large, and from small to large and then from large to small .
  • the changing trend of the focusing distance includes, but is not limited to: from large to small and from small to large.
  • classifying the M regions according to the change trend of the pixel contrast value and the change trend of the focus distance, and obtaining the classification result may include: classifying the first region in the M regions into a classification result.
  • the class is the background area, wherein the change trend of the pixel contrast value of the first area is the same as the change trend of the focus distance; the second area in the M areas is classified as the foreground area, wherein the pixel contrast value of the second area is the same.
  • the change trend of is opposite to that of the focus distance; the third area in the M areas is classified as the main area, wherein the change trend of the pixel contrast value of the third area and the change trend of the focus distance are the same first and then opposite.
  • the change trend of the pixel contrast value of the third area and the change trend of the focus distance are opposite first and then the same.
  • the target object includes: at least one of a background area, a foreground area and a subject area.
  • FIG. 5 is a schematic diagram of a result of region classification provided by an embodiment of the present application.
  • the rate of change of the pixel contrast values of the background area, the foreground area, and the main body area may be different.
  • the M regions may also be classified according to the change rate of the pixel contrast value and the change trend of the focus distance to obtain a classification result.
  • the areas in the M areas with the pixel contrast value change rate greater than the first rate are classified as foreground areas; the pixel contrast value change rate in the M areas is smaller than the second rate.
  • the area is classified as a background area; the area in which the pixel contrast value change rate in the M areas is between the second rate and the first rate is classified as the main area, wherein the first rate is greater than the second rate.
  • the areas in the M areas with the change rate of the pixel contrast value greater than the third rate are classified as the background area; the areas in the M areas with the change rate of the pixel contrast value less than the fourth rate are classified as the background area. is the foreground area; the area where the pixel contrast value change rate in the M areas is between the fourth rate and the third rate is classified as the main area, wherein the third rate is greater than the fourth rate.
  • the target image may be an image focusing on the target object among the N images, that is, the target object may be an image focusing on the target object among the N images.
  • the target object is the main area
  • the pixel contrast value of the target object increases from small to large, and then from large to small. Therefore, the image corresponding to the maximum pixel contrast value of the target object can be determined as the target image. It can be understood that when the pixel contrast value of the target object is at the maximum value, the focus of the image acquisition component is just on the target object, that is, the image acquisition component takes the target object as the focus.
  • the image processing method provided by the embodiments of the present application may further include: performing first processing on the target object in the target image, and/or, performing the first processing on the target object in the target image except the target object.
  • the other objects perform the second processing.
  • the embodiments of the present application do not limit the specific processing manners of the first processing and the second processing, and any available processing manners can be applied to the embodiments of the present application.
  • any available processing manners can be applied to the embodiments of the present application.
  • color burn processing color gradient processing, soft light processing, sharpening processing, oil painting processing and color pencil processing and so on.
  • the first processing and the second processing may be set according to actual requirements.
  • the first processing may be a beauty processing.
  • the second processing may be blurring processing.
  • the target object when the target object is the main body region, the target object can be made clearer by performing blurring processing on other regions except the main body region in the target image.
  • the image processing method provided by the embodiments of the present application may further include: displaying the target object in the fourth area of the screen; displaying the target image in the fifth area of the screen except the target object other objects. That is, the target object in the target image is separated from other objects in the target image except the target object. Then, the second processing is performed on the target object displayed in the fourth area and the objects other than the target object in the target image displayed in the fifth area, respectively.
  • FIG. 6 is a schematic diagram of displaying objects in sub-regions provided by an embodiment of the present application.
  • the target object is the main area, and other objects except the target object are the background area and the foreground area.
  • the target objects displayed in the fourth area of the screen can be respectively and performing the second processing on other objects other than the target object in the target image displayed in the fifth area of the screen, to avoid processing the target object and other objects other than the target object in the target image on the target image, Mishandling the target object or objects other than the target object in the target image.
  • the image processing method provided by the embodiments of the present invention may further include: combining the target object displayed in the fourth area that has undergone the first processing and the target object displayed in the fifth area that has undergone the second processing. Other objects in the target image except the target object are merged to obtain the processed target image.
  • the target object and other objects other than the target object in the target image are displayed in sub-regions, as shown in FIG. 6 .
  • the first processing may be performed on the target object displayed in the fourth area, and/or the target object displayed in the fifth area except the target object may be subjected to the first processing.
  • the second processing is performed on other objects other than the object.
  • the two processed objects are merged to obtain the processed target image, as shown in Figure 7 .
  • FIG. 7 is a schematic diagram of a processed target image provided by an embodiment of the present application.
  • the object in the target image, "the main area, the background area, and the foreground area” may also be displayed in three areas. Then, at least one object among the objects displayed in the sub-regions is processed, and after the object processing is completed, the three objects can be combined again to obtain a processed target image.
  • FIG. 8 is a schematic structural diagram of an image processing apparatus provided by an embodiment of the present application. As shown in FIG. 8 , the image processing apparatus 800 may include:
  • the first acquisition module 801 is configured to acquire N images, wherein the N images are images captured by the image acquisition component at different focusing distances;
  • a dividing module 802 configured to divide each of the N images into M regions
  • the second acquisition module 803 is used to acquire the pixel contrast value of each area of each image
  • Determining module 804 is used to determine the coordinate information of the target object in the target image according to the pixel contrast value, wherein the target image is the image in the N images;
  • the third obtaining module 805 is configured to obtain the target object in the target image according to the coordinate information.
  • each of the N images is divided into M areas, and the coordinate information of the target object in the target image is determined according to the pixel contrast value of each area of each image, and according to the coordinate information, Obtaining the target object in the target image is to realize the matting of the target object.
  • the embodiment of the present application can automatically cut out the target object, which can improve the accuracy of the image cutout.
  • the determining module 804 may include:
  • the classification sub-module is used to classify the M areas according to the change trend of the pixel contrast value and the change trend of the focus distance, and obtain the classification result;
  • the determining sub-module is used for determining the coordinate information of the target object in the target image according to the classification result.
  • the classification submodule may be specifically used for:
  • the first area in the M areas is classified as a background area, wherein the change trend of the pixel contrast value of the first area is the same as the change trend of the focus distance;
  • the third area in the M areas is classified as the main area, wherein the change trend of the pixel contrast value of the third area and the change trend of the focus distance are the same first and then opposite, or the change of the pixel contrast value of the third area.
  • the trend and the change trend of focus distance are opposite first and then the same;
  • the target object includes: at least one of a background area, a foreground area and a subject area.
  • the image processing apparatus 800 may further include:
  • the display module is used for displaying the target object in the fourth area of the screen, and displaying other objects in the target image except the target object in the fifth area of the screen.
  • the target image may be an image with the target object as the focus among the N images.
  • the image processing apparatus in this embodiment of the present application may be an apparatus, or may be a component, an integrated circuit, or a chip in a terminal.
  • the apparatus may be a mobile electronic device or a non-mobile electronic device.
  • the mobile electronic device may be a mobile phone, a tablet computer, a notebook computer, a palmtop computer, an in-vehicle electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (personal digital assistant).
  • UMPC ultra-mobile personal computer
  • PDA personal digital assistant
  • non-mobile electronic devices can be servers, network attached storage (Network Attached Storage, NAS), personal computer (personal computer, PC), television (television, TV), teller machine or self-service machine, etc., this application Examples are not specifically limited.
  • the image processing apparatus in this embodiment of the present application may be an apparatus having an operating system.
  • the operating system may be an Android (Android) operating system, an ios operating system, or other possible operating systems, which are not specifically limited in the embodiments of the present application.
  • the image processing apparatus provided in the embodiments of the present application can implement each process in the image processing method embodiments shown in FIG. 1 to FIG. 7 , and in order to avoid repetition, details are not repeated here.
  • FIG. 9 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application.
  • the electronic device 900 includes but is not limited to: a radio frequency unit 901 , a network module 902 , an audio output unit 903 , an input unit 904 , a sensor 905 , a display unit 906 , a user input unit 907 , an interface unit 908 , and a memory 909 , and components such as the processor 910 .
  • the input unit 904 may include a graphics processor 9041 and a microphone 9042 .
  • the display unit 906 may include a display panel 9061 .
  • the user input unit 907 includes a touch panel 9071 and other input devices 9072 .
  • the memory 909 may be used to store software programs as well as various data.
  • the memory 909 may mainly include a stored program area and a stored data area, wherein the stored program area may store an operating system, an application program required for at least one function (such as a sound playback function, an image playback function, etc.), and the like.
  • the electronic device 900 may also include a power supply (such as a battery) for supplying power to various components, and the power supply may be logically connected to the processor 910 through a power management system, so that the power management system can manage charging, discharging, and power management. consumption management and other functions.
  • a power supply such as a battery
  • the structure of the electronic device shown in FIG. 9 does not constitute a limitation to the electronic device.
  • the electronic device may include more or less components than the one shown, or combine some components, or arrange different components, which will not be repeated here. .
  • the processor 910 is configured to: acquire N images, where the N images are images captured by the image acquisition component at different focusing distances; divide each of the N images into M regions; acquire each image The pixel contrast value of each area of then; according to the pixel contrast value, determine the coordinate information of the target object in the target image, wherein the target image is an image in N images; according to the coordinate information, obtain the target object in the target image.
  • each of the N images is divided into M areas, and the coordinate information of the target object in the target image is determined according to the pixel contrast value of each area of each image, and according to the coordinate information, Obtaining the target object in the target image is to realize the matting of the target object.
  • the embodiments of the present application can automatically perform image matting on the target object, which can improve the accuracy of image matting.
  • the processor 910 may be specifically configured to:
  • the M areas are classified, and the classification result is obtained;
  • the coordinate information of the target object in the target image is determined.
  • the processor 910 may be specifically configured to:
  • the first area in the M areas is classified as a background area, wherein the change trend of the pixel contrast value of the first area is the same as the change trend of the focus distance;
  • the third area in the M areas is classified as the main area, wherein the change trend of the pixel contrast value of the third area and the change trend of the focus distance are the same first and then opposite, or the change of the pixel contrast value of the third area.
  • the trend and the change trend of focus distance are opposite first and then the same;
  • the target object includes: at least one of a background area, a foreground area and a subject area.
  • the display unit 906 may be used for:
  • the target object is displayed in the fourth area of the screen, and other objects in the target image except the target object are displayed in the fifth area of the screen.
  • an embodiment of the present application further provides an electronic device, including a processor 910, a memory 909, a program or instruction stored in the memory 909 and executable on the processor 910, the program or instruction being processed by the processor
  • an electronic device including a processor 910, a memory 909, a program or instruction stored in the memory 909 and executable on the processor 910, the program or instruction being processed by the processor
  • 910 When 910 is executed, each process of the above image processing method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, details are not described here.
  • the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.
  • Embodiments of the present invention further provide an electronic device configured to execute each process of the above image processing method embodiments, and can achieve the same technical effect, which is not repeated here to avoid repetition.
  • Embodiments of the present application further provide a computer-readable storage medium, where a program or an instruction is stored on the computer-readable storage medium, and when the program or instruction is executed by a processor, each process of the above image processing method embodiment is implemented, and can To achieve the same technical effect, in order to avoid repetition, details are not repeated here.
  • the processor is the processor in the electronic device described in the foregoing embodiments.
  • Examples of the computer-readable storage medium include non-transitory computer-readable storage media, such as computer read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disk or optical disk, etc. .
  • An embodiment of the present application further provides a chip, where the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is configured to run a program or an instruction to implement the above image processing method embodiments.
  • the chip includes a processor and a communication interface
  • the communication interface is coupled to the processor
  • the processor is configured to run a program or an instruction to implement the above image processing method embodiments.
  • An embodiment of the present invention further provides a computer program product, which can be executed by a processor to implement the various processes of the above image processing method embodiments, and can achieve the same technical effect. To avoid repetition, details are not repeated here. .
  • the chip mentioned in the embodiments of the present application may also be referred to as a system-on-chip, a system-on-chip, a system-on-a-chip, or a system-on-a-chip, or the like.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Studio Devices (AREA)

Abstract

Provided are an image processing method and apparatus, and a device and a medium, which belong to the technical field of image processing. The image processing method comprises: acquiring N images, wherein the N images are images photographed by an image collection component at different focusing distances; dividing each of the N images into M areas; acquiring a pixel contrast value of each area of each image; determining coordinate information of a target object in a target image according to a pixel contrast value, wherein the target image is an image among the N images; and acquiring the target object in the target image according to the coordinate information.

Description

图像处理方法、装置、设备及介质Image processing method, apparatus, equipment and medium
相关申请的交叉引用CROSS-REFERENCE TO RELATED APPLICATIONS
本申请主张在2020年06月30日在中国提交的中国专利申请号202010611475.X的优先权,其全部内容通过引用包含于此。This application claims priority to Chinese Patent Application No. 202010611475.X filed in China on Jun. 30, 2020, the entire contents of which are incorporated herein by reference.
技术领域technical field
本申请属于图像处理技术领域,具体涉及一种图像处理方法、装置、设备及介质。The present application belongs to the technical field of image processing, and in particular relates to an image processing method, apparatus, device and medium.
背景技术Background technique
抠图是图像处理中最常做的操作之一,是把图像中的某一部分从该图像中分离出来。相关技术中通常是人为通过采用套索工具、选框工具、魔术棒工具或钢笔工具等进行抠图。Matting is one of the most common operations in image processing, which is to separate a certain part of an image from the image. In the related art, a lasso tool, a marquee tool, a magic wand tool, a pen tool, etc. are usually used to manually cut out the image.
但是,在实现本申请过程中,发明人发现相关技术中至少存在如下问题:抠图不准确。However, in the process of realizing the present application, the inventor found that there are at least the following problems in the related art: the cutout is inaccurate.
发明内容SUMMARY OF THE INVENTION
本申请实施例的目的是提供一种图像处理方法、装置、设备及介质,能够解决抠图不准确的问题。The purpose of the embodiments of the present application is to provide an image processing method, apparatus, device, and medium, which can solve the problem of inaccurate matting.
为了解决上述技术问题,本申请是这样实现的:In order to solve the above technical problems, this application is implemented as follows:
第一方面,本申请实施例提供了一种图像处理方法,包括:In a first aspect, an embodiment of the present application provides an image processing method, including:
获取N个图像,其中,N个图像为图像采集组件在不同对焦距离下拍摄的图像;acquiring N images, wherein the N images are images captured by the image acquisition component at different focusing distances;
将N个图像中的每个图像划分为M个区域;Divide each of the N images into M regions;
获取每个图像的每个区域的像素反差值;Get the pixel contrast value of each area of each image;
根据像素反差值,确定目标对象在目标图像中的坐标信息,其中,目 标图像为N个图像中的图像;According to the pixel contrast value, determine the coordinate information of the target object in the target image, wherein the target image is an image in N images;
根据坐标信息,获取目标图像中的目标对象。Obtain the target object in the target image according to the coordinate information.
第二方面,本申请实施例提供了一种图像处理装置,包括:In a second aspect, an embodiment of the present application provides an image processing apparatus, including:
第一获取模块,用于获取N个图像,其中,N个图像为图像采集组件在不同对焦距离下拍摄的图像;a first acquisition module, configured to acquire N images, wherein the N images are images captured by the image acquisition component at different focusing distances;
划分模块,用于将N个图像中的每个图像划分为M个区域;a division module for dividing each of the N images into M regions;
第二获取模块,用于获取每个图像的每个区域的像素反差值;The second acquisition module is used to acquire the pixel contrast value of each area of each image;
确定模块,用于根据像素反差值,确定目标对象在目标图像中的坐标信息,其中,目标图像为N个图像中的图像;a determining module, configured to determine the coordinate information of the target object in the target image according to the pixel contrast value, wherein the target image is an image in N images;
第三获取模块,用于根据坐标信息,获取目标图像中的目标对象。The third acquiring module is used for acquiring the target object in the target image according to the coordinate information.
第三方面,本申请实施例提供了一种电子设备,该电子设备包括处理器、存储器及存储在所述存储器上并可在所述处理器上运行的程序或指令,所述程序或指令被所述处理器执行时实现如第一方面所述的方法的步骤。In a third aspect, embodiments of the present application provide an electronic device, the electronic device includes a processor, a memory, and a program or instruction stored on the memory and executable on the processor, the program or instruction being The processor implements the steps of the method according to the first aspect when executed.
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质上存储程序或指令,所述程序或指令被处理器执行时实现如第一方面所述的方法的步骤。In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, where a program or an instruction is stored on the computer-readable storage medium, and when the program or instruction is executed by a processor, the method according to the first aspect is implemented A step of.
第五方面,本申请实施例提供了一种芯片,所述芯片包括处理器和通信接口,所述通信接口和所述处理器耦合,所述处理器用于运行程序或指令,实现如第一方面所述的方法的步骤。In a fifth aspect, an embodiment of the present application provides a chip, the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is configured to run a program or an instruction, and implement the first aspect the steps of the method.
在本申请实施例中,将N个图像中的每个图像划分为M个区域,根据每个图像的每个区域的像素反差值,确定目标对象在目标图像中的坐标信息,根据坐标信息,获取目标图像中的目标对象,即实现了对目标对象的抠图。相比于相关技术中人为利用工具抠图,本申请实施例能够自动的对目标对象进行抠图,能够提高抠图的准确性。In the embodiment of the present application, each of the N images is divided into M areas, and the coordinate information of the target object in the target image is determined according to the pixel contrast value of each area of each image, and according to the coordinate information, Obtaining the target object in the target image is to realize the matting of the target object. Compared with artificially using tools to cut out the image in the related art, the embodiment of the present application can automatically cut out the target object, which can improve the accuracy of the image cutout.
附图说明Description of drawings
图1是本申请实施例提供的图像处理方法的流程示意图;1 is a schematic flowchart of an image processing method provided by an embodiment of the present application;
图2是本申请实施例提供的目标拍摄场景的示意图;2 is a schematic diagram of a target shooting scene provided by an embodiment of the present application;
图3是本申请实施例提供的N个图像的示意图;3 is a schematic diagram of N images provided by an embodiment of the present application;
图4是本申请实施例提供的区域划分的示意图;4 is a schematic diagram of area division provided by an embodiment of the present application;
图5是本申请实施例提供的区域分类的结果示意图;5 is a schematic diagram of the results of the area classification provided by the embodiment of the present application;
图6是本申请实施例提供的对象分区域显示的示意图;6 is a schematic diagram of sub-regional display of objects provided by an embodiment of the present application;
图7是本申请实施例提供的处理后的目标图像的示意图;7 is a schematic diagram of a processed target image provided by an embodiment of the present application;
图8是本申请实施例提供的图像处理装置的结构示意图;8 is a schematic structural diagram of an image processing apparatus provided by an embodiment of the present application;
图9是实现本申请实施例的电子设备的硬件结构示意图。FIG. 9 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application.
具体实施方式detailed description
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the protection scope of the present application.
本申请的说明书和权利要求书中的术语“第一”、“第二”等是用于区别类似的对象,而不用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便本申请的实施例能够以除了在这里图示或描述的那些以外的顺序实施。此外,说明书以及权利要求中“和/或”表示所连接对象的至少其中之一,字符“/”,一般表示前后关联对象是一种“或”的关系。The terms "first", "second" and the like in the description and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It is to be understood that data so used may be interchanged under appropriate circumstances so that embodiments of the application can be practiced in sequences other than those illustrated or described herein. In addition, "and/or" in the description and claims indicates at least one of the connected objects, and the character "/" generally indicates that the associated objects are in an "or" relationship.
下面结合附图,通过具体的实施例及其应用场景对本申请实施例提供的图像处理方法、装置、设备及介质进行详细地说明。The image processing method, apparatus, device, and medium provided by the embodiments of the present application will be described in detail below with reference to the accompanying drawings through specific embodiments and application scenarios thereof.
图1是本申请实施例提供的图像处理方法的流程示意图。如图1所示,图像处理方法可以包括:FIG. 1 is a schematic flowchart of an image processing method provided by an embodiment of the present application. As shown in Figure 1, the image processing method may include:
S101:获取N个图像,其中,N个图像为图像采集组件在不同对焦距离下拍摄的图像;S101: Acquire N images, where the N images are images captured by the image acquisition component at different focusing distances;
S102:将N个图像中的每个图像划分为M个区域;S102: Divide each of the N images into M regions;
S103:获取每个图像的每个区域的像素反差值;S103: Obtain the pixel contrast value of each area of each image;
S104:根据像素反差值,确定目标对象在目标图像中的坐标信息,其 中,目标图像为N个图像中的图像;S104: determine the coordinate information of the target object in the target image according to the pixel contrast value, wherein the target image is the image in the N images;
S105:根据坐标信息,获取目标图像中的目标对象。S105: Acquire the target object in the target image according to the coordinate information.
需要说明的是,本申请实施例提供的图像处理方法,执行主体可以为图像处理装置,或者该图像处理装置中的用于执行图像处理方法的控制模块。本申请实施例中以图像处理装置执行图像处理方法为例,说明本申请实施例提供的图像处理方法。It should be noted that, in the image processing method provided by the embodiments of the present application, the execution subject may be an image processing apparatus, or a control module in the image processing apparatus for executing the image processing method. In the embodiments of the present application, an image processing method performed by an image processing apparatus is used as an example to describe the image processing method provided by the embodiments of the present application.
图像处理装置获取N个图像;将N个图像中的每个图像划分为M个区域;获取每个图像的每个区域的像素反差值;根据像素反差值,确定目标对象在目标图像中的坐标信息;根据坐标信息,获取目标图像中的目标对象。The image processing device acquires N images; divides each image in the N images into M areas; acquires the pixel contrast value of each area of each image; determines the coordinates of the target object in the target image according to the pixel contrast value information; obtain the target object in the target image according to the coordinate information.
上述各步骤的具体实现方式将在下文中进行详细描述。The specific implementation of the above steps will be described in detail below.
在本申请实施例中,将N个图像中的每个图像划分为M个区域,根据每个图像的每个区域的像素反差值,确定目标对象在目标图像中的坐标信息,根据坐标信息,获取目标图像中的目标对象,即实现了对目标对象的抠图。相比于相关技术中人为利用工具抠图,本申请实施例能够自动的对目标对象进行抠图,能够提高抠图的准确性。In the embodiment of the present application, each of the N images is divided into M areas, and the coordinate information of the target object in the target image is determined according to the pixel contrast value of each area of each image, and according to the coordinate information, Obtaining the target object in the target image is to realize the matting of the target object. Compared with artificially using tools to cut out the image in the related art, the embodiment of the present application can automatically cut out the target object, which can improve the accuracy of the image cutout.
在本申请实施例的一些可能实现中,图像采集组件可以为单图像采集组件。In some possible implementations of the embodiments of the present application, the image acquisition component may be a single image acquisition component.
通过本申请实施例,利用单图像采集组件采集在对焦距离逐步变化的过程中针对目标拍摄场景的N个图像,将N个图像中的每个图像划分为M个区域;根据每个图像的每个区域的像素反差值,确定目标对象在目标图像中的坐标信息,根据坐标信息,获取目标图像中的目标对象。即实现了对目标对象的抠图,能够提高抠图的准确性。并且无需利用多个图像采集组件采集针对目标拍摄场景的多个图像,利用一个图像采集组件采集针对目标拍摄场景的N个图像,即可实现对目标对象的抠图,成本较低。Through the embodiment of the present application, a single image acquisition component is used to collect N images of the target shooting scene in the process of gradually changing the focus distance, and each image in the N images is divided into M areas; The pixel contrast value of each area determines the coordinate information of the target object in the target image, and obtains the target object in the target image according to the coordinate information. That is, the matting of the target object is realized, and the accuracy of the matting can be improved. In addition, it is not necessary to use multiple image acquisition components to collect multiple images for the target shooting scene, and use one image acquisition component to collect N images for the target shooting scene, so that the target object can be matted, and the cost is low.
在本申请实施例的一些可能实现中,对焦距离的变化趋势可以为由小到大逐步变化,或者,由大到小逐步变化。In some possible implementations of the embodiments of the present application, the change trend of the focus distance may be a gradual change from small to large, or a gradual change from large to small.
对焦距离是指物象之间的距离,是镜头到物体的距离与镜头到感光元件的距离之和。Focusing distance refers to the distance between objects and images, which is the sum of the distance from the lens to the object and the distance from the lens to the photosensitive element.
在本申请实施例的一些可能实现中,目标拍摄场景如图2所示。图2是本申请实施例提供的目标拍摄场景的示意图。利用图像采集组件采集到的在对焦距离逐步变化的过程中针对图2所示的目标拍摄场景的N个图像,如图3所示。图3是本申请实施例提供的N个图像的示意图。其中,图3示出了四个图像示意图。In some possible implementations of the embodiments of the present application, the target shooting scene is shown in FIG. 2 . FIG. 2 is a schematic diagram of a target shooting scene provided by an embodiment of the present application. N images of the scene captured by the target shown in FIG. 2 in the process of gradually changing the focus distance are collected by using the image collection component, as shown in FIG. 3 . FIG. 3 is a schematic diagram of N images provided by an embodiment of the present application. Among them, Figure 3 shows four schematic diagrams of images.
在本申请实施例的一些可能实现中,以图3所示的四个图像中的一个图像为例,通过S102将该图像划分为M个区域,如图4所示。图4是本申请实施例提供的区域划分的示意图。其中,图4中每一个方格代表一个区域。In some possible implementations of the embodiments of the present application, taking one image among the four images shown in FIG. 3 as an example, the image is divided into M regions through S102 , as shown in FIG. 4 . FIG. 4 is a schematic diagram of area division provided by an embodiment of the present application. Among them, each square in Figure 4 represents an area.
在本申请实施例的一些可能实现中,通过S102划分得到的多个区域中每个区域可以包括多个像素。In some possible implementations of the embodiments of the present application, each of the multiple regions obtained by dividing in S102 may include multiple pixels.
在每个区域可以包括多个像素时,该区域的像素反差值可以为该区域包括的多个像素中的每个像素的像素反差值之和。When each area may include multiple pixels, the pixel contrast value of the area may be the sum of the pixel contrast values of each pixel in the multiple pixels included in the area.
其中,像素反差值指各个相邻像素间的色彩差异。The pixel contrast value refers to the color difference between adjacent pixels.
在本申请实施例的一些可能实现中,通过S102划分得到的多个区域中每个区域可以仅包括一个像素。In some possible implementations of the embodiments of the present application, each of the multiple regions obtained by dividing in S102 may include only one pixel.
在每个区域可以包括一个像素时,该区域的像素反差值可以为该区域包括的一个像素的像素反差值。When each area may include one pixel, the pixel contrast value of the area may be the pixel contrast value of one pixel included in the area.
通过本申请实施例,每个区域仅包括一个像素,也就是说,按照像素粒度对图像进行划分,能够使目标对象在目标对象中的坐标更精确,进而能够抠图的准确性。According to the embodiment of the present application, each area includes only one pixel, that is, the image is divided according to the pixel granularity, so that the coordinates of the target object in the target object can be more accurate, and thus the accuracy of the map can be achieved.
在本申请实施例的一些可能实现中,S104可以包括:根据像素反差值的变化趋势和对焦距离的变化趋势,对M个区域进行分类,得到分类结果;根据分类结果,确定目标对象在目标图像中的坐标信息。In some possible implementations of the embodiments of the present application, S104 may include: classifying the M regions according to the change trend of the pixel contrast value and the change trend of the focus distance, and obtain a classification result; according to the classification result, determine that the target object is in the target image coordinate information in .
在本申请实施例的一些可能实现中,像素反差值的变化趋势包括但不限于:由大变小、由小变大、由大变小再由小变大和由小变大再由大变小。In some possible implementations of the embodiments of the present application, the change trend of the pixel contrast value includes but is not limited to: from large to small, from small to large, from large to small and then from small to large, and from small to large and then from large to small .
在本申请实施例的一些可能实现中,对焦距离的变化趋势包括但不限于:由大变小和由小变大。In some possible implementations of the embodiments of the present application, the changing trend of the focusing distance includes, but is not limited to: from large to small and from small to large.
在本申请实施例的一些可能实现中,根据像素反差值的变化趋势和对 焦距离的变化趋势,对M个区域进行分类,得到分类结果,可以包括:将M个区域中的第一区域,归类为背景区域,其中,第一区域的像素反差值的变化趋势和对焦距离的变化趋势相同;将M个区域中的第二区域,归类为前景区域,其中,第二区域的像素反差值的变化趋势和对焦距离的变化趋势相反;将M个区域中的第三区域,归类为主体区域,其中,第三区域的像素反差值的变化趋势和对焦距离的变化趋势先相同再相反,或,第三区域的像素反差值的变化趋势和对焦距离的变化趋势先相反再相同。In some possible implementations of the embodiments of the present application, classifying the M regions according to the change trend of the pixel contrast value and the change trend of the focus distance, and obtaining the classification result, may include: classifying the first region in the M regions into a classification result. The class is the background area, wherein the change trend of the pixel contrast value of the first area is the same as the change trend of the focus distance; the second area in the M areas is classified as the foreground area, wherein the pixel contrast value of the second area is the same. The change trend of , is opposite to that of the focus distance; the third area in the M areas is classified as the main area, wherein the change trend of the pixel contrast value of the third area and the change trend of the focus distance are the same first and then opposite. Or, the change trend of the pixel contrast value of the third area and the change trend of the focus distance are opposite first and then the same.
其中,目标对象包括:背景区域、前景区域和主体区域中至少一个。Wherein, the target object includes: at least one of a background area, a foreground area and a subject area.
以图4所示的区域划分为例,归类出的背景区域、前景区域和主体区域如图5所示。图5是本申请实施例提供的区域分类的结果示意图。Taking the area division shown in FIG. 4 as an example, the classified background area, foreground area and subject area are shown in FIG. 5 . FIG. 5 is a schematic diagram of a result of region classification provided by an embodiment of the present application.
在本申请实施例的一些可能实现中,上述背景区域、前景区域和主体区域的像素反差值的变化速率可以不相同。In some possible implementations of the embodiments of the present application, the rate of change of the pixel contrast values of the background area, the foreground area, and the main body area may be different.
在本申请实施例的一些可能实现中,还可以根据像素反差值的变化速率和对焦距离的变化趋势,对M个区域进行分类,得到分类结果。In some possible implementations of the embodiments of the present application, the M regions may also be classified according to the change rate of the pixel contrast value and the change trend of the focus distance to obtain a classification result.
具体的,当对焦距离由小变大时,将M个区域中像素反差值变化速率大于第一速率的区域,归类为前景区域;将M个区域中像素反差值变化速率小于第二速率的区域,归类为背景区域;将M个区域中像素反差值变化速率介于第二速率和第一速率之间的区域,归类为主体区域,其中,第一速率大于第二速率。Specifically, when the focusing distance increases from small to large, the areas in the M areas with the pixel contrast value change rate greater than the first rate are classified as foreground areas; the pixel contrast value change rate in the M areas is smaller than the second rate. The area is classified as a background area; the area in which the pixel contrast value change rate in the M areas is between the second rate and the first rate is classified as the main area, wherein the first rate is greater than the second rate.
当对焦距离由大变小时,将M个区域中像素反差值变化速率大于第三速率的区域,归类为背景区域;将M个区域中像素反差值变化速率小于第四速率的区域,归类为前景区域;将M个区域中像素反差值变化速率介于第四速率和第三速率之间的区域,归类为主体区域,其中,第三速率大于第四速率。When the focusing distance changes from large to small, the areas in the M areas with the change rate of the pixel contrast value greater than the third rate are classified as the background area; the areas in the M areas with the change rate of the pixel contrast value less than the fourth rate are classified as the background area. is the foreground area; the area where the pixel contrast value change rate in the M areas is between the fourth rate and the third rate is classified as the main area, wherein the third rate is greater than the fourth rate.
在本申请实施例的一些可能实现中,目标图像可以为N个图像中以目标对象为焦点的图像,即目标对象可以为N个图像中对焦在目标对象的图像。In some possible implementations of the embodiments of the present application, the target image may be an image focusing on the target object among the N images, that is, the target object may be an image focusing on the target object among the N images.
在目标对象为主体区域的情况下,无论对焦距离是由小到大逐步变化还是由大到小逐步变化,目标对象的像素反差值均由小变大,再由大变小。 因此,可以将目标对象的像素反差值处于最大时对应的图像,确定为目标图像。可以理解的是,目标对象的像素反差值处于最大时,图像采集组件的焦点正好对焦在目标对象上,即图像采集组件以目标对象为焦点。In the case where the target object is the main area, no matter whether the focusing distance changes gradually from small to large or from large to small, the pixel contrast value of the target object increases from small to large, and then from large to small. Therefore, the image corresponding to the maximum pixel contrast value of the target object can be determined as the target image. It can be understood that when the pixel contrast value of the target object is at the maximum value, the focus of the image acquisition component is just on the target object, that is, the image acquisition component takes the target object as the focus.
在本申请实施例的一些可能实现中,本申请实施例提供的图像处理方法还可以包括:对目标图像中的目标对象进行第一处理,和/或,对目标图像中除目标对象之外的其他对象进行第二处理。In some possible implementations of the embodiments of the present application, the image processing method provided by the embodiments of the present application may further include: performing first processing on the target object in the target image, and/or, performing the first processing on the target object in the target image except the target object. The other objects perform the second processing.
本申请实施例并不对第一处理和第二处理的具体处理方式进行限定,任何可用的处理方式均可应用于本申请实施例中。比如,颜色加深处理、颜色渐变处理、柔光处理、锐化处理、油画处理和彩铅处理等等。The embodiments of the present application do not limit the specific processing manners of the first processing and the second processing, and any available processing manners can be applied to the embodiments of the present application. For example, color burn processing, color gradient processing, soft light processing, sharpening processing, oil painting processing and color pencil processing and so on.
在本申请实施例的一些可能实现中,第一处理和第二处理可以根据实际需求进行设置。In some possible implementations of the embodiments of the present application, the first processing and the second processing may be set according to actual requirements.
在本申请实施例的一些可能实现中,在目标对象为人物的情况下,第一处理可以为美颜处理。In some possible implementations of the embodiments of the present application, when the target object is a person, the first processing may be a beauty processing.
在本申请实施例的一些可能实现中,第二处理可以为虚化处理。In some possible implementations of the embodiments of the present application, the second processing may be blurring processing.
在本申请实施例中,在目标对象为主体区域的情况下,通过对目标图像中除主体区域之外的其他区域进行虚化处理,能够使目标对象更加清晰。In the embodiment of the present application, when the target object is the main body region, the target object can be made clearer by performing blurring processing on other regions except the main body region in the target image.
在本申请实施例的一些可能实现中,本申请实施例提供的图像处理方法还可以包括:在屏幕的第四区域显示目标对象;在屏幕的第五区域显示目标图像中除目标对象之外的其他对象。也就是说,将目标图像中的目标对象和目标图像中除目标对象之外的其他对象进行分离。然后,分别对显示在第四区域的目标对象和对显示在第五区域的目标图像中除目标对象之外的其他对象进行第二处理。In some possible implementations of the embodiments of the present application, the image processing method provided by the embodiments of the present application may further include: displaying the target object in the fourth area of the screen; displaying the target image in the fifth area of the screen except the target object other objects. That is, the target object in the target image is separated from other objects in the target image except the target object. Then, the second processing is performed on the target object displayed in the fourth area and the objects other than the target object in the target image displayed in the fifth area, respectively.
示例性的,将目标图像中的目标对象和除目标对象之外的其他对象分区域显示,如图6所示。图6是本申请实施例提供的对象分区域显示的示意图。Exemplarily, the target object and other objects other than the target object in the target image are displayed in sub-regions, as shown in FIG. 6 . FIG. 6 is a schematic diagram of displaying objects in sub-regions provided by an embodiment of the present application.
其中,在图6中,目标对象为主体区域,除目标对象之外的其他对象为背景区域和前景区域。Among them, in FIG. 6 , the target object is the main area, and other objects except the target object are the background area and the foreground area.
在本申请实施例中,通过在屏幕的第四区域显示目标对象;在屏幕的第五区域显示目标图像中除目标对象之外的其他对象,能够分别对显示在 屏幕的第四区域的目标对象和对显示在屏幕的第五区域的目标图像中除目标对象之外的其他对象进行第二处理,避免在目标图像上对目标对象和目标图像中除目标对象之外的其他对象进行处理时,对目标对象或目标图像中除目标对象之外的其他对象误处理。In the embodiment of the present application, by displaying the target object in the fourth area of the screen and displaying other objects in the target image except the target object in the fifth area of the screen, the target objects displayed in the fourth area of the screen can be respectively and performing the second processing on other objects other than the target object in the target image displayed in the fifth area of the screen, to avoid processing the target object and other objects other than the target object in the target image on the target image, Mishandling the target object or objects other than the target object in the target image.
在本申请实施例的一些可能实现中,本发明实施例提供的图像处理方法还可以包括:将显示在第四区域的经过第一处理的目标对象和显示在第五区域的经过第二处理的目标图像中除目标对象之外的其他对象,进行合并,得到处理后的目标图像。In some possible implementations of the embodiments of the present application, the image processing method provided by the embodiments of the present invention may further include: combining the target object displayed in the fourth area that has undergone the first processing and the target object displayed in the fifth area that has undergone the second processing. Other objects in the target image except the target object are merged to obtain the processed target image.
示例性的,将目标图像中的目标对象和除目标对象之外的其他对象分区域显示,如图6所示。在将目标图像中的目标对象和除目标对象之外的其他对象分区域显示之后,可以对显示在第四区域的目标对象进行第一处理,和/或,对显示在第五区域的除目标对象之外的其他对象进行第二处理,在对目标对象和除目标对象之外的其他对象处理完成后,将经过处理的两个对象进行合并,得到处理后的目标图像,如图7所示。图7是本申请实施例提供的处理后的目标图像的示意图。Exemplarily, the target object and other objects other than the target object in the target image are displayed in sub-regions, as shown in FIG. 6 . After the target object and other objects except the target object in the target image are displayed in different areas, the first processing may be performed on the target object displayed in the fourth area, and/or the target object displayed in the fifth area except the target object may be subjected to the first processing. The second processing is performed on other objects other than the object. After the processing of the target object and other objects except the target object is completed, the two processed objects are merged to obtain the processed target image, as shown in Figure 7 . FIG. 7 is a schematic diagram of a processed target image provided by an embodiment of the present application.
在本申请实施例的一个可能实现中,还可以将目标图像中对象“主体区域、背景区域和前景区域”三者分区域显示。然后,对分区域显示后的各个对象中的至少一个对象进行处理,在对象处理完成,可以将三个对象再进行合并,得到处理后的目标图像。In a possible implementation of the embodiment of the present application, the object in the target image, "the main area, the background area, and the foreground area" may also be displayed in three areas. Then, at least one object among the objects displayed in the sub-regions is processed, and after the object processing is completed, the three objects can be combined again to obtain a processed target image.
本申请实施例,通过将对象分区域显示,然后再对某些区域显示的对象进行处理,能够提高图像处理的准确性,防止对象未分区域显示时,对某一对象进行处理时,对其他对象的误操作。In this embodiment of the present application, by displaying objects in different regions, and then processing objects displayed in certain regions, the accuracy of image processing can be improved, and when objects are not displayed in regions, when an object is processed, other objects are processed. Mishandling of objects.
图8是本申请实施例提供的图像处理装置的结构示意图。如图8所示,图像处理装置800可以包括:FIG. 8 is a schematic structural diagram of an image processing apparatus provided by an embodiment of the present application. As shown in FIG. 8 , the image processing apparatus 800 may include:
第一获取模块801,用于获取N个图像,其中,N个图像为图像采集组件在不同对焦距离下拍摄的图像;The first acquisition module 801 is configured to acquire N images, wherein the N images are images captured by the image acquisition component at different focusing distances;
划分模块802,用于将N个图像中的每个图像划分为M个区域;A dividing module 802, configured to divide each of the N images into M regions;
第二获取模块803,用于获取每个图像的每个区域的像素反差值;The second acquisition module 803 is used to acquire the pixel contrast value of each area of each image;
确定模块804,用于根据像素反差值,确定目标对象在目标图像中的 坐标信息,其中,目标图像为N个图像中的图像;Determining module 804 is used to determine the coordinate information of the target object in the target image according to the pixel contrast value, wherein the target image is the image in the N images;
第三获取模块805,用于根据坐标信息,获取目标图像中的目标对象。The third obtaining module 805 is configured to obtain the target object in the target image according to the coordinate information.
在本申请实施例中,将N个图像中的每个图像划分为M个区域,根据每个图像的每个区域的像素反差值,确定目标对象在目标图像中的坐标信息,根据坐标信息,获取目标图像中的目标对象,即实现了对目标对象的抠图。相比于相关技术中人为利用工具抠图,本申请实施例能够自动的对目标对象进行抠图,能够提高抠图的准确性。In the embodiment of the present application, each of the N images is divided into M areas, and the coordinate information of the target object in the target image is determined according to the pixel contrast value of each area of each image, and according to the coordinate information, Obtaining the target object in the target image is to realize the matting of the target object. Compared with artificially using tools to cut out the image in the related art, the embodiment of the present application can automatically cut out the target object, which can improve the accuracy of the image cutout.
在本申请实施例的一些可能实现中,确定模块804可以包括:In some possible implementations of the embodiments of the present application, the determining module 804 may include:
分类子模块,用于根据像素反差值的变化趋势和对焦距离的变化趋势,对M个区域进行分类,得到分类结果;The classification sub-module is used to classify the M areas according to the change trend of the pixel contrast value and the change trend of the focus distance, and obtain the classification result;
确定子模块,用于根据分类结果,确定目标对象在目标图像中的坐标信息。The determining sub-module is used for determining the coordinate information of the target object in the target image according to the classification result.
在本申请实施例的一些可能实现中,分类子模块具体可以用于:In some possible implementations of the embodiments of the present application, the classification submodule may be specifically used for:
将M个区域中的第一区域,归类为背景区域,其中,第一区域的像素反差值的变化趋势和对焦距离的变化趋势相同;The first area in the M areas is classified as a background area, wherein the change trend of the pixel contrast value of the first area is the same as the change trend of the focus distance;
将M个区域中的第二区域,归类为前景区域,其中,第二区域的像素反差值的变化趋势和对焦距离的变化趋势相反;Classify the second area in the M areas as a foreground area, wherein the change trend of the pixel contrast value of the second area is opposite to the change trend of the focus distance;
将M个区域中的第三区域,归类为主体区域,其中,第三区域的像素反差值的变化趋势和对焦距离的变化趋势先相同再相反,或,第三区域的像素反差值的变化趋势和对焦距离的变化趋势先相反再相同;The third area in the M areas is classified as the main area, wherein the change trend of the pixel contrast value of the third area and the change trend of the focus distance are the same first and then opposite, or the change of the pixel contrast value of the third area. The trend and the change trend of focus distance are opposite first and then the same;
其中,目标对象包括:背景区域、前景区域和主体区域中至少一个。Wherein, the target object includes: at least one of a background area, a foreground area and a subject area.
在本申请实施例的一些可能实现中,图像处理装置800还可以包括:In some possible implementations of the embodiments of the present application, the image processing apparatus 800 may further include:
显示模块,用于在屏幕的第四区域显示目标对象,在屏幕的第五区域显示目标图像中除目标对象之外的其他对象。The display module is used for displaying the target object in the fourth area of the screen, and displaying other objects in the target image except the target object in the fifth area of the screen.
在本申请实施例的一些可能实现中,目标图像可以为N个图像中以目标对象为焦点的图像。In some possible implementations of the embodiments of the present application, the target image may be an image with the target object as the focus among the N images.
本申请实施例中的图像处理装置可以是装置,也可以是终端中的部件、集成电路、或芯片。该装置可以是移动电子设备,也可以为非移动电子设备。示例性的,移动电子设备可以为手机、平板电脑、笔记本电脑、掌上 电脑、车载电子设备、可穿戴设备、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本或者个人数字助理(personal digital assistant,PDA)等,非移动电子设备可以为服务器、网络附属存储器(Network Attached Storage,NAS)、个人计算机(personal computer,PC)、电视机(television,TV)、柜员机或者自助机等,本申请实施例不作具体限定。The image processing apparatus in this embodiment of the present application may be an apparatus, or may be a component, an integrated circuit, or a chip in a terminal. The apparatus may be a mobile electronic device or a non-mobile electronic device. Exemplarily, the mobile electronic device may be a mobile phone, a tablet computer, a notebook computer, a palmtop computer, an in-vehicle electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (personal digital assistant). assistant, PDA), etc., non-mobile electronic devices can be servers, network attached storage (Network Attached Storage, NAS), personal computer (personal computer, PC), television (television, TV), teller machine or self-service machine, etc., this application Examples are not specifically limited.
本申请实施例中的图像处理装置可以为具有操作系统的装置。该操作系统可以为安卓(Android)操作系统,可以为ios操作系统,还可以为其他可能的操作系统,本申请实施例不作具体限定。The image processing apparatus in this embodiment of the present application may be an apparatus having an operating system. The operating system may be an Android (Android) operating system, an ios operating system, or other possible operating systems, which are not specifically limited in the embodiments of the present application.
本申请实施例提供的图像处理装置能够实现图1至图7的图像处理方法实施例中的各个过程,为避免重复,这里不再赘述。The image processing apparatus provided in the embodiments of the present application can implement each process in the image processing method embodiments shown in FIG. 1 to FIG. 7 , and in order to avoid repetition, details are not repeated here.
图9是实现本申请实施例的电子设备的硬件结构示意图。如图9所示,该电子设备900包括但不限于:射频单元901、网络模块902、音频输出单元903、输入单元904、传感器905、显示单元906、用户输入单元907、接口单元908、存储器909、以及处理器910等部件。FIG. 9 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application. As shown in FIG. 9 , the electronic device 900 includes but is not limited to: a radio frequency unit 901 , a network module 902 , an audio output unit 903 , an input unit 904 , a sensor 905 , a display unit 906 , a user input unit 907 , an interface unit 908 , and a memory 909 , and components such as the processor 910 .
输入单元904可以包括图形处理器9041和麦克风9042。显示单元906可包括显示面板9061。用户输入单元907包括触控面板9071以及其他输入设备9072。The input unit 904 may include a graphics processor 9041 and a microphone 9042 . The display unit 906 may include a display panel 9061 . The user input unit 907 includes a touch panel 9071 and other input devices 9072 .
存储器909可用于存储软件程序以及各种数据。存储器909可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等。The memory 909 may be used to store software programs as well as various data. The memory 909 may mainly include a stored program area and a stored data area, wherein the stored program area may store an operating system, an application program required for at least one function (such as a sound playback function, an image playback function, etc.), and the like.
本领域技术人员可以理解,电子设备900还可以包括给各个部件供电的电源(比如电池),电源可以通过电源管理系统与处理器910逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。图9中示出的电子设备结构并不构成对电子设备的限定,电子设备可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置,在此不再赘述。Those skilled in the art can understand that the electronic device 900 may also include a power supply (such as a battery) for supplying power to various components, and the power supply may be logically connected to the processor 910 through a power management system, so that the power management system can manage charging, discharging, and power management. consumption management and other functions. The structure of the electronic device shown in FIG. 9 does not constitute a limitation to the electronic device. The electronic device may include more or less components than the one shown, or combine some components, or arrange different components, which will not be repeated here. .
其中,处理器910用于:获取N个图像,其中,N个图像为图像采集组件在不同对焦距离下拍摄的图像;将N个图像中的每个图像划分为M 个区域;获取每个图像的每个区域的像素反差值;根据像素反差值,确定目标对象在目标图像中的坐标信息,其中,目标图像为N个图像中的图像;根据坐标信息,获取目标图像中的目标对象。The processor 910 is configured to: acquire N images, where the N images are images captured by the image acquisition component at different focusing distances; divide each of the N images into M regions; acquire each image The pixel contrast value of each area of then; according to the pixel contrast value, determine the coordinate information of the target object in the target image, wherein the target image is an image in N images; according to the coordinate information, obtain the target object in the target image.
在本申请实施例中,将N个图像中的每个图像划分为M个区域,根据每个图像的每个区域的像素反差值,确定目标对象在目标图像中的坐标信息,根据坐标信息,获取目标图像中的目标对象,即实现了对目标对象的抠图。相比于相关技术中人为利用工具抠图,本申请实施例能够自动的对目标对象进行抠图,能够提高抠图的准确性。In the embodiment of the present application, each of the N images is divided into M areas, and the coordinate information of the target object in the target image is determined according to the pixel contrast value of each area of each image, and according to the coordinate information, Obtaining the target object in the target image is to realize the matting of the target object. Compared with manually using tools to cut out images in the related art, the embodiments of the present application can automatically perform image matting on the target object, which can improve the accuracy of image matting.
在本申请实施例的一些可能实现中,处理器910具体可以用于:In some possible implementations of the embodiments of the present application, the processor 910 may be specifically configured to:
根据像素反差值的变化趋势和对焦距离的变化趋势,对M个区域进行分类,得到分类结果;According to the change trend of the pixel contrast value and the change trend of the focus distance, the M areas are classified, and the classification result is obtained;
根据分类结果,确定目标对象在目标图像中的坐标信息。According to the classification result, the coordinate information of the target object in the target image is determined.
在本申请实施例的一些可能实现中,处理器910具体可以用于:In some possible implementations of the embodiments of the present application, the processor 910 may be specifically configured to:
将M个区域中的第一区域,归类为背景区域,其中,第一区域的像素反差值的变化趋势和对焦距离的变化趋势相同;The first area in the M areas is classified as a background area, wherein the change trend of the pixel contrast value of the first area is the same as the change trend of the focus distance;
将M个区域中的第二区域,归类为前景区域,其中,第二区域的像素反差值的变化趋势和对焦距离的变化趋势相反;Classify the second area in the M areas as a foreground area, wherein the change trend of the pixel contrast value of the second area is opposite to the change trend of the focus distance;
将M个区域中的第三区域,归类为主体区域,其中,第三区域的像素反差值的变化趋势和对焦距离的变化趋势先相同再相反,或,第三区域的像素反差值的变化趋势和对焦距离的变化趋势先相反再相同;The third area in the M areas is classified as the main area, wherein the change trend of the pixel contrast value of the third area and the change trend of the focus distance are the same first and then opposite, or the change of the pixel contrast value of the third area. The trend and the change trend of focus distance are opposite first and then the same;
其中,目标对象包括:背景区域、前景区域和主体区域中至少一个。Wherein, the target object includes: at least one of a background area, a foreground area and a subject area.
在本申请实施例的一些可能实现中,显示单元906可以用于:In some possible implementations of the embodiments of the present application, the display unit 906 may be used for:
在屏幕的第四区域显示目标对象,在屏幕的第五区域显示目标图像中除目标对象之外的其他对象。The target object is displayed in the fourth area of the screen, and other objects in the target image except the target object are displayed in the fifth area of the screen.
可选的,本申请实施例还提供一种电子设备,包括处理器910,存储器909,存储在存储器909上并可在所述处理器910上运行的程序或指令,该程序或指令被处理器910执行时实现上述图像处理方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。Optionally, an embodiment of the present application further provides an electronic device, including a processor 910, a memory 909, a program or instruction stored in the memory 909 and executable on the processor 910, the program or instruction being processed by the processor When 910 is executed, each process of the above image processing method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, details are not described here.
需要注意的是,本申请实施例中的电子设备包括上述所述的移动电子 设备和非移动电子设备。It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.
本发明实施例还提供一种电子设备,被配置成用于执行上述图像处理方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。Embodiments of the present invention further provide an electronic device configured to execute each process of the above image processing method embodiments, and can achieve the same technical effect, which is not repeated here to avoid repetition.
本申请实施例还提供一种计算机可读存储介质,所述计算机可读存储介质上存储有程序或指令,该程序或指令被处理器执行时实现上述图像处理方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。Embodiments of the present application further provide a computer-readable storage medium, where a program or an instruction is stored on the computer-readable storage medium, and when the program or instruction is executed by a processor, each process of the above image processing method embodiment is implemented, and can To achieve the same technical effect, in order to avoid repetition, details are not repeated here.
其中,所述处理器为上述实施例中所述的电子设备中的处理器。所述计算机可读存储介质的示例包括非暂态计算机可读存储介质,如计算机只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等。Wherein, the processor is the processor in the electronic device described in the foregoing embodiments. Examples of the computer-readable storage medium include non-transitory computer-readable storage media, such as computer read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disk or optical disk, etc. .
本申请实施例另提供了一种芯片,所述芯片包括处理器和通信接口,所述通信接口和所述处理器耦合,所述处理器用于运行程序或指令,实现上述图像处理方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。An embodiment of the present application further provides a chip, where the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is configured to run a program or an instruction to implement the above image processing method embodiments. Each process can achieve the same technical effect. In order to avoid repetition, it will not be repeated here.
本发明实施例还提供一种计算机程序产品,所述计算机程序产品可被处理器执行以实现上述图像处理方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。An embodiment of the present invention further provides a computer program product, which can be executed by a processor to implement the various processes of the above image processing method embodiments, and can achieve the same technical effect. To avoid repetition, details are not repeated here. .
应理解,本申请实施例提到的芯片还可以称为系统级芯片、系统芯片、芯片系统或片上系统芯片等。It should be understood that the chip mentioned in the embodiments of the present application may also be referred to as a system-on-chip, a system-on-chip, a system-on-a-chip, or a system-on-a-chip, or the like.
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素。此外,需要指出的是,本申请实施方式中的方法和装置的范围不限按示出或讨论的顺序来执行功能,还可包括根据所涉及的功能按基本同时的方式或按相反 的顺序来执行功能,例如,可以按不同于所描述的次序来执行所描述的方法,并且还可以添加、省去、或组合各种步骤。另外,参照某些示例所描述的特征可在其他示例中被组合。It should be noted that, herein, the terms "comprising", "comprising" or any other variation thereof are intended to encompass non-exclusive inclusion, such that a process, method, article or device comprising a series of elements includes not only those elements, It also includes other elements not expressly listed or inherent to such a process, method, article or apparatus. Without further limitation, an element qualified by the phrase "comprising a..." does not preclude the presence of additional identical elements in a process, method, article or apparatus that includes the element. In addition, it should be noted that the scope of the methods and apparatus in the embodiments of the present application is not limited to performing the functions in the order shown or discussed, but may also include performing the functions in a substantially simultaneous manner or in the reverse order depending on the functions involved. To perform functions, for example, the described methods may be performed in an order different from that described, and various steps may also be added, omitted, or combined. Additionally, features described with reference to some examples may be combined in other examples.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本申请各个实施例所述的方法。From the description of the above embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus a necessary general hardware platform, and of course hardware can also be used, but in many cases the former is better implementation. Based on this understanding, the technical solution of the present application can be embodied in the form of a software product in essence or in a part that contributes to the prior art, and the computer software product is stored in a storage medium (such as ROM/RAM, magnetic disk, CD-ROM), including several instructions to make a terminal (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) execute the methods described in the various embodiments of this application.
上面结合附图对本申请的实施例进行了描述,但是本申请并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本申请的启示下,在不脱离本申请宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本申请的保护之内。The embodiments of the present application have been described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific embodiments, which are merely illustrative rather than restrictive. Under the inspiration of this application, without departing from the scope of protection of the purpose of this application and the claims, many forms can be made, which all fall within the protection of this application.

Claims (15)

  1. 一种图像处理方法,包括:An image processing method, comprising:
    获取N个图像,其中,所述N个图像为图像采集组件在不同对焦距离下拍摄的图像;acquiring N images, wherein the N images are images captured by the image acquisition component at different focusing distances;
    将所述N个图像中的每个图像划分为M个区域;dividing each of the N images into M regions;
    获取每个图像的每个区域的像素反差值;Get the pixel contrast value of each area of each image;
    根据所述像素反差值,确定目标对象在目标图像中的坐标信息,其中,所述目标图像为所述N个图像中的图像;Determine the coordinate information of the target object in the target image according to the pixel contrast value, wherein the target image is an image in the N images;
    根据所述坐标信息,获取所述目标图像中的所述目标对象。Acquire the target object in the target image according to the coordinate information.
  2. 根据权利要求1所述的方法,其中,所述根据所述像素反差值,确定目标对象在目标图像中的坐标信息,包括:The method according to claim 1, wherein the determining the coordinate information of the target object in the target image according to the pixel contrast value comprises:
    根据所述像素反差值的变化趋势和所述对焦距离的变化趋势,对所述M个区域进行分类,得到分类结果;According to the change trend of the pixel contrast value and the change trend of the focus distance, classify the M areas to obtain a classification result;
    根据所述分类结果,确定所述目标对象在所述目标图像中的坐标信息。According to the classification result, the coordinate information of the target object in the target image is determined.
  3. 根据权利要求2所述的方法,其中,所述根据所述像素反差值的变化趋势和所述对焦距离的变化趋势,对所述M个区域进行分类,得到分类结果,包括:The method according to claim 2, wherein the classification of the M regions according to the change trend of the pixel contrast value and the change trend of the focus distance to obtain a classification result, comprising:
    将所述M个区域中的第一区域,归类为背景区域,其中,所述第一区域的像素反差值的变化趋势和所述对焦距离的变化趋势相同;Classifying the first area in the M areas as a background area, wherein the change trend of the pixel contrast value of the first area is the same as the change trend of the focus distance;
    将所述M个区域中的第二区域,归类为前景区域,其中,所述第二区域的像素反差值的变化趋势和所述对焦距离的变化趋势相反;Classifying the second area in the M areas as a foreground area, wherein the change trend of the pixel contrast value of the second area is opposite to the change trend of the focus distance;
    将所述M个区域中的第三区域,归类为主体区域,其中,所述第三区域的像素反差值的变化趋势和所述对焦距离的变化趋势先相同再相反,或,所述第三区域的像素反差值的变化趋势和所述对焦距离的变化趋势先相反再相同;The third area in the M areas is classified as the main area, wherein the change trend of the pixel contrast value of the third area and the change trend of the focus distance are the same first and then opposite, or, the first The change trend of the pixel contrast value of the three regions and the change trend of the focus distance are opposite first and then the same;
    其中,所述目标对象包括:所述背景区域、所述前景区域和所述主体区域中至少一个。Wherein, the target object includes: at least one of the background area, the foreground area and the main body area.
  4. 根据权利要求1所述的方法,其中,在所述根据所述坐标信息,获取所述目标图像中的所述目标对象之后,所述方法还包括:The method according to claim 1, wherein after acquiring the target object in the target image according to the coordinate information, the method further comprises:
    在屏幕的第四区域显示所述目标对象;display the target object in the fourth area of the screen;
    在所述屏幕的第五区域显示所述目标图像中除所述目标对象之外的其他对象。Objects other than the target object in the target image are displayed in the fifth area of the screen.
  5. 根据权利要求1所述的方法,其中,所述目标图像为所述N个图像中以所述目标对象为焦点的图像。The method according to claim 1, wherein the target image is an image with the target object as a focus among the N images.
  6. 一种图像处理装置,包括:An image processing device, comprising:
    第一获取模块,用于获取N个图像,其中,所述N个图像为图像采集组件在不同对焦距离下拍摄的图像;a first acquisition module, configured to acquire N images, wherein the N images are images captured by the image acquisition component at different focusing distances;
    划分模块,用于将所述N个图像中的每个图像划分为M个区域;a dividing module, for dividing each of the N images into M regions;
    第二获取模块,用于获取每个图像的每个区域的像素反差值;The second acquisition module is used to acquire the pixel contrast value of each area of each image;
    确定模块,用于根据所述像素反差值,确定目标对象在目标图像中的坐标信息,其中,所述目标图像为所述N个图像中的图像;a determining module, configured to determine the coordinate information of the target object in the target image according to the pixel contrast value, wherein the target image is an image in the N images;
    第三获取模块,用于根据所述坐标信息,获取所述目标图像中的所述目标对象。A third acquiring module, configured to acquire the target object in the target image according to the coordinate information.
  7. 根据权利要求6所述的装置,其中,所述确定模块包括:The apparatus of claim 6, wherein the determining module comprises:
    分类子模块,用于根据所述像素反差值的变化趋势和所述对焦距离的变化趋势,对所述M个区域进行分类,得到分类结果;A classification submodule, configured to classify the M areas according to the change trend of the pixel contrast value and the change trend of the focus distance, and obtain a classification result;
    确定子模块,用于根据所述分类结果,确定所述目标对象在所述目标图像中的坐标信息。A determination submodule, configured to determine the coordinate information of the target object in the target image according to the classification result.
  8. 根据权利要求7所述的装置,其中,所述分类子模块具体用于:The device according to claim 7, wherein the classification submodule is specifically used for:
    将所述M个区域中的第一区域,归类为背景区域,其中,所述第一区域的像素反差值的变化趋势和所述对焦距离的变化趋势相同;Classifying the first area in the M areas as a background area, wherein the change trend of the pixel contrast value of the first area is the same as the change trend of the focus distance;
    将所述M个区域中的第二区域,归类为前景区域,其中,所述第二区域的像素反差值的变化趋势和所述对焦距离的变化趋势相反;Classifying the second area in the M areas as a foreground area, wherein the change trend of the pixel contrast value of the second area is opposite to the change trend of the focus distance;
    将所述M个区域中的第三区域,归类为主体区域,其中,所述第三区域的像素反差值的变化趋势和所述对焦距离的变化趋势先相同再相反,或, 所述第三区域的像素反差值的变化趋势和所述对焦距离的变化趋势先相反再相同;The third area in the M areas is classified as the main area, wherein the change trend of the pixel contrast value of the third area and the change trend of the focus distance are the same first and then opposite, or, the first The change trend of the pixel contrast value of the three regions and the change trend of the focus distance are opposite first and then the same;
    其中,所述目标对象包括:所述背景区域、所述前景区域和所述主体区域中至少一个。Wherein, the target object includes: at least one of the background area, the foreground area and the main body area.
  9. 根据权利要求6所述的装置,其中,所述装置还包括:The apparatus of claim 6, wherein the apparatus further comprises:
    显示模块,用于在屏幕的第四区域显示所述目标对象,在所述屏幕的第五区域显示所述目标图像中除所述目标对象之外的其他对象。The display module is configured to display the target object in the fourth area of the screen, and display other objects in the target image except the target object in the fifth area of the screen.
  10. 根据权利要求6所述的装置,其中,所述目标图像为所述N个图像中以所述目标对象为焦点的图像。The apparatus according to claim 6, wherein the target image is an image of the N images with the target object as a focus.
  11. 一种电子设备,包括:处理器、存储器及存储在所述存储器上并可在所述处理器上运行的程序或指令,所述程序或指令被所述处理器执行时实现如权利要求1至5任一项所述的图像处理方法的步骤。An electronic device, comprising: a processor, a memory, and a program or instruction stored on the memory and executable on the processor, the program or instruction being executed by the processor to implement claims 1 to 5. The steps of any one of the image processing methods.
  12. 一种电子设备,被配置为用于执行如权利要求1至5中任一项所述的图像处理方法的步骤。An electronic device configured to perform the steps of the image processing method as claimed in any one of claims 1 to 5.
  13. 一种计算机可读存储介质,所述计算机可读存储介质上存储程序或指令,所述程序或指令被处理器执行时实现如权利要求1至5任一项所述的图像处理方法的步骤。A computer-readable storage medium storing programs or instructions on the computer-readable storage medium, when the programs or instructions are executed by a processor, the steps of the image processing method according to any one of claims 1 to 5 are implemented.
  14. 一种计算机程序产品,所述计算机程序产品可被处理器执行以实现如权利要求1至5中任一项所述的图像处理方法的步骤。A computer program product executable by a processor to implement the steps of the image processing method according to any one of claims 1 to 5.
  15. 一种芯片,包括处理器和通信接口,所述通信接口和所述处理器耦合,所述处理器用于运行程序或指令,实现如权利要求1至5任一项所述的图像处理方法的步骤。A chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or an instruction to implement the steps of the image processing method according to any one of claims 1 to 5 .
PCT/CN2021/100019 2020-06-30 2021-06-15 Image processing method and apparatus, and device and medium WO2022001648A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010611475.X 2020-06-30
CN202010611475.XA CN111866378A (en) 2020-06-30 2020-06-30 Image processing method, apparatus, device and medium

Publications (1)

Publication Number Publication Date
WO2022001648A1 true WO2022001648A1 (en) 2022-01-06

Family

ID=72989934

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/100019 WO2022001648A1 (en) 2020-06-30 2021-06-15 Image processing method and apparatus, and device and medium

Country Status (2)

Country Link
CN (1) CN111866378A (en)
WO (1) WO2022001648A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115002356A (en) * 2022-07-19 2022-09-02 深圳市安科讯实业有限公司 Night vision method based on digital video photography

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112362164B (en) * 2020-11-10 2022-01-18 广东电网有限责任公司 Temperature monitoring method and device of equipment, electronic equipment and storage medium
CN113055603A (en) * 2021-03-31 2021-06-29 联想(北京)有限公司 Image processing method and electronic equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008294785A (en) * 2007-05-25 2008-12-04 Sanyo Electric Co Ltd Image processor, imaging apparatus, image file, and image processing method
US20120320239A1 (en) * 2011-06-14 2012-12-20 Pentax Ricoh Imaging Company, Ltd. Image processing device and image processing method
CN102843510A (en) * 2011-06-14 2012-12-26 宾得理光映像有限公司 Imaging device and distance information detecting method
CN110189339A (en) * 2019-06-03 2019-08-30 重庆大学 The active profile of depth map auxiliary scratches drawing method and system
CN111246106A (en) * 2020-01-22 2020-06-05 维沃移动通信有限公司 Image processing method, electronic device, and computer-readable storage medium

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101930533B (en) * 2009-06-19 2013-11-13 株式会社理光 Device and method for performing sky detection in image collecting device
KR20110020519A (en) * 2009-08-24 2011-03-03 삼성전자주식회사 Digital photographing apparatus, controlling method of the same, and recording medium storing program to implement the method
CN102338972A (en) * 2010-07-21 2012-02-01 华晶科技股份有限公司 Assistant focusing method using multiple face blocks
CN105629631B (en) * 2016-02-29 2020-01-10 Oppo广东移动通信有限公司 Control method, control device and electronic device
CN108305215A (en) * 2018-01-23 2018-07-20 北京易智能科技有限公司 A kind of image processing method and system based on intelligent mobile terminal
CN110336951A (en) * 2019-08-26 2019-10-15 厦门美图之家科技有限公司 Contrast formula focusing method, device and electronic equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008294785A (en) * 2007-05-25 2008-12-04 Sanyo Electric Co Ltd Image processor, imaging apparatus, image file, and image processing method
US20120320239A1 (en) * 2011-06-14 2012-12-20 Pentax Ricoh Imaging Company, Ltd. Image processing device and image processing method
CN102843510A (en) * 2011-06-14 2012-12-26 宾得理光映像有限公司 Imaging device and distance information detecting method
CN110189339A (en) * 2019-06-03 2019-08-30 重庆大学 The active profile of depth map auxiliary scratches drawing method and system
CN111246106A (en) * 2020-01-22 2020-06-05 维沃移动通信有限公司 Image processing method, electronic device, and computer-readable storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115002356A (en) * 2022-07-19 2022-09-02 深圳市安科讯实业有限公司 Night vision method based on digital video photography

Also Published As

Publication number Publication date
CN111866378A (en) 2020-10-30

Similar Documents

Publication Publication Date Title
WO2022001648A1 (en) Image processing method and apparatus, and device and medium
RU2596580C2 (en) Method and device for image segmentation
CN108737739B (en) Preview picture acquisition method, preview picture acquisition device and electronic equipment
US10317777B2 (en) Automatic zooming method and apparatus
CN112714255B (en) Shooting method and device, electronic equipment and readable storage medium
CN106446223B (en) Map data processing method and device
CN108898082B (en) Picture processing method, picture processing device and terminal equipment
WO2022042679A1 (en) Picture processing method and apparatus, device, and storage medium
CN108961267B (en) Picture processing method, picture processing device and terminal equipment
WO2018166069A1 (en) Photographing preview method, graphical user interface, and terminal
CN112714253B (en) Video recording method and device, electronic equipment and readable storage medium
TWI777098B (en) Method, apparatus and electronic device for image processing and storage medium thereof
CN103824252A (en) Picture processing method and system
JP7210089B2 (en) RESOURCE DISPLAY METHOD, APPARATUS, DEVICE AND COMPUTER PROGRAM
CN111290684B (en) Image display method, image display device and terminal equipment
WO2022161340A1 (en) Image display method and apparatus, and electronic device
CN110463177A (en) The bearing calibration of file and picture and device
CN112269522A (en) Image processing method, image processing device, electronic equipment and readable storage medium
CN110689565B (en) Depth map determination method and device and electronic equipment
US20220182554A1 (en) Image display method, mobile terminal, and computer-readable storage medium
WO2019090734A1 (en) Photographing method and apparatus, mobile terminal, and computer readable storage medium
CN111325220A (en) Image generation method, device, equipment and storage medium
CN112734661A (en) Image processing method and device
CN111638844A (en) Screen capturing method and device and electronic equipment
CN112383708B (en) Shooting method and device, electronic equipment and readable storage medium

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: 21833084

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: 21833084

Country of ref document: EP

Kind code of ref document: A1

122 Ep: pct application non-entry in european phase

Ref document number: 21833084

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 26-06-2023)

122 Ep: pct application non-entry in european phase

Ref document number: 21833084

Country of ref document: EP

Kind code of ref document: A1