Gamma curve debugging method, gamma curve debugging device and computer storage medium

CN116193271BActive Publication Date: 2026-08-11ZHEJIANG DAHUA TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-16
Publication Date
2026-08-11

AI Technical Summary

Technical Problem

[0003]本申请提出了一种伽马曲线调试方法、伽马曲线调试装置及计算机存储介质,以解决上述多个设备上的图像会存在亮度和动态范围差异性的问题

Benefits of technology

[0015] The beneficial effects of this application are as follows: Unlike the prior art, the gamma curve debugging method of this application first acquires the first image data of the reference device and the second image data of the test device under the same environment; then, it calculates the data difference between the first image data and the second image data, and uses the data difference and the first image data of the reference device to obtain the difference curve between the reference device and the test device; finally, it determines the gamma curve of the test device based on the difference curve and the gamma curve of the reference device. The gamma curve debugging method of this application can automatically calibrate the gamma curve of the test device during the development of multi-series devices, and can eliminate the problem of differences between different devices, thereby effectively improving the brightness consistency of the test device image within the dynamic range.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116193271B_ABST
    Figure CN116193271B_ABST
Patent Text Reader

Abstract

This application discloses a gamma curve calibration method, a gamma curve calibration device, and a computer storage medium. The gamma curve calibration method includes: acquiring first image data from a reference device and second image data from a test device under identical conditions; acquiring the data difference between the first and second image data; using the data difference and the first image data from the reference device to obtain a difference curve between the reference device and the test device; and determining the gamma curve of the test device based on the difference curve and the gamma curve of the reference device. Through this method, the gamma curve calibration method of this application can automatically calibrate the gamma curve and effectively eliminate device variability issues, improving the dynamic range brightness consistency of the device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of image processing technology, specifically to a gamma curve debugging method, a gamma curve debugging device, and a computer storage medium. Background Technology

[0002] In the current field of image processing technology, because different devices have different lenses, sensors, and filters, even under the same illumination conditions and with consistent average brightness from the sensors, images from different devices may exhibit localized brightness inconsistencies. This issue will manifest in the image's RAW data. If differences in RAW data are caused by device variations, these differences will be further amplified during subsequent image processing steps. This can lead to variations in brightness and dynamic range across images from multiple devices when developing multi-series devices. Summary of the Invention

[0003] This application proposes a gamma curve debugging method, a gamma curve debugging device, and a computer storage medium to solve the problem of differences in brightness and dynamic range in images on the aforementioned multiple devices.

[0004] To solve the above-mentioned technical problems, one technical solution adopted in this application is: to provide a gamma curve debugging method, the method comprising: acquiring first image data of a reference device and second image data of a test device under the same environment; acquiring the data difference between the first image data and the second image data; using the data difference and the first image data of the reference device to obtain the difference curve between the reference device and the test device; and determining the gamma curve of the test device based on the difference curve and the gamma curve of the reference device.

[0005] The gamma curve debugging method also includes: obtaining the average brightness based on the initial image data; and setting the light intake of the reference device and the test device according to the average brightness.

[0006] The process of acquiring first image data from a reference device and second image data from a test device under the same environment includes: acquiring third image data from a reference device and fourth image data from a test device under the same environment; converting the third image data from the reference device into first image data; and converting the fourth image data from the test device into second image data. The first and second image data are of RGB data type, and the third and fourth image data are of RAW data type.

[0007] The process of obtaining the data difference between the first image data and the second image data includes: obtaining the first channel data, the second channel data, and the third channel data of the first image data; obtaining the first channel data, the second channel data, and the third channel data of the second image data; obtaining the first channel data difference between the first channel data of the first image data and the first channel data of the second image data; obtaining the second channel data difference between the second channel data of the first image data and the second channel data of the second image data; and obtaining the third channel data difference between the third channel data of the first image data and the third channel data of the second image data.

[0008] Specifically, by using the data difference and the first image data of the reference device, the difference curve between the reference device and the test device is obtained, including:

[0009] First-channel difference data is obtained by using the difference between the first channel data and the first channel data of the first image data; second-channel difference data is obtained by using the difference between the second channel data and the second channel data of the first image data; third-channel difference data is obtained by using the difference between the third channel data and the third channel data of the first image data; the first-channel difference data, the second-channel difference data, and the third-channel difference data are converted into a two-dimensional dataset; and difference curves between the reference device and the test device are generated based on the two-dimensional dataset.

[0010] The two-dimensional dataset includes channel data and difference data. The process of generating a difference curve between the reference device and the test device based on the two-dimensional dataset includes: using the channel data in the two-dimensional dataset as the horizontal axis and the difference data as the vertical axis to fit and generate a mapping two-dimensional graph; obtaining the average value of several difference data corresponding to each channel data; and fitting and generating a difference curve between the reference device and the test device according to each channel data and its corresponding average difference data.

[0011] The process of determining the gamma curve of the test device based on the difference curve and the gamma curve of the reference device includes: under the same channel data, using the average difference data of the difference curve to perform a linear multiplication compensation operation on the brightness value of the gamma curve of the reference device to obtain the brightness value of the gamma curve of the test device under the channel data.

[0012] Before performing a linear multiplication compensation operation on the brightness value of the gamma curve of the reference device using the average difference data of the difference curve, the gamma curve method also includes: obtaining the maximum channel data of the gamma curve of the reference device; and performing a linear mapping on the channel data of the difference curve according to the maximum channel data to unify the maximum channel data of the difference curve and the gamma curve of the reference device.

[0013] To solve the above-mentioned technical problems, one technical solution adopted in this application is to provide a gamma curve debugging device, which includes a memory and a processor coupled to the memory, wherein the memory is used to store program data and the processor is used to execute the program data to implement the gamma curve debugging method described above.

[0014] To solve the above-mentioned technical problems, another technical solution adopted in this application is to provide a computer storage medium that stores program instructions internally, and the program instructions are executed to implement the gamma curve debugging method of any of the above-mentioned methods.

[0015] The beneficial effects of this application are as follows: Unlike the prior art, the gamma curve debugging method of this application first acquires the first image data of the reference device and the second image data of the test device under the same environment; then, it calculates the data difference between the first image data and the second image data, and uses the data difference and the first image data of the reference device to obtain the difference curve between the reference device and the test device; finally, it determines the gamma curve of the test device based on the difference curve and the gamma curve of the reference device. The gamma curve debugging method of this application can automatically calibrate the gamma curve of the test device during the development of multi-series devices, and can eliminate the problem of differences between different devices, thereby effectively improving the brightness consistency of the test device image within the dynamic range. Attached Figure Description

[0016] Figure 1 This is a flowchart illustrating the first embodiment of the gamma curve debugging method provided in this application;

[0017] Figure 2 This is a schematic diagram of an embodiment of the TC004HD test card provided in this application;

[0018] Figure 3 This is a flowchart illustrating the second thermal embodiment of the gamma curve debugging method provided in this application;

[0019] Figure 4 yes Figure 1 A flowchart illustrating a specific implementation method for step S101;

[0020] Figure 5 yes Figure 1 A flowchart illustrating a specific implementation method for step S102;

[0021] Figure 6 yes Figure 1 A flowchart illustrating a specific implementation method for step S103;

[0022] Figure 7 yes Figure 6 A flowchart illustrating the specific implementation method of step S503 in the middle section;

[0023] Figure 8 This is a two-dimensional schematic diagram illustrating the mapping between RGB values ​​and diffRGB values ​​provided in this application;

[0024] Figure 9 This is a schematic diagram of an embodiment of the difference curve provided in this application;

[0025] Figure 10 yes Figure 1 A flowchart illustrating a specific implementation method for step S104;

[0026] Figure 11 This is a schematic diagram of the structure of an embodiment of the gamma curve debugging device provided in this application;

[0027] Figure 12 This is a schematic diagram of the structure of an embodiment of the computer storage medium provided in this application. Detailed Implementation

[0028] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of the embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.

[0029] During the development of multi-series devices, because different camera devices have different lenses, sensors, and filters, even under the same illumination environment and with the same average brightness of the sensor, the images acquired by different camera devices will have local brightness inconsistencies.

[0030] The problem of inconsistent local brightness in an image will be reflected in the raw data of the acquired image. RAW refers to the original image file, which is simply the data information before the image sensor operates to generate the image. The photographic equipment collects light through the lens and interprets and calculates the light to form an image.

[0031] If differences in RAW image data are caused by variations in device components, these differences will be further amplified during subsequent image processing. This can lead to variations in brightness and dynamic range across multiple devices during multi-series device development. Dynamic range refers to the richness of detail in both dark and bright areas simultaneously recorded by a camera; a higher dynamic range allows for the recording of more detailed images. In camera devices, variations in graphics cards or monitors can cause brightness deviations in the actual output image. Gamma curves are used to correct these brightness deviations.

[0032] To address the issue of discrepancies in image RAW data caused by device variations and to obtain new gamma curves for the test equipment, this application first proposes a gamma curve debugging method. (See [link to relevant documentation]). Figure 1 , Figure 1 This is a flowchart illustrating the first embodiment of the gamma curve debugging method provided in this application. Figure 1 As shown, the gamma curve debugging method in this embodiment specifically includes steps S101 to S104:

[0033] Step S101: Under the same environment, acquire the first image data of the reference device and the second image data of the test device respectively.

[0034] To eliminate the device differences between the test equipment and the reference equipment, the gamma curve debugging device first needs to acquire the first image data of the reference equipment under the same environment and the second image data of the test equipment under the same environment.

[0035] For example, when acquiring the first image data of the reference device, the RAW data of the reference device can be acquired under a specific color temperature environment and converted into the first image data. The first image data is the RGB data of the reference device and the gamma curve data of the reference device under the current environment. When acquiring the gamma curve of the reference device and the first image data, the color temperature is not limited. The color temperature can be a fixed color temperature or a full color temperature, depending on whether the reference device uses different gamma curves according to different color temperature environments.

[0036] After acquiring the first image data from the reference device, when acquiring the second image data from the test device, RAW data of the test device under the same color temperature and environment is acquired and converted into the second image data, which is the RGB data of the test device. In this embodiment, the same demosaic algorithm can be used to convert RAW data into RGB data.

[0037] Furthermore, when acquiring the first image data from the reference device and the second image data from the test device, an Imatest TC004HD test card can be placed within the shooting areas of both the reference device and the test device, such as... Figure 2 As shown, Figure 2 This is a schematic diagram of an embodiment of the TC004HD test card provided in this application. Placing the Imatest TC004HD test card can increase the color difference of the acquired image data, which is beneficial to improving the computational efficiency of subsequent methods. In other embodiments, other test cards may also be placed within the shooting area, which is not limited here.

[0038] Step S102: Obtain the data difference between the first image data and the second image data.

[0039] After acquiring the first image data of the reference device and the second image data of the test device under the same environment, the gamma curve debugging device calculates the RGB data difference between the first image data and the second image data.

[0040] For example, in this embodiment, the demosaic algorithm can be used to convert the RAW format image data of the reference device and the RAW format image data of the test device into RGB format image data, and then the data difference between the two can be calculated. Demosaic is the most important step in image processing; its main function is to convert the RAW format data acquired by the sensor into a complete RGB data format that is visible to the human eye. In other embodiments, other algorithms can also be used for format conversion, which are not limited here.

[0041] Step S103: Using the data difference and the first image data of the reference device, obtain the difference curve between the reference device and the test device.

[0042] After obtaining the data difference between the reference device and the test device in step S102, the gamma curve debugging device uses the data difference and the first image data of the reference device to obtain the difference data of the three color channels of the reference device and the test device. Finally, it uses the difference data of the three color channels to fit and generate the difference curve between the reference device and the test device.

[0043] Step S104: Determine the gamma curve of the test equipment based on the difference curve and the gamma curve of the reference equipment.

[0044] The gamma curve debugging device performs a linear multiplication operation between the acquired difference curve and the gamma curve of the parameter device, as described below, to determine the gamma curve of the test device.

[0045] Unlike existing technologies, the gamma curve debugging method of this application first acquires first image data of a reference device and second image data of a test device under the same environment; then, it calculates the data difference between the first and second image data, and uses the data difference and the first image data of the reference device to obtain the difference curve between the reference device and the test device; finally, it determines the gamma curve of the test device based on the difference curve and the gamma curve of the reference device. The gamma curve debugging method of this application can automatically calibrate the gamma curve of the test device during the development of multi-series devices, and can eliminate the problem of differences between different devices, thereby effectively improving the brightness consistency of the test device image within the dynamic range.

[0046] Optionally, please refer to Figure 3 , Figure 3 This is a schematic flowchart of the second thermal embodiment of the gamma curve debugging method provided in this application. Figure 3As shown, the gamma curve debugging method in this embodiment specifically includes steps S201 to S206:

[0047] Step S201: Obtain the average brightness based on the initial image data.

[0048] To acquire the first image data from the reference device and the second image data from the test device, the gamma curve debugging device must first be set up in the same environment as the reference device and the test device, and the inputs of the reference device and the test device should also be the same.

[0049] In this embodiment, initial image data of the reference device in its initial state can be obtained first. The initial image data includes the RAW data of the reference device in its initial state. The average brightness is calculated based on the obtained RAW data of the reference device in its initial state.

[0050] Step S202: Set the light intake of the reference device and the test device according to the average brightness.

[0051] After calculating the average brightness of the RAW data of the reference device in its initial state, the amount of light entering the reference device in its initial state can be obtained based on the average brightness. Therefore, before the step of obtaining the first image data of the reference device and the second image data of the test device, the amount of light entering the reference device and the test device can be set according to the average brightness so that the amount of light entering the reference device and the test device are the same.

[0052] Step S203: Under the same environment, acquire the first image data of the reference device and the second image data of the test device respectively.

[0053] Step S203 is the same as step S101, and will not be repeated here.

[0054] Step S204: Obtain the data difference between the first image data and the second image data.

[0055] Step S204 is the same as step S102, and will not be repeated here.

[0056] Step S205: Using the data difference and the first image data of the reference device, obtain the difference curve between the reference device and the test device.

[0057] Step S205 is the same as step S103, and will not be repeated here.

[0058] Step S206: Determine the gamma curve of the test equipment based on the difference curve and the gamma curve of the reference equipment.

[0059] Step S206 is the same as step S104, and will not be repeated here.

[0060] Optionally, based on the above embodiments, the method for acquiring the first image data of the reference device and the second image data of the test device is as follows: Figure 4 As shown, please refer to Figure 4 , Figure 4 yes Figure 1 A flowchart illustrating a specific implementation of step S101 is provided. In this embodiment, the first and second image data are of RGB data type, while the third and fourth image data are of RAW data type. This embodiment can be achieved through... Figure 4 The method shown implements step S101, and the specific implementation steps include steps S301 to S303:

[0061] Step S301: Under the same environment, acquire the third image data of the reference device and the fourth image data of the test device respectively.

[0062] Due to the differences in components between the reference device and the test device, the RAW format image data acquired by the two devices will also differ. Therefore, the third image data in RAW format from the reference device and the fourth image data in RAW format from the test device should be acquired separately under the same environment.

[0063] Step S302: Convert the third image data of the reference device into the first image data.

[0064] To facilitate subsequent calculations of differences in image data, the gamma curve debugging device needs to convert the third image data from the reference device into the first image data, that is, convert the RAW format data obtained from the reference device into RGB data that is more conducive to calculating differences.

[0065] Step S303: Convert the fourth image data of the test device into the second image data.

[0066] Similarly, the gamma curve debugging device also needs to convert the fourth image data of the test equipment into the second image data, that is, to convert the RAW format data obtained from the test equipment into RGB data that is conducive to calculating differences.

[0067] Optionally, the method for obtaining the data difference between the first image data and the second image data is as follows: Figure 5 As shown, please refer to Figure 5 , Figure 5 yes Figure 1 A flowchart illustrating a specific implementation method for step S102. This embodiment can be achieved through, as shown below... Figure 5 The method shown implements step S102, and the specific implementation steps include steps S401 to S404:

[0068] Step S401: Obtain the first channel data, the second channel data and the third channel data of the first image data, and obtain the first channel data, the second channel data and the third channel data of the second image data.

[0069] After converting the RAW data of the reference device into first image data in RGB format, the gamma curve debugging device can obtain the first channel data, second channel data and third channel data of the first image data based on the first image data in RGB format; similarly, the gamma curve debugging device can also obtain the first channel data, second channel data and third channel data of the second image data based on the second image data in RGB format.

[0070] Step S402: Obtain the difference between the first channel data of the first image data and the first channel data of the second image data.

[0071] The gamma curve debugging device calculates the difference between the first channel data of the first image data and the first channel data of the second image data, and denotes it as diffR.

[0072] Step S403: Obtain the second channel data difference between the second channel data of the first image data and the second channel data of the second image data.

[0073] The gamma curve debugging device calculates the difference between the second channel data of the first image data and the second channel data of the second image data, and denotes it as diffG.

[0074] Step S404: Obtain the difference between the third channel data of the first image data and the third channel data of the second image data.

[0075] The gamma curve debugging device calculates the difference between the third channel data of the first image data and the third channel data of the second image data, and denots it as diffB.

[0076] In this embodiment, the calculated data differences diffR, diffG, and diffB are consistent with the resolution of the RAW data.

[0077] Optionally, the method for obtaining the difference curves between the reference device and the test device is as follows: Figure 6 As shown, please refer to Figure 6 , Figure 6 yes Figure 1 A flowchart illustrating a specific implementation method for step S103. This embodiment can be achieved through, as follows: Figure 6 The method shown implements step S103, and the specific implementation steps include steps S501 to S503:

[0078] Step S501: Obtain first channel difference data by using the first channel data difference and the first channel data of the first image data; obtain second channel difference data by using the second channel data difference and the second channel data of the first image data; obtain third channel difference data by using the third channel data difference and the third channel data of the first image data.

[0079] The gamma curve debugging device obtains first channel difference data by using the first channel data difference and the first channel data of the first image data, obtains second channel difference data by using the second channel data difference and the second channel data of the first image data, and obtains third channel difference data by using the third channel data difference and the third channel data of the first image data.

[0080] When calculating the first channel difference data, the first channel data of the first image data of the reference device is first obtained, that is, the pixel value R of the first channel. Then, the ratio of the first channel data difference diffR to the pixel value R of the first channel is obtained. The calculation formula is diffRatioR = diffR / R. Here, diffRatioR represents the first channel difference data, and its value ranges from 0 to 1.

[0081] The difference between the second and third channel data can be obtained as described above. The formula for calculating the difference between the second and third channel data is diffRatioG = diffG / G, and the formula for calculating the difference between the third and third channel data is diffRatioB = diffB / B, where G is the second channel data of the first image data of the reference device, i.e., the pixel value of the second channel, and diffRatioG represents the difference between the second and third channels; B is the third channel data of the first image data of the reference device, i.e., the pixel value of the third channel, and diffRatioB represents the difference between the third and third channels.

[0082] Step S502: Convert the first channel difference data, the second channel difference data, and the third channel difference data into a two-dimensional dataset.

[0083] The gamma curve adjustment device acquires the first channel difference data (diffRatioR), the second channel difference data (diffRatioG), and the third channel difference data (diffRatioB), and then converts them into a two-dimensional dataset (diffRatioRGB). It should be noted that pixels at different physical locations may have the same RGB value, but different diffRGB values, resulting in differences in the acquired diffRatioRGB.

[0084] Step S503: Generate the difference curve between the reference device and the test device based on the two-dimensional dataset.

[0085] The gamma curve debugging device obtains the diffRatioRGB values ​​corresponding to the continuous RGB values ​​from 0 to 255 based on the acquired two-dimensional dataset, takes the average value, and then performs linear fitting on this value to obtain the difference curve between the reference device and the test device.

[0086] Optionally, please refer to Figure 7 , Figure 7 yes Figure 6 A flowchart illustrating the specific implementation method of step S503. In this embodiment, the two-dimensional dataset includes channel data and difference data. Figure 7 As shown, this embodiment can be achieved through, as... Figure 7 The method shown implements step S503, and the specific implementation steps include steps S601 to S603:

[0087] Step S601: Using the channel data in the two-dimensional dataset as the x-axis and the difference data as the y-axis, fit and generate a two-dimensional mapping graph.

[0088] Please see Figure 8 , Figure 8 This is a two-dimensional schematic diagram illustrating the mapping between RGB values ​​and diffRGB values ​​provided in this application. For example... Figure 8 As shown, the gamma curve debugging device uses the channel data in the two-dimensional dataset as the x-axis and the difference data as the y-axis to fit and generate a curve like... Figure 8 The diagram shown is a two-dimensional mapping.

[0089] Step S602: Obtain the average value of several difference data corresponding to each channel data.

[0090] The gamma curve debugging device acquires the average value of several difference data corresponding to each channel's data, such as... Figure 8 As shown, the horizontal axis represents the RGB values, and the vertical axis represents the corresponding diffRatioRGB values. The final fitted data is generated as follows: Figure 8 After obtaining the two-dimensional mapping diagram shown, the average value of the difference data diffRGB values ​​corresponding to each RGB value from 0 to 255 is then obtained.

[0091] Step S603: Based on the data of each channel and the average value of its corresponding difference data, fit and generate the difference curve between the reference device and the test device.

[0092] Please see Figure 9 , Figure 9This is a schematic diagram of an embodiment of the difference curve provided in this application. As shown in Figure 9, the gamma curve debugging device generates a difference curve between the reference device and the test device by fitting the average value of each channel's data and its corresponding difference data. That is, after averaging all the diffRatioRGB values ​​corresponding to the continuous RGB values ​​from 0 to 255, a linear fit is performed to generate the difference curve between the reference device and the test device.

[0093] Optionally, the method for determining the gamma curve of the test equipment is as follows: Figure 10 As shown, please refer to Figure 10 , Figure 10 yes Figure 1 A flowchart illustrating a specific implementation method for step S104. This embodiment can be achieved through, as shown below... Figure 10 The method shown implements step S104, and the specific implementation steps include steps S701 to S703:

[0094] Step S701: Obtain the maximum channel data of the gamma curve of the reference device.

[0095] The gamma curve debugging device obtains, for example, Figure 9 After obtaining the difference curves between the reference device and the test device, the difference curves can be linearly multiplied with the gamma curve of the reference device to obtain the gamma curve of the new test device. The calculation method is as follows: First, the gamma curve debugging device needs to obtain the maximum channel data of the gamma curve of the reference device.

[0096] Step S702: Perform a linear mapping on the channel data of the difference curve according to the maximum channel data to unify the maximum channel data of the difference curve and the gamma curve of the reference device.

[0097] The gamma curve debugging device then performs a linear mapping on the channel data of the difference curve according to the maximum channel data, so as to unify the maximum channel data of the difference curve and the gamma curve of the reference device.

[0098] Step S703: Under the same channel data, use the average difference data of the difference curve to perform a linear multiplication compensation operation on the brightness value of the gamma curve of the reference device to obtain the brightness value of the gamma curve of the test device under the channel data.

[0099] The gamma curve adjustment device ultimately compensates for the brightness value of the reference device's gamma curve by linearly multiplying the average difference data of the difference curve under the same channel data, thereby obtaining the brightness value of the test device's gamma curve under that channel data.

[0100] In this embodiment, the gamma curve adjustment device performs a linear mapping between the abscissa of the gamma curve of the reference device and the abscissa of the difference curve, and performs a corresponding mapping with the maximum value to unify the abscissa. Then, it uses the average value of the difference data of the difference curve to perform a linear multiplication compensation operation on the brightness value of the gamma curve of the reference device to obtain the brightness value of the gamma curve of the test device under the channel data, and finally obtains the gamma curve of the test device.

[0101] Unlike existing technologies, the gamma curve debugging method of this application first acquires first image data of a reference device and second image data of a test device under the same environment; then, it calculates the data difference between the first and second image data, and uses the data difference and the first image data of the reference device to obtain the difference curve between the reference device and the test device; finally, it determines the gamma curve of the test device based on the difference curve and the gamma curve of the reference device. The gamma curve debugging method of this application can automatically calibrate the gamma curve of the test device during the development of multi-series devices, and can eliminate the problem of differences between different devices, thereby effectively improving the brightness consistency of the test device image within the dynamic range.

[0102] Optionally, this application further proposes a gamma curve debugging device, please refer to [link to relevant documentation]. Figure 11 , Figure 11 This is a schematic diagram of an embodiment of the gamma curve debugging device provided in this application. The gamma curve debugging device 200 includes a processor 201 and a memory 202 coupled to the processor 201.

[0103] Processor 201 can also be referred to as CPU (Central Processing Unit). Processor 201 may be an integrated circuit chip with signal processing capabilities. Processor 201 can also be a general-purpose processor, digital signal processor (DSP), application-specific integrated circuit (ASIC), field-programmable gate array (FPGA), or other programmable logic device, discrete gate or transistor logic device, or discrete hardware component. A general-purpose processor can be a microprocessor or any conventional processor.

[0104] The memory 202 is used to store the program data required for the processor 201 to run.

[0105] The processor 201 is also used to execute program data stored in the memory 202 to implement the above-mentioned gamma curve debugging method.

[0106] Optionally, this application further proposes a computer storage medium. See also... Figure 12 , Figure 12 This is a schematic diagram of the structure of an embodiment of the computer storage medium provided in this application.

[0107] The computer storage medium 300 in this embodiment stores program instructions 310, which are executed to implement the above-described gamma curve debugging method.

[0108] Specifically, program instructions 310 can be formed into a program file and stored in the aforementioned storage medium in the form of a software product, so that an electronic device (which may be a personal computer, server, or network device, etc.) or processor can execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks, or terminal devices such as computers, servers, mobile phones, and tablets.

[0109] In this embodiment, the computer storage medium 300 can be, but is not limited to, a USB flash drive, SD card, PD optical drive, portable hard drive, large-capacity floppy drive, flash memory, multimedia memory card, server, etc.

[0110] In one embodiment, a computer program product or computer program is provided, comprising computer instructions stored in a computer storage medium. A processor of an electronic device reads the computer instructions from the computer storage medium and executes the computer instructions, causing the electronic device to perform the steps described in the above method embodiments.

[0111] Furthermore, if the aforementioned functions are implemented as software functions and sold or used as independent products, they can be stored in a mobile terminal-readable storage medium. That is, this application also provides a storage device storing program data, which can be executed to implement the methods of the above embodiments. This storage device can be, for example, a USB flash drive, an optical disc, or a server. In other words, this application can be embodied in the form of a software product, which includes several instructions to cause a smart terminal to execute all or part of the steps of the methods described in the various embodiments.

[0112] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this application, "multiple" means at least two, such as two, three, etc., unless otherwise explicitly specified.

[0113] Any process or method description in the flowchart or otherwise herein can be understood as representing an apparatus, segment, or portion of code comprising one or more executable instructions for implementing a particular logical function or process, and the scope of the preferred embodiments of this application includes additional implementations in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order according to the functions involved, as should be understood by those skilled in the art to which embodiments of this application pertain.

[0114] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a ordered list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (which may be a personal computer, server, network device, or other system that can fetch and execute instructions from, an instruction execution system, apparatus, or device). For the purposes of this specification, "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transmit programs for use by, or in conjunction with, an instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of computer-readable media include: an electrical connection having one or more wires (electronic device), a portable computer disk drive (magnetic device), random access memory (RAM), read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disc read-only memory (CDROM). Alternatively, the computer-readable medium may be paper or other suitable media on which the program can be printed, since the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in a computer memory.

[0115] The above description is merely an embodiment of this application and does not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. A gamma curve tuning method, characterized in that, The gamma curve debugging method includes: Under the same environment, the first image data of the reference device and the second image data of the test device were acquired respectively. Obtain the data difference between the first image data and the second image data; Using the data difference and the first image data of the reference device, a difference curve between the reference device and the test device is obtained; The gamma curve of the test device is determined based on the difference curve and the gamma curve of the reference device. The step of obtaining the data difference between the first image data and the second image data includes: obtaining the first channel data, the second channel data, and the third channel data of the first image data; obtaining the first channel data, the second channel data, and the third channel data of the second image data; obtaining the first channel data difference between the first channel data of the first image data and the first channel data of the second image data; obtaining the second channel data difference between the second channel data of the first image data and the second channel data of the second image data; and obtaining the third channel data difference between the third channel data of the first image data and the third channel data of the second image data. The step of obtaining a difference curve between the reference device and the test device using the data difference and the first image data of the reference device includes: obtaining first channel difference data using the first channel data difference and the first channel data of the first image data; obtaining second channel difference data using the second channel data difference and the second channel data of the first image data; obtaining third channel difference data using the third channel data difference and the third channel data of the first image data; converting the first channel difference data, the second channel difference data, and the third channel difference data into a two-dimensional dataset; and generating a difference curve between the reference device and the test device based on the two-dimensional dataset. The two-dimensional dataset includes channel data and difference data; generating the difference curve between the reference device and the test device based on the two-dimensional dataset includes: using the channel data in the two-dimensional dataset as the horizontal axis and the difference data as the vertical axis, fitting and generating a mapped two-dimensional graph; obtaining the average value of several difference data corresponding to each channel data; and fitting and generating the difference curve between the reference device and the test device according to each channel data and its corresponding average difference data. The step of determining the gamma curve of the test device based on the difference curve and the gamma curve of the reference device includes: obtaining the maximum channel data of the gamma curve of the reference device; performing a linear mapping on the channel data of the difference curve according to the maximum channel data to unify the maximum channel data of the difference curve and the gamma curve of the reference device; and, under the same channel data, performing a linear multiplication compensation operation on the brightness value of the gamma curve of the reference device using the average difference data of the difference curve to obtain the brightness value of the gamma curve of the test device under the channel data.

2. The gamma curve debugging method according to claim 1, characterized in that, The gamma curve debugging method also includes: Obtain the average brightness based on the initial image data; The light intake of the reference device and the test device is set according to the average brightness.

3. The gamma curve debugging method according to claim 1 or 2, characterized in that, The step of acquiring first image data from a reference device and second image data from a test device under the same environment includes: Under the same environment, the third image data of the reference device and the fourth image data of the test device were acquired respectively. The third image data of the reference device is converted into the first image data; The fourth image data from the test device is converted into the second image data; The first and second image data are of RGB data type, while the third and fourth image data are of RAW data type.

4. A gamma curve adjustment device, characterized in that, The gamma curve debugging device includes a memory and a processor coupled to the memory; The memory is used to store program data, and the processor is used to execute the program data to implement the gamma curve debugging method as described in any one of claims 1 to 3.

5. A computer storage medium, characterized in that, The computer storage medium is used to store program data, which, when executed by the computer, is used to implement the gamma curve debugging method as described in any one of claims 1 to 3.

Citation Information

Patent Citations

  • Project system and gamma curve correction method

    US20220150455A1