CN113556472B - Image compensation method, device, medium and front camera - Google Patents

Image compensation method, device, medium and front camera Download PDF

Info

Publication number
CN113556472B
CN113556472B CN202111103573.3A CN202111103573A CN113556472B CN 113556472 B CN113556472 B CN 113556472B CN 202111103573 A CN202111103573 A CN 202111103573A CN 113556472 B CN113556472 B CN 113556472B
Authority
CN
China
Prior art keywords
phase point
processing chip
image
point position
matched
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN202111103573.3A
Other languages
Chinese (zh)
Other versions
CN113556472A (en
Inventor
尤伟强
侯国军
杜军红
葛振纲
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai Haocheng Information Technology Co ltd
Original Assignee
Shanghai Haocheng Information Technology Co ltd
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 Shanghai Haocheng Information Technology Co ltd filed Critical Shanghai Haocheng Information Technology Co ltd
Priority to CN202111103573.3A priority Critical patent/CN113556472B/en
Publication of CN113556472A publication Critical patent/CN113556472A/en
Application granted granted Critical
Publication of CN113556472B publication Critical patent/CN113556472B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/80Geometric correction

Landscapes

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

Abstract

The embodiment of the invention provides an image compensation method, an image compensation device, a medium and a front camera, wherein the method comprises the following steps: the image is shot for leading camera, leading camera includes: the method is applied to a front camera and comprises the following steps: acquiring an original image shot by a front camera; determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip; acquiring a preset compensation algorithm according to the phase point position; and compensating the original image according to the position of the phase point and the compensation algorithm to obtain a compensated image. The image compensation method provided by the embodiment of the invention can be used for carrying out image compensation on the original image, and the quality of the image generated after compensation is higher.

Description

Image compensation method, device, medium and front camera
Technical Field
The embodiment of the invention relates to the technical field of cameras, in particular to an image compensation method, an image compensation device, an image compensation medium and a front-facing camera.
Background
With the continuous development of science and technology, the functions of the user terminal are more and more abundant. A user terminal, such as a commonly used mobile phone, is usually equipped with a camera to meet the shooting requirements of the user. The cameras on the mobile phone are divided into a front camera and a rear camera, and generally, the definition, performance and the like of the front camera are inferior to those of the rear camera. The camera comprises a processing chip and an image signal processor. A processing chip commonly used in the rear camera is a PDAF (Phase Detection Auto Focus, chinese) chip, and the PDAF chip has an image sensor and a PDAF function, and the image sensor is used to convert an external scene into an electrical signal to form an original image. The PDAF is used to perform a Phase Detection focusing operation on each PD (Phase Detection, chinese: Phase) point formed of a photosensitive material in an image sensor, thereby improving the sharpness of an original image. And finally, processing the image through an image signal processor, and further improving the quality of the image. The processing chip of the front camera, such as the OV13B10 chip, only has an image sensor, but does not have the PDAF function.
The image sensor generally has PD dead pixels, and an image signal processor is required to perform image compensation on an original image generated by the image sensor. The image compensation requires the image signal processor to acquire the position information of the PD point from the PDAF chip, and since the processing chip of the front camera is not the PDAF chip, the image signal processor cannot perform image compensation on the original image, resulting in low quality of the finally generated image.
Disclosure of Invention
The invention provides an image compensation method, an image compensation device, an image compensation medium and a front-facing camera, which are used for solving the problems that an image signal processor cannot compensate images of original images and the quality of finally generated images is low because a processing chip of the front-facing camera is not a PDAF (digital projection imaging) chip at present.
A first aspect of an embodiment of the present invention provides an image compensation method, including:
the image is shot for leading camera, leading camera includes: the method is applied to a front camera and comprises the following steps:
acquiring an original image shot by a front camera;
determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip;
acquiring a preset compensation algorithm according to the phase point position;
and compensating the original image according to the position of the phase point and the compensation algorithm to obtain a compensated image.
Optionally, as the above method, before determining all the phase point positions in the first processing chip that match the original image by using the phase point position determination process that matches the first processing chip, the method further includes:
and acquiring a phase point position determination process matched with the first processing chip.
Optionally, in the method, the terminal device including the front camera further includes a rear camera, and the rear camera includes: a second processing chip;
the phase point position determination process for obtaining the phase point position matched with the first processing chip comprises the following steps:
calling a phase point position corresponding to the second processing chip to determine a flow;
and performing chip compatibility adjustment on the phase point position determination process corresponding to the second processing chip to obtain a phase point position determination process matched with the first processing chip.
Optionally, in the method as described above, the first processing chip includes an image sensor;
the determining, by using a phase point position determination process matched with a first processing chip, all phase point positions matched with the original image in the first processing chip includes:
acquiring factory information stored in the image sensor;
and determining all phase point positions matched with the original image from the image sensor according to the factory information.
Optionally, in the method described above, a phase point position determination procedure matched with the first processing chip is obtained by using the first processing chip;
the determining, by using a phase point position determination process matched with a first processing chip, all phase point positions matched with the original image in the first processing chip includes:
and determining all the phase point positions matched with the original image in the first processing chip by adopting the first processing chip and a phase point position determination process matched with the first processing chip.
Optionally, in the method described above, the front camera further includes: an image signal processor;
the obtaining of the preset compensation algorithm according to the phase point position includes:
the image signal processor receives a compensation algorithm acquisition request sent by a first processing chip according to the position of the phase point;
and the image signal processor acquires the pre-stored compensation algorithm according to the compensation algorithm acquisition request.
Optionally, in the method described above, the compensation algorithm is a phase pixel correction algorithm;
the compensating the original image according to the position of the phase point and the compensation algorithm to obtain a compensated image includes:
and the image signal processor compensates the original image according to the position of the phase point and the phase pixel correction algorithm to obtain a compensated image.
A second aspect of the embodiments of the present invention provides an image compensation apparatus, where the image is captured by a front camera, and the front camera includes: a first processing chip, the device is located at a front camera, the device includes:
the image acquisition module is used for acquiring an original image shot by the front camera;
the determining module is used for determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determining process matched with the first processing chip;
the algorithm obtaining module is used for obtaining a preset compensation algorithm according to the phase point position;
and the compensation module is used for compensating the original image according to the position of the phase point and the compensation algorithm so as to obtain a compensated image.
Optionally, the apparatus as described above, further comprising:
and the flow acquiring module is used for acquiring the phase point position determining flow matched with the first processing chip.
Optionally, the apparatus described above, the terminal device including the front camera further includes a rear camera, and the rear camera includes: a second processing chip;
the flow acquisition module is specifically configured to:
calling a phase point position corresponding to the second processing chip to determine a flow; and performing chip compatibility adjustment on the phase point position determination process corresponding to the second processing chip to obtain a phase point position determination process matched with the first processing chip.
Optionally, in the apparatus as described above, the first processing chip includes an image sensor;
the determining module is specifically configured to:
acquiring factory information stored in the image sensor; and determining all phase point positions matched with the original image from the image sensor according to the factory information.
Optionally, in the apparatus described above, the first processing chip is used to obtain a phase point position determination procedure matched with the first processing chip;
the determining module is specifically configured to:
and determining all the phase point positions matched with the original image in the first processing chip by adopting the first processing chip and a phase point position determination process matched with the first processing chip.
Optionally, in the apparatus as described above, the front camera further includes: an image signal processor;
the algorithm obtaining module is specifically configured to:
the image signal processor receives a compensation algorithm acquisition request sent by a first processing chip according to the position of the phase point; and the image signal processor acquires the pre-stored compensation algorithm according to the compensation algorithm acquisition request.
Optionally, in the apparatus as described above, the compensation algorithm is a phase pixel correction algorithm;
the compensation module is specifically configured to:
and the image signal processor compensates the original image according to the position of the phase point and the phase pixel correction algorithm to obtain a compensated image.
A third aspect of the embodiments of the present invention provides a front camera, including: a first processing chip and an image signal processor; the first processing chip is electrically interconnected with the image signal processor; the first processing chip comprises a first processor and a first memory; the image signal processor includes a second processor and a second memory;
a first memory stores the first processor-executable instructions;
the first processor is configured to: acquiring an original image shot by a front camera; determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip;
a second memory stores the second processor-executable instructions;
the second processor is configured to: acquiring a preset compensation algorithm according to the phase point position; and compensating the original image according to the position of the phase point and the compensation algorithm to obtain a compensated image.
A fourth aspect of the embodiments of the present invention provides a computer-readable storage medium, in which computer-executable instructions are stored, and when the computer-executable instructions are executed by a processor, the computer-executable instructions are configured to implement the image compensation method according to any one of the first aspect.
A fifth aspect of the embodiments of the present invention provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, the computer program implements the image compensation method according to any one of the first aspects.
The embodiment of the invention provides an image compensation method, an image compensation device, a medium and a front camera, wherein the image compensation method comprises the following steps: the image is shot for leading camera, leading camera includes: the method is applied to a front camera and comprises the following steps: acquiring an original image shot by a front camera; determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip; acquiring a preset compensation algorithm according to the phase point position; and compensating the original image according to the position of the phase point and the compensation algorithm to obtain a compensated image. The image compensation method of the embodiment of the invention adopts the phase point position determining process matched with the first processing chip, and the matching degree of the phase point position determining process and the first processing chip is higher, so that the first processing chip can determine all phase point positions matched with the original image through the phase point position process. Therefore, the front camera can compensate the original image according to the phase point position and a compensation algorithm, and the quality of the finally generated image is high.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
FIG. 1 is a diagram of a scene in which an image compensation method according to an embodiment of the present invention can be implemented;
FIG. 2 is a flowchart illustrating an image compensation method according to a first embodiment of the present invention;
FIG. 3 is a schematic phase point diagram of an image compensation method according to a first embodiment of the present invention;
FIG. 4 is a flowchart illustrating an image compensation method according to a second embodiment of the present invention;
FIG. 5 is a flowchart illustrating an image compensation method according to a third embodiment of the present invention;
FIG. 6 is a schematic structural diagram of an image compensation apparatus according to a fourth embodiment of the present invention;
fig. 7 is a schematic structural diagram of an image compensation apparatus according to a fifth embodiment of the present invention;
fig. 8 is a schematic structural diagram of a front camera according to a sixth embodiment of the present invention.
With the above figures, certain embodiments of the invention have been illustrated and described in more detail below. The drawings and the description are not intended to limit the scope of the inventive concept in any way, but rather to illustrate it by those skilled in the art with reference to specific embodiments.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the invention, as detailed in the appended claims.
The technical solution of the present invention will be described in detail below with specific examples. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments. Embodiments of the present invention will be described below with reference to the accompanying drawings.
For a clear understanding of the technical solutions of the present application, a detailed description of the prior art solutions is first provided. The image sensor of the camera generally has PD dead pixels, i.e. phase dead pixels, which are caused by the problems generated when the optical signals of the process or the external scene are converted into the electrical signals. The phase defect of the image sensor cannot be automatically eliminated, and the generated image needs to be compensated. In the rear camera, the PDAF chip has a phase automatic focusing function, so that the PDAF chip can acquire all phase point positions of the image sensor. And then, acquiring a phase point position from the PDAF chip through the image signal processor, acquiring a compensation algorithm according to a loading flow of the PDAF chip, and finally, compensating the original image according to the phase point position and the compensation algorithm by the image signal processor. In the front camera, the processing chip does not use the PDAF chip, but generally uses the OV13B10 chip. The OV13B10 chip does not have the phase focusing function of the PDAF chip, and at the same time, does not have the function of acquiring the position of the phase point. The image signal processor needs to compensate the original image according to the phase point position and a compensation algorithm, and when the OV13B10 chip cannot acquire the phase point position, the image signal processor cannot compensate the original image, so that the image generated by the front-facing camera is easy to generate network-like noise, and the image quality is low.
Therefore, aiming at the technical problems that in the prior art, because the processing chip of the front camera is not a PDAF chip, the image signal processor cannot perform image compensation on the original image, and the quality of the finally generated image is low, the inventor finds that the phase point position can be determined by constructing a phase point position determination process applicable to the processing chip of the front camera, so that a compensation algorithm is determined according to the phase point position, and the image signal processor can perform compensation on the original image. Specifically, the front camera acquires an original image shot by the front camera, and then determines all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip. The front-facing camera acquires a preset compensation algorithm according to the position of the phase point. And compensating the original image according to the position of the phase point and a compensation algorithm to obtain a compensated image. The image compensation method of the embodiment of the invention adopts the phase point position determining process matched with the first processing chip, and the matching degree of the phase point position determining process and the first processing chip is higher, so that the first processing chip can determine all phase point positions matched with the original image through the phase point position process. Therefore, the front-facing camera can compensate the original image according to the phase point position and the compensation algorithm, and the quality of the finally generated image is high.
The inventor proposes a technical scheme of the application based on the creative discovery.
An application scenario of the image compensation method provided by the embodiment of the present invention is described below. As shown in fig. 1, 1 is a front camera, and 2 is a first processing chip. The network architecture of the application scene corresponding to the image compensation method provided by the embodiment of the invention comprises the following steps: a front camera 1 and a first processing chip 2. The first processing chip 2 may be a chip of the OV13B10 model, the first processing chip 2 comprising an image sensor. When receiving a shooting instruction of a terminal device control chip, the front-facing camera 1 acquires an original image shot by the front-facing camera, and the original image is obtained by converting an optical signal by an image sensor in the front-facing camera. The front-facing camera 1 determines all the phase point positions matched with the original image in the first processing chip 2 by adopting a phase point position determination process matched with the first processing chip 2. Meanwhile, the front camera 1 adopts an image signal processor in the front camera to obtain a preset compensation algorithm according to the position of the phase point, and the compensation algorithm can adopt a phase pixel correction algorithm. And finally, the front camera 1 adopts an image signal processor to compensate the original image according to the position of the phase point and a compensation algorithm so as to obtain a compensated image. The compensated image can be displayed on a display interface of the terminal device. The compensated image has no grid noise and high image quality.
The embodiments of the present invention will be described with reference to the accompanying drawings.
Fig. 2 is a schematic flow chart of an image compensation method according to a first embodiment of the present invention, and as shown in fig. 2, in this embodiment, an implementation subject of the embodiment of the present invention is an image compensation device, which may be integrated in a front camera, where an image is taken by the front camera, and the front camera includes: a first processing chip. The image compensation method provided by this embodiment includes the following steps:
and step S101, acquiring an original image shot by the front camera.
In this embodiment, the front-facing camera includes a first processing chip and an Image Signal Processor (hereinafter, referred to as "Image Signal Processor"), and the first processing chip includes an Image sensor. The first processing chip may be an OV13B10 model chip. The OV13B10 model chip does not have a motor and phase autofocus function unlike the PDAF chip.
In this embodiment, the image sensor has a plurality of phase points formed by photosensitive material, and the original image is converted from the external scene light signal by the image sensor in the front camera. The phase points on the image sensor are generally distributed according to regions due to the large number, as shown in fig. 3, where fig. 3 is a part of the phase points in a certain region. The PD dead pixel, i.e., phase dead pixel, in fig. 3 is represented by a black block, and RGB refers to a phase point. In fig. 3, right shift PD refers to a phase dead pixel with a right partial area being blocked, and left shift PD refers to a phase dead pixel with a left partial area being blocked. As can be seen from fig. 3, the number of phase-defect points of the image sensor is generally greater than 2, and has a certain number, and therefore, the phase-defect points affect the quality of the image generated by the front camera, such as causing network-like noise to appear in the image.
In this embodiment, the obtaining mode may be that the front-facing camera directly obtains the original image captured by the front-facing camera, or may be that the front-facing camera obtains the original image from a transfer database storing the original image, which is not limited in this embodiment.
Step S102, determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip.
In this embodiment, the phase point position determination process matched with the first processing chip may be a dedicated phase point position determination process designed for the first processing chip, or may be a phase point position determination process by calling other processing chips, such as a PDAF chip. The called phase point position determination process can be matched with the first processing chip through compatibility adjustment.
In this embodiment, since all the phase points need to be compensated when the original image is compensated, all the phase point positions in the first processing chip that match the original image need to be determined.
In this embodiment, the position of the phase point may be represented by the coordinate xy of each phase point.
And step S103, acquiring a preset compensation algorithm according to the position of the phase point.
In this embodiment, the front-facing camera may adopt an image signal processor in the front-facing camera to obtain a preset compensation algorithm according to the position of the phase point. In the rear camera, generally, when the PDAF chip in the rear camera is loaded, the process of obtaining the compensation algorithm is started. Meanwhile, the flow of the front camera acquiring the compensation algorithm in the prior art is the same as that of the rear camera, and the flow of acquiring the compensation algorithm can be started only when the PDAF chip is loaded. Therefore, since the first processing chip used by the front camera is not the PDAF chip, the front camera cannot acquire not only the phase point position but also the compensation algorithm. Even if the front camera acquires the position of the phase point, because the PDAF chip is not arranged, errors can be continuously reported when the process of acquiring the compensation algorithm is executed, and therefore the original image cannot be compensated.
In this embodiment, the flow of acquiring the compensation algorithm is modified, and the flow depending on the starting of the PDAF chip and the flow depending on the function of the PDAF chip are not executed. After the phase point position is obtained, the front-facing camera directly obtains a preset compensation algorithm according to the phase point position by adopting an image signal processor without starting a PDAF chip.
In this embodiment, the operating system of the image signal processor in the front camera may adopt an operating system of a high-pass platform or other platforms. The compensation algorithm may be a high-pass platform or other platform based PDPC (Phase Detection pixel correction, Chinese) algorithm. By using the PDPC algorithm, the original image can be compensated more accurately.
And step S104, compensating the original image according to the position of the phase point and a compensation algorithm to obtain a compensated image.
In this embodiment, when the phase point position and the compensation algorithm are obtained, the image signal processor may be used to compensate the original image according to the phase point position and the compensation algorithm, so as to obtain a compensated image.
The embodiment of the invention provides an image compensation method, which comprises the following steps: the image is shot for leading camera, and leading camera includes: the method is applied to the front camera and comprises the following steps: and acquiring an original image shot by the front camera. And determining all the phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip. And acquiring a preset compensation algorithm according to the position of the phase point. And compensating the original image according to the position of the phase point and a compensation algorithm to obtain a compensated image. The image compensation method of the embodiment of the invention adopts the phase point position determining process matched with the first processing chip, and the matching degree of the phase point position determining process and the first processing chip is higher, so that the first processing chip can determine all phase point positions matched with the original image through the phase point position process. Meanwhile, the flow for obtaining the compensation algorithm is modified to a certain extent, and the compensation algorithm is directly obtained without executing the flow depending on starting the PDAF chip and the flow depending on the functions of the PDAF chip. Therefore, the front-facing camera can compensate the original image according to the phase point position and the compensation algorithm, and the quality of the finally generated image is high.
Fig. 4 is a schematic flow chart of an image compensation method according to a second embodiment of the present invention, and as shown in fig. 4, the image compensation method according to this embodiment is further refined in step 102 based on the image compensation method according to the previous embodiment of the present invention. The image compensation method provided by the present embodiment includes the following steps.
It should be noted that the first processing chip includes an image sensor.
Step S201, an original image captured by the front camera is acquired.
In this embodiment, the implementation manner of step 201 is similar to that of step 101 in the previous embodiment of the present invention, and is not described in detail here.
Optionally, in this embodiment, a phase point position determination process matched with the first processing chip is obtained by using the first processing chip.
Determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip, wherein the phase point position determination process comprises the following steps:
and determining all the phase point positions matched with the original image in the first processing chip by adopting the first processing chip and the phase point position determination process matched with the first processing chip.
In this embodiment, the front-facing camera may adopt the first processing chip to obtain the phase point position determination process matched with the first processing chip, so that the first processing chip may determine all the phase point positions matched with the original image in the first processing chip according to the phase point position determination process matched with the first processing chip.
Step S202, factory information stored in the image sensor is acquired.
In this embodiment, a set of phase point position determination processes matched with the first processing chip is designed, so that the phase point position determination efficiency is improved. The image sensor stores the position of each phase point when the image sensor is shipped, so that shipping information can be acquired from the image sensor to determine the position of the phase point.
Step S203, determining all phase point positions matched with the original image from the image sensor according to factory information.
In this embodiment, since the factory information records the positions of all the phase points in the image sensor, all the phase point positions matched with the original image can be determined from the image sensor according to the factory information.
And step S204, acquiring a preset compensation algorithm according to the position of the phase point.
The implementation manner of step 204 is similar to that of step 103 in the previous embodiment of the present invention, and is not described herein again.
Optionally, in this embodiment, the front camera further includes: an image signal processor.
Obtaining a preset compensation algorithm according to the phase point position, comprising:
and the image signal processor receives a compensation algorithm acquisition request sent by the first processing chip according to the position of the phase point.
The image signal processor acquires the pre-stored compensation algorithm according to the compensation algorithm acquisition request.
In this embodiment, after the first processing chip determines the phase point position, the first processing chip sends a compensation algorithm obtaining request to the image signal processor, and the image signal processor obtains a compensation algorithm pre-stored in the image signal processor according to the compensation algorithm obtaining request. Through the interactive cooperation of the first processing chip and the image signal processor, the efficiency of original image compensation can be improved.
Optionally, in this embodiment, the compensation algorithm is a phase pixel correction algorithm.
Compensating the original image according to the position of the phase point and a compensation algorithm to obtain a compensated image, comprising:
and the image signal processor compensates the original image according to the position of the phase point and the phase pixel correction algorithm to obtain a compensated image.
In this embodiment, a phase pixel correction algorithm based on a high-pass platform or a joint platform may be adopted, and the image signal processor inputs the phase position into the phase pixel correction algorithm to compensate the original image.
And S205, compensating the original image according to the position of the phase point and a compensation algorithm to obtain a compensated image.
In this embodiment, the implementation manner of step 205 is similar to that of step 104 in the previous embodiment of the present invention, and is not described in detail here.
According to the image compensation method provided by the embodiment of the invention, a set of phase point position determining process matched with the first processing chip is directly designed, so that the phase point position determining efficiency is improved, and the overall efficiency of original image compensation is further improved.
Fig. 5 is a flowchart illustrating an image compensation method according to a third embodiment of the present invention. As shown in fig. 5, the image compensation method provided in this embodiment is further refined in each step based on the image compensation method provided in the first embodiment of the present invention. The image compensation method provided by the present embodiment includes the following steps.
It should be noted that the first processing chip includes an image sensor.
Step S301, acquiring an original image shot by the front camera.
In this embodiment, the implementation manner of step 301 is similar to that of step 201 in the previous embodiment of the present invention, and is not described in detail here.
Step S302, a phase point position determination procedure matched with the first processing chip is obtained, and all phase point positions matched with the original image in the first processing chip are determined.
In this embodiment, the phase point position determining process matched with the first processing chip may be a phase point position determining process dedicated to the first processing chip, or a phase point position determining process that can be used by the first processing chip after the phase point position determining processes of other processing chips are adjusted. The phase point position determination process matched with the first processing chip can be stored in the first processing chip, and can also be stored in other databases.
In this embodiment, the terminal device including the front camera further includes a rear camera, and the rear camera includes: and a second processing chip.
The phase point position determination process matched with the first processing chip is obtained, and comprises the following steps:
and calling the phase point position corresponding to the second processing chip to determine the flow.
And performing chip compatibility adjustment on the phase point position determination process corresponding to the second processing chip to obtain a phase point position determination process matched with the first processing chip.
In this embodiment, the terminal device generally has a front camera and a rear camera. The rear camera comprises a second processing chip, and the second processing chip generally uses a PDAF chip.
In this embodiment, the phase point position determination process corresponding to the second processing chip is subjected to chip compatibility adjustment, so as to obtain a phase point position determination process matched with the first processing chip. The adjusted phase point position determining process is used as a phase point position determining process matched with the first processing chip, and the operation of an actual process in the terminal equipment can be well compatible.
Step S303, acquiring a preset compensation algorithm according to the position of the phase point.
In this embodiment, the implementation manner of step 303 is similar to that of step 204 in the previous embodiment of the present invention, and is not described in detail here.
And S304, compensating the original image according to the position of the phase point and a compensation algorithm to obtain a compensated image.
In this embodiment, the implementation manner of step 304 is similar to that of step 205 in the previous embodiment of the present invention, and is not described in detail here.
According to the image compensation method provided by the embodiment of the invention, the phase point position determination process of the second processing chip of the rear camera is called, and chip compatibility adjustment is carried out on the process, so that the phase point position determination process matched with the first processing chip is obtained. In the same terminal equipment, programs of compensation processes of the front camera and the rear camera have certain degree of similarity, so that the operation of an actual process in the terminal equipment can be well compatible.
Meanwhile, in order to better understand the image compensation method of the present embodiment, the following describes in detail the linking application between the front camera and the rear camera in the terminal device. The first processing chip of the front camera of the embodiment adopts an OV13B10 chip, and the second processing chip of the rear camera adopts a PDAF chip. When the rear camera compensates the original image according to the phase point position and the compensation algorithm, the compensation is completed by depending on the image sensor end and the image signal processor end in the PDAF chip, and the Type of the executed compensation process is Type 2. When the front-facing camera compensates the original image according to the phase point position and the compensation algorithm, the front-facing camera only depends on the image signal processor end, and the Type of the executed compensation process is Type 3. Thus, depending on the front camera and rear camera compensation flow categories, the flow of Type2 can be executed when the rear camera is activated, and the flow of Type3 can be executed when the front camera is activated. Neither of the flows of Type3 are performed with respect to starting or identifying PDAF hardware. Therefore, independent operation of the image compensation process of the front camera and the rear camera is realized, and the interference between the front camera and the rear camera is reduced.
Fig. 6 is a schematic structural diagram of an image compensation apparatus according to a fourth embodiment of the present invention, as shown in fig. 6, in this embodiment, an image is captured by a front camera, and the front camera includes: a first processing chip, which is located in the front camera, the image compensation apparatus 400 includes:
and an image obtaining module 401, configured to obtain an original image captured by the front camera.
A determining module 402, configured to determine all phase point positions in the first processing chip that match the original image by using a phase point position determining procedure matched with the first processing chip.
And an algorithm obtaining module 403, configured to obtain a preset compensation algorithm according to the phase point position.
And a compensation module 404, configured to compensate the original image according to the phase point position and a compensation algorithm to obtain a compensated image.
The image compensation apparatus provided in this embodiment may implement the technical solution of the method embodiment shown in fig. 2, and the implementation principle and technical effect thereof are similar to those of the method embodiment shown in fig. 2, and are not described in detail herein.
Meanwhile, fig. 7 is a schematic structural diagram of an image compensation apparatus according to a fifth embodiment of the present invention, and as shown in fig. 7, another embodiment of the image compensation apparatus according to the present invention further refines the image compensation apparatus 500 on the basis of the image compensation apparatus according to the previous embodiment.
Optionally, in this embodiment, the image compensation apparatus 500 further includes:
a process obtaining module 501, configured to obtain a phase point position determination process matched with the first processing chip.
Optionally, in this embodiment, the terminal device including the front camera further includes a rear camera, and the rear camera includes: and a second processing chip.
The flow acquiring module 501 is specifically configured to:
and calling the phase point position corresponding to the second processing chip to determine the flow. And performing chip compatibility adjustment on the phase point position determination process corresponding to the second processing chip to obtain a phase point position determination process matched with the first processing chip.
Optionally, in this embodiment, the first processing chip includes an image sensor.
The determining module 402 is specifically configured to:
and acquiring factory information stored in the image sensor. And determining all phase point positions matched with the original image from the image sensor according to factory information.
Optionally, in this embodiment, a phase point position determination process matched with the first processing chip is obtained by using the first processing chip.
The determining module 402 is specifically configured to:
and determining all the phase point positions matched with the original image in the first processing chip by adopting the first processing chip and the phase point position determination process matched with the first processing chip.
Optionally, in this embodiment, the front camera further includes: an image signal processor.
The algorithm obtaining module 403 is specifically configured to:
and the image signal processor receives a compensation algorithm acquisition request sent by the first processing chip according to the position of the phase point. The image signal processor acquires the pre-stored compensation algorithm according to the compensation algorithm acquisition request.
Optionally, in this embodiment, the compensation algorithm is a phase pixel correction algorithm.
The compensation module 404 is specifically configured to:
and the image signal processor compensates the original image according to the position of the phase point and the phase pixel correction algorithm to obtain a compensated image.
The image compensation apparatus provided in this embodiment may implement the technical solutions of the method embodiments shown in fig. 2 to 5, and the implementation principles and technical effects thereof are similar to those of the method embodiments shown in fig. 2 to 5, and are not described in detail herein.
As shown in fig. 8, fig. 8 is a schematic structural diagram of a front camera provided in a sixth embodiment of the present invention. The first processing chip and the image signal processor in the front camera are intended for various forms of processors. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the inventions described and/or claimed herein.
As shown in fig. 8, the front camera includes: a first processor 601, a first memory 602, a second processor 603, and a second memory 604. The various components are interconnected using different buses and may be mounted on a common motherboard or in other manners as desired. The processor may process instructions executed within the front-facing camera.
The first memory 602 and the second memory 604 are non-transitory computer readable storage media provided by the present invention. The non-transitory computer-readable storage medium of the present invention stores computer instructions for causing a computer to execute the image compensation method provided by the present invention.
The first memory 602 and the second memory 604 serve as a non-transitory computer-readable storage medium, and may be used to store non-transitory software programs, non-transitory computer-executable programs, and modules, such as program instructions/modules corresponding to the image compensation method in the embodiment of the present invention (for example, the image acquisition module 401, the determination module 402, the algorithm acquisition module 403, and the compensation module 404 shown in fig. 6). The first processor 601 executes various functional applications and data processing, i.e., the image compensation method in the above-described method embodiment, by executing the non-transitory software programs, instructions and modules stored in the first memory 602, and the second processor 603 executes the non-transitory software programs, instructions and modules stored in the second memory 604.
The present embodiment also provides a computer program product comprising a computer program which, when executed by a processor, implements the image compensation method as in the first to third embodiments.
Other embodiments of the invention will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the embodiments of the invention following, in general, the principles of the embodiments of the invention and including such departures from the present disclosure as come within known or customary practice within the art to which the embodiments of the invention pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of embodiments of the invention being indicated by the following claims.
It is to be understood that the embodiments of the present invention are not limited to the precise arrangements described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of embodiments of the invention is limited only by the appended claims.

Claims (7)

1. An image compensation method is characterized in that the image is shot by a front camera, and the front camera comprises: the method is applied to a front camera and comprises the following steps:
acquiring an original image shot by a front camera;
determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip;
acquiring a preset compensation algorithm according to the phase point position;
compensating the original image according to the position of the phase point and the compensation algorithm to obtain a compensated image;
before determining all the phase point positions matched with the original image in the first processing chip by adopting the phase point position determination process matched with the first processing chip, the method further comprises the following steps:
obtaining a phase point position determining process matched with the first processing chip;
include the terminal equipment of leading camera still includes rear camera, include in the rear camera: a second processing chip;
the phase point position determination process for obtaining the phase point position matched with the first processing chip comprises the following steps:
calling a phase point position corresponding to the second processing chip to determine a flow;
performing chip compatibility adjustment on the phase point position determination process corresponding to the second processing chip to obtain a phase point position determination process matched with the first processing chip;
or
The first processing chip comprises an image sensor;
the determining, by using a phase point position determination process matched with a first processing chip, all phase point positions matched with the original image in the first processing chip includes:
acquiring factory information stored in the image sensor; wherein, the factory information records all phase point positions in the image sensor;
and determining all phase point positions matched with the original image from the image sensor according to the factory information.
2. The method of claim 1, wherein the determining all the phase point positions in the first processing chip matched with the original image by using the phase point position determination process matched with the first processing chip comprises:
and determining all the phase point positions matched with the original image in the first processing chip by adopting the first processing chip and a phase point position determination process matched with the first processing chip.
3. The method of claim 1, wherein the front facing camera further comprises: an image signal processor;
the obtaining of the preset compensation algorithm according to the phase point position includes:
the image signal processor receives a compensation algorithm acquisition request sent by a first processing chip according to the position of the phase point;
and the image signal processor acquires the pre-stored compensation algorithm according to the compensation algorithm acquisition request.
4. The method of claim 3, wherein the compensation algorithm is a phase pixel correction algorithm;
the compensating the original image according to the position of the phase point and the compensation algorithm to obtain a compensated image includes:
and the image signal processor compensates the original image according to the position of the phase point and the phase pixel correction algorithm to obtain a compensated image.
5. An image compensation device, wherein the image is taken by a front camera, and the front camera comprises: a first processing chip, the device is located at a front camera, the device includes:
the image acquisition module is used for acquiring an original image shot by the front camera;
the determining module is used for determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determining process matched with the first processing chip;
the algorithm obtaining module is used for obtaining a preset compensation algorithm according to the phase point position;
the compensation module is used for compensating the original image according to the position of the phase point and the compensation algorithm so as to obtain a compensated image;
the device further comprises:
the flow acquisition module is used for acquiring a phase point position determination flow matched with the first processing chip;
include the terminal equipment of leading camera still includes rear camera, include in the rear camera: a second processing chip;
the flow acquisition module is specifically configured to:
calling a phase point position corresponding to the second processing chip to determine a flow; performing chip compatibility adjustment on the phase point position determination process corresponding to the second processing chip to obtain a phase point position determination process matched with the first processing chip;
or
The first processing chip comprises an image sensor;
the determining module is specifically configured to:
acquiring factory information stored in the image sensor; and determining all phase point positions matched with the original image from the image sensor according to the factory information.
6. A front camera, comprising: a first processing chip and an image signal processor; the first processing chip is electrically interconnected with the image signal processor; the first processing chip comprises a first processor and a first memory; the image signal processor includes a second processor and a second memory;
a first memory stores the first processor-executable instructions;
the first processor is configured to: acquiring an original image shot by a front camera; determining all phase point positions matched with the original image in the first processing chip by adopting a phase point position determination process matched with the first processing chip;
the first processor is further configured to: obtaining a phase point position determining process matched with the first processing chip;
include the terminal equipment of leading camera still includes rear camera, include in the rear camera: a second processing chip;
the first processor is further configured to: the phase point position determination process for obtaining the phase point position matched with the first processing chip comprises the following steps:
calling a phase point position corresponding to the second processing chip to determine a flow;
performing chip compatibility adjustment on the phase point position determination process corresponding to the second processing chip to obtain a phase point position determination process matched with the first processing chip;
or
The first processing chip comprises an image sensor;
the first processor is further configured to: the determining, by using a phase point position determination process matched with a first processing chip, all phase point positions matched with the original image in the first processing chip includes:
acquiring factory information stored in the image sensor; wherein, the factory information records all phase point positions in the image sensor;
determining all phase point positions matched with the original image from the image sensor according to the factory information;
a second memory stores the second processor-executable instructions;
the second processor is configured to: acquiring a preset compensation algorithm according to the phase point position; and compensating the original image according to the position of the phase point and the compensation algorithm to obtain a compensated image.
7. A computer-readable storage medium having computer-executable instructions stored therein, which when executed by a processor, are configured to implement the image compensation method of any one of claims 1 to 4.
CN202111103573.3A 2021-09-22 2021-09-22 Image compensation method, device, medium and front camera Active CN113556472B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111103573.3A CN113556472B (en) 2021-09-22 2021-09-22 Image compensation method, device, medium and front camera

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111103573.3A CN113556472B (en) 2021-09-22 2021-09-22 Image compensation method, device, medium and front camera

Publications (2)

Publication Number Publication Date
CN113556472A CN113556472A (en) 2021-10-26
CN113556472B true CN113556472B (en) 2021-12-14

Family

ID=78106618

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111103573.3A Active CN113556472B (en) 2021-09-22 2021-09-22 Image compensation method, device, medium and front camera

Country Status (1)

Country Link
CN (1) CN113556472B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110336993A (en) * 2019-07-02 2019-10-15 Oppo广东移动通信有限公司 Depth camera head controlling method, device, electronic equipment and storage medium

Family Cites Families (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003247823A (en) * 2002-02-26 2003-09-05 Seiko Precision Inc Method and device for detecting phase difference, range finder, and image pickup device
CN103595935B (en) * 2013-10-15 2017-02-15 深圳市掌网科技股份有限公司 Dynamic compensation method and system for three-dimensional video image dead pixels
CN106303192B (en) * 2015-05-25 2019-05-07 小米科技有限责任公司 Terminal control method and terminal
CN105847680B (en) * 2016-03-28 2017-09-15 维沃移动通信有限公司 A kind of camera power consumption control method and mobile terminal
CN106792748B (en) * 2016-12-20 2020-03-03 北京小米移动软件有限公司 Data transmission method, device, base station and terminal
CN106998455A (en) * 2017-03-31 2017-08-01 努比亚技术有限公司 A kind of dual camera image pickup method and terminal
CN109981965B (en) * 2017-12-27 2021-01-01 华为技术有限公司 Focusing method and electronic equipment
CN110223643B (en) * 2018-03-01 2022-02-11 京东方科技集团股份有限公司 Data transmission method, assembly and system and display device
CN110347433A (en) * 2018-04-03 2019-10-18 京东方科技集团股份有限公司 Method for parameter configuration, device and display device
KR20200034276A (en) * 2018-09-21 2020-03-31 엘지이노텍 주식회사 Camera module and method of operating the same
CN110460825A (en) * 2019-08-02 2019-11-15 武汉华星光电半导体显示技术有限公司 A kind of imaging compensating device, imaging compensating method and its application
CN110750272B (en) * 2019-10-12 2023-09-05 昆山丘钛微电子科技有限公司 Data burning method for image pickup apparatus, burning apparatus, and storage medium
CN112866553B (en) * 2019-11-12 2022-05-17 Oppo广东移动通信有限公司 Focusing method and device, electronic equipment and computer readable storage medium
CN111064898B (en) * 2019-12-02 2021-07-16 联想(北京)有限公司 Image shooting method and device, equipment and storage medium
CN112017137B (en) * 2020-08-19 2024-02-27 深圳市锐尔觅移动通信有限公司 Image processing method, device, electronic equipment and computer readable storage medium
CN112004026B (en) * 2020-09-01 2021-06-29 北京小米移动软件有限公司 Phase focusing device, phase focusing method, shooting device, terminal equipment and medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110336993A (en) * 2019-07-02 2019-10-15 Oppo广东移动通信有限公司 Depth camera head controlling method, device, electronic equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于图像匹配与补偿技术的共享屏幕实现方法;彭小平等;《信息安全与通信保密》;20090310(第03期);全文 *

Also Published As

Publication number Publication date
CN113556472A (en) 2021-10-26

Similar Documents

Publication Publication Date Title
KR102385360B1 (en) Electronic device performing image correction and operation method of thereof
JP6469678B2 (en) System and method for correcting image artifacts
US11290641B2 (en) Electronic device and method for correcting image corrected in first image processing scheme in external electronic device in second image processing scheme
CN104980652A (en) Image processing apparatus and image processing method
CN110099220B (en) Panoramic stitching method and device
CN110225232B (en) Image processing apparatus
JP5054184B2 (en) Lens shading compensation method with autofocus camera module
WO2020011112A1 (en) Image processing method and system, readable storage medium, and terminal
JP2012114849A (en) Image processing apparatus and image processing method
JP2015088833A (en) Image processing device, imaging device, and image processing method
CN110581956A (en) Image processing method, image processing device, storage medium and electronic equipment
CN113992850A (en) ISP-based image processing method and device, storage medium and camera equipment
CN111742320A (en) Method of providing text translation management data related to application and electronic device thereof
CN112383772B (en) Camera performance automatic test method and device, electronic equipment and storage medium
CN108198189B (en) Picture definition obtaining method and device, storage medium and electronic equipment
CN109257540B (en) Photographing correction method of multi-photographing lens group and photographing device
KR102418852B1 (en) Electronic device and method for controlling an image display
CN113556472B (en) Image compensation method, device, medium and front camera
EP3834170B1 (en) Apparatus and methods for generating high dynamic range media, based on multi-stage compensation of motion
CN111182223B (en) Image processing method, image processing device, storage medium and electronic equipment
CN110969575B (en) Adaptive image stitching method and image processing device
CN116456191A (en) Image generation method, device, equipment and computer readable storage medium
CN115174878B (en) Projection picture correction method, apparatus and storage medium
CN113711230A (en) Method, system, and computer readable medium for removing veiling glare in an image
US8629925B2 (en) Image processing apparatus, image processing method, and computer program

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant