Gamma correction method, device, driver chip, display component and storage medium

By storing the M-order correction difference value in the correction difference value group, the problem of excessive resource occupation in the prior art is solved, and the effect of reducing resource occupation is achieved.

CN113936581BActive Publication Date: 2025-08-29SHENZHEN CRAFTSMAN TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202111205867.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-10-15
Publication Date
2025-08-29
Estimated Expiration
2041-10-15

AI Technical Summary

Technical Problem

The prior art occupies a lot of resources by storing the final correction value corresponding to each original value.

Method used

By storing the correction difference value group, the M-order correction difference value in the correction difference value group is calculated by calculating the difference value value value value, thereby reducing resource consumption.

Benefits of technology

Reduces resource usage of gamma correction and reduces storage space.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113936581B_ABST
    Figure CN113936581B_ABST
Patent Text Reader

Abstract

The present application relates to a gamma correction method, device, driver chip, display component, and storage medium. The method includes: in response to a gamma correction instruction, obtaining a first original value to be corrected; searching a pre-stored correction difference value group, wherein the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, and the M-th order correction difference value is obtained by calculating the difference between gamma correction values, where M is a natural number greater than 1; performing gamma correction based on the correction difference value group to obtain a first gamma correction value corresponding to the first original value. The gamma correction method, device, driver chip, display component, and storage medium can reduce the resources occupied by gamma correction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of display technology, and in particular to a gamma correction method, device, driver chip, display component and storage medium. Background Art

[0002] Gamma correction refers to a method that corrects raw values ​​to match the human eye's optimal light sensitivity range. This method uses an algorithm to correct the raw values ​​to obtain a final corrected value. However, this algorithm is computationally intensive. Therefore, some related technologies store the final corrected value corresponding to each raw value, allowing for direct lookup of the corresponding final corrected value.

[0003] However, storing the final correction value corresponding to each original value takes up a lot of resources. Summary of the Invention

[0004] Embodiments of the present application provide a gamma correction method, device, driver chip, display component, and storage medium, which can reduce the resources occupied by gamma correction.

[0005] A gamma correction method, comprising:

[0006] In response to a gamma correction instruction, obtaining a first original value to be corrected;

[0007] Searching for a pre-stored correction difference value group, the correction difference value group including M-th order correction difference values ​​corresponding to different original values, the M-th order correction difference value being obtained by calculating the difference between gamma correction values, where M is a natural number greater than 1;

[0008] Gamma correction is performed according to the correction difference value group to obtain a first gamma correction value corresponding to the first original value.

[0009] In one embodiment, performing gamma correction according to the correction difference value group to obtain a first gamma-corrected value corresponding to the first original value includes:

[0010] Obtaining at least one M-th order correction difference value associated with the first original value from the correction difference value group;

[0011] Gamma correction is performed according to at least one Mth-order correction difference value associated with the first original value to obtain a first gamma-corrected value corresponding to the first original value.

[0012] In one embodiment, obtaining at least one M-th order correction difference value associated with the first original value from the correction difference value group includes:

[0013] determining a second original value that is less than or equal to the first original value;

[0014] Identifying, from the correction difference value group, M-th order correction difference values ​​corresponding to all the second original values;

[0015] using the M-th order correction difference values ​​corresponding to all the second original values ​​as the M-th order correction difference values ​​associated with the first original value;

[0016] The performing gamma correction according to at least one M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value includes:

[0017] Performing an M-th order accumulation on at least one M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

[0018] In one embodiment, obtaining at least one M-th order correction difference value associated with the first original value from the correction difference value group includes:

[0019] Obtaining historical gamma correction values ​​and determining historical original values ​​corresponding to the historical gamma correction values;

[0020] determining a third original value that is less than or equal to a target original value, the target original value being the larger of the historical original value and the first original value;

[0021] Obtaining an M-th order correction difference value corresponding to each third original value from the correction difference value group;

[0022] Using the M-th order correction difference value corresponding to each third original value as the M-th order correction difference value associated with the first original value;

[0023] The performing gamma correction according to at least one M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value includes:

[0024] The historical gamma correction value is used as an initial correction value, and an M-th order correction difference value associated with the first original value is accumulated or subtracted in an M-th order to obtain a first gamma correction value corresponding to the first original value.

[0025] In one embodiment, when M=1, obtaining at least one M-th order correction difference value associated with the first original value from the correction difference value group includes:

[0026] Obtaining historical gamma correction values ​​and determining historical original values ​​corresponding to the historical gamma correction values;

[0027] determining a fourth original value between the historical original value and the first original value;

[0028] Obtaining an M-th order correction difference value corresponding to each fourth original value from the correction difference value group;

[0029] Using the M-th order correction difference value corresponding to each fourth original value as the M-th order correction difference value associated with the first original value;

[0030] The performing gamma correction according to at least one M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value includes:

[0031] The historical gamma correction value is used as an initial correction value, and the M-th order correction difference value associated with the first original value is accumulated or subtracted to obtain a first gamma correction value corresponding to the first original value.

[0032] In one embodiment, the method further comprises:

[0033] Determine the M-th order correction difference corresponding to different original values ​​according to any two adjacent gamma correction values;

[0034] The M-th order correction differences corresponding to different original values ​​are converted into integers and stored.

[0035] In one embodiment, searching for a pre-stored correction difference value set includes:

[0036] Get the gamma correction coefficient;

[0037] Find the correction difference value group corresponding to the gamma correction coefficient.

[0038] In one embodiment, the difference between the average value of the M-th order correction differences corresponding to different original values ​​and the gamma correction coefficient is the smallest.

[0039] In one embodiment, the method further comprises:

[0040] Obtain N-order correction differences corresponding to different original values, M≤N;

[0041] Determine the difference between the average value of each order correction difference corresponding to different original values ​​and the gamma correction coefficient;

[0042] The M-th order correction difference having the smallest difference between the average value and the gamma correction coefficient is stored.

[0043] A gamma correction device, comprising:

[0044] an acquisition module, configured to acquire a first original value to be corrected in response to a gamma correction instruction;

[0045] a search module, configured to search a pre-stored correction difference value group, wherein the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, wherein the M-th order correction difference value is obtained by calculating the difference between gamma correction values, where M is a natural number greater than 1;

[0046] A correction module is configured to perform gamma correction according to the correction difference value group to obtain a first gamma correction value corresponding to the first original value.

[0047] A driver chip includes a memory and a processor. The memory stores a computer program. When the computer program is executed by the processor, the processor performs the steps of the above-mentioned gamma correction method.

[0048] A display component includes a light-emitting unit and a driving chip, wherein the driving chip is used to execute the steps of the above method.

[0049] A computer-readable storage medium stores a computer program, which implements the steps of the above method when executed by a processor.

[0050] The gamma correction method, device, driver chip, display component, and storage medium described above include: obtaining a first original value to be corrected in response to a gamma correction instruction; searching a pre-stored correction difference value group, wherein the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, the M-th order correction difference values ​​being obtained by calculating the difference between gamma correction values, where M is a natural number greater than 1; performing gamma correction according to the correction difference value group to obtain a first gamma correction value corresponding to the first original value. Since the present application stores the correction difference value group, and the M-th order correction difference value in the correction difference value group is obtained by calculating the difference between the gamma correction values, the stored value is smaller, and therefore the occupied storage space is smaller, thereby reducing the resources occupied by gamma correction. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0052] Figure 1One of the flowcharts of the gamma correction method provided in one embodiment;

[0053] Figure 2 A detailed flowchart of step 130 is provided for one embodiment;

[0054] Figure 3 A second flow chart of a gamma correction method provided in one embodiment;

[0055] Figure 4 A third flow chart of a gamma correction method provided in one embodiment;

[0056] Figure 5 A fourth flowchart of a gamma correction method provided in one embodiment;

[0057] Figure 6 A schematic diagram of the structure of a gamma correction device provided in one embodiment;

[0058] Figure 7 FIG. 1 is a schematic diagram of the internal structure of a driver chip in one embodiment. DETAILED DESCRIPTION

[0059] In order to make the purpose, technical solutions and advantages of this application more clearly understood, the present application is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.

[0060] It will be understood that the terms "first," "second," and the like used herein may be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, a first original value may be referred to as a second original value, and similarly, a second original value may be referred to as a first original value, without departing from the scope of this application. Both the first original value and the second original value are original values, but they are not the same original value.

[0061] refer to Figure 1 , Figure 1 One of the flow charts of the gamma correction method provided in one embodiment. In one embodiment, Figure 1 As shown, the gamma correction method includes steps 110 to 130.

[0062] Step 110: In response to the gamma correction instruction, obtain a first original value to be corrected.

[0063] The gamma correction instruction refers to an instruction that triggers gamma correction. The first original value refers to the original value to be corrected, which can be understood as the initial value. Specifically, the first original value is related to the bit data. For example, if the data to be corrected is 8-bit data, the first original value is any value between 0 and 255; if the data to be corrected is 16-bit data, the first original value is any value between 0 and 65535.

[0064] Step 120 : Searching for a pre-stored correction difference value group, wherein the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, and the M-th order correction difference value is obtained by calculating the difference between gamma correction values.

[0065] Among them, the correction difference value group refers to a pre-stored difference value group, which serves as a parameter for determining the final correction value. Specifically, the correction difference value group includes M-th order correction difference values ​​corresponding to different original values. The different original values ​​in this embodiment are related to bit data. For example, if the data to be corrected is 8-bit data, the different original values ​​are a set of multiple values ​​of 0-255. The M-th order correction difference values ​​corresponding to different original values ​​mean that each original value corresponds to an M-th order correction difference value. In this embodiment, M is a natural number greater than 1. Specifically, the order of the correction difference values ​​corresponding to different original values ​​is the same. For example, each original value corresponds to a 2nd order correction difference value. In this embodiment, the order refers to the order of the difference value. Optionally, when M≥2, the M-th order correction difference value is the difference between the M-1th order correction difference values; when M=1, the 1st order correction difference value is the difference between the gamma correction values. For example, when the order is 1, the first-order correction difference is the difference between two adjacent gamma correction values; when the order is 2, the second-order correction difference is the difference between two adjacent first-order correction differences; when the order is 3, the third-order correction difference is the difference between the second-order correction differences, and so on.

[0066] Step 130: Perform gamma correction according to the correction difference value group to obtain a first gamma correction value corresponding to the first original value.

[0067] The first gamma correction value refers to the final correction value after correction. In this step, gamma correction is performed according to the correction difference value group, thereby obtaining the first gamma correction value corresponding to the first original value.

[0068] For example, 16-bit data is obtained by performing gamma correction on 8-bit data, and the gamma correction coefficient is 2.2. As shown in Table 1, Table 1 provides the first-order correction difference value, the second-order correction difference value, the third-order correction difference value, and the first gamma correction value corresponding to some first original values ​​of the 8-bit data.

[0069] First original value First gamma correction value 1st order correction difference 2nd order correction difference 3rd order correction difference 0 0 0 0 0 1 0.33 0.33 0.33 0.33 2 1.53 1.2 0.86 0.53 3 3.73 2.2 1.01 0.14 4 7.02 3.29 1.09 0.09 5 11.48 4.45 1.16 0.07 6 17.14 5.66 1.21 0.05 7 24.06 6.92 1.26 0.05 8 32.28 8.22 1.3 0.04

[0070] Table 1

[0071] As can be seen from Table 1, the M-th order correction difference values ​​corresponding to different original values ​​are smaller than the gamma correction values ​​corresponding to different original values, so the storage space occupied is smaller, and the resources occupied are also smaller.

[0072] The technical solution of this embodiment stores a correction difference group, that is, stores the M-th order correction difference in the correction difference group, and the M-th order correction difference in the correction difference group is obtained by calculating the difference between the gamma correction values. Therefore, the stored value is smaller, and the occupied storage space is smaller, thereby reducing the resources occupied by gamma correction.

[0073] The following embodiment, based on any of the above embodiments, describes how to perform gamma correction according to the correction difference value group to obtain a first gamma correction value corresponding to the first original value.

[0074] refer to Figure 2 , Figure 2 A detailed flow chart of step 130 is provided for one embodiment. In one embodiment, as Figure 2 As shown, step 130, performing gamma correction according to the correction difference value group to obtain a first gamma correction value corresponding to the first original value, includes steps 210 to 220.

[0075] Step 210: Obtain at least one M-th order correction difference value associated with the first original value from the correction difference value group.

[0076] In this step, because the correction difference value group includes Mth-order correction difference values ​​corresponding to different original values, some Mth-order correction difference values ​​may be unrelated to the first gamma correction value to be determined. Therefore, it is necessary to obtain at least one Mth-order correction difference value associated with the first original value from the correction difference value group. It should be noted that the Mth-order correction difference value is related to the value of the first original value.

[0077] Step 220: Perform gamma correction according to at least one M-th order correction difference associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

[0078] In this step, gamma correction is performed according to at least one M-th order correction difference value associated with the first original value.

[0079] The technical solution of this embodiment obtains at least one M-th order correction difference associated with the first original value from the correction difference group, and performs gamma correction based on at least one M-th order correction difference associated with the first original value to obtain a first gamma correction value corresponding to the first original value. In this case, only the M-th order correction difference associated with the first original value needs to be obtained, and there is no need to obtain the M-th order correction parameters unrelated to the first original value, which can further reduce the resources occupied by gamma correction.

[0080] In one possible implementation, obtaining at least one M-th order correction difference associated with the first original value from the correction difference value group includes:

[0081] Determine a second original value that is less than or equal to the first original value; identify the Mth-order correction difference values ​​corresponding to all the second original values ​​from the correction difference value group; and use the Mth-order correction difference values ​​corresponding to all the second original values ​​as the Mth-order correction difference values ​​associated with the first original value.

[0082] In one possible implementation, performing gamma correction according to at least one M-th order correction difference value associated with the first original value to obtain a first gamma-corrected value corresponding to the first original value includes:

[0083] Performing an M-th order accumulation on at least one M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

[0084] refer to Figure 3 , Figure 3 The second flow chart of the gamma correction method provided in one embodiment is as follows. Figure 3 As shown, the gamma correction method of one embodiment includes steps 310 to 360 .

[0085] Step 310: In response to the gamma correction instruction, obtain a first original value to be corrected.

[0086] This step may refer to the description of any of the above embodiments, and will not be described in detail in this embodiment.

[0087] Step 320: Search for a pre-stored correction difference value group, where the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, and the M-th order correction difference value is obtained by calculating the difference between gamma correction values.

[0088] This step may refer to the description of any of the above embodiments, and will not be described in detail in this embodiment.

[0089] Step 330: Determine a second original value that is less than or equal to the first original value.

[0090] The second original value refers to one of different original values, such as one of 0-255. In this embodiment, the second original value is less than or equal to the first original value. For example, if the first original value is 2, the second original value includes 0, 1, and 2.

[0091] Step 340: Identify the M-th order correction difference values ​​corresponding to all the second original values ​​from the correction difference value group.

[0092] In this step, since the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, the M-th order correction difference values ​​corresponding to all second original values ​​can be identified from the correction difference value group. For example, if the second original values ​​include 0, 1, and 2, the M-th order correction difference value corresponding to the second original value 0, the M-th order correction difference value corresponding to the second original value 1, and the M-th order correction difference value corresponding to the second original value 2 can be identified from the correction difference value group.

[0093] It should be noted that when the original value is 0, the corresponding M-th order correction difference is 0.

[0094] Step 350: Use the M-th order correction difference values ​​corresponding to all the second original values ​​as the M-th order correction difference values ​​associated with the first original value.

[0095] In this step, the M-th order correction difference values ​​corresponding to all the second original values ​​are used as the M-th order correction difference values ​​associated with the first original value.

[0096] Step 360: Perform an M-th order accumulation on at least one M-th order correction difference associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

[0097] In this step, performing an M-order accumulation on at least one M-th order correction difference associated with the first original value is equivalent to performing an M-order accumulation on the M-th order correction differences corresponding to all second original values. It can be understood that since the M-th order correction difference is the difference between the M-1-th order correction differences, the M-order accumulation can be understood as a reverse accumulation process.

[0098] Specifically, no matter what the number M is, the first-order correction difference can always be determined based on the M-th-order correction difference. Since the first-order correction difference is the difference between the gamma correction values, the first gamma correction value can be determined.

[0099] Continuing with Table 1, for example, assuming the first original value is 2 and M is 2, then the second original values ​​include 0, 1, and 2. The second-order correction differences corresponding to all the second original values ​​are 0, 0.33, and 0.86, respectively. The M-order accumulation expression is: 0.33 + 0.33 + 0.86 = 1.53. Thus, the first gamma correction value corresponding to the first original value 2 is determined to be 1.53.

[0100] First original value First gamma correction value 1st order correction difference Second-order correction difference 3rd order correction difference 0 0 0 0 0 1 0.33 0.33 0.33 0.33 2 1.53 1.2 0.86 0.53 3 3.73 2.2 1.01 0.14 4 7.02 3.29 1.09 0.09 5 11.48 4.45 1.16 0.07 6 17.14 5.66 1.21 0.05 7 24.06 6.92 1.26 0.05 8 32.28 8.22 1.3 0.04

[0101] Table 1

[0102] In one possible implementation, obtaining at least one M-th order correction difference associated with the first original value from the correction difference value group includes:

[0103] Obtain historical gamma correction values ​​and determine historical original values ​​corresponding to the historical gamma correction values; determine a third original value that is less than or equal to a target original value, where the target original value is the larger of the historical original value and the first original value; obtain an M-th order correction difference corresponding to each third original value from the correction difference value group; and use the M-th order correction difference corresponding to each third original value as the M-th order correction difference associated with the first original value.

[0104] In one possible implementation, performing gamma correction according to at least one M-th order correction difference value associated with the first original value to obtain a first gamma-corrected value corresponding to the first original value includes:

[0105] The historical gamma correction value is used as an initial correction value, and an M-th order correction difference value associated with the first original value is accumulated or subtracted in an M-th order to obtain a first gamma correction value corresponding to the first original value.

[0106] refer to Figure 4 , Figure 4 The third flow chart of the gamma correction method provided in one embodiment. Figure 4 As shown, the gamma correction method of one embodiment includes steps 410 to 470 .

[0107] Step 410: In response to the gamma correction instruction, obtain a first original value to be corrected.

[0108] This step may refer to the description of any of the above embodiments, and will not be described in detail in this embodiment.

[0109] Step 420: Search for a pre-stored correction difference value group, where the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, and the M-th order correction difference value is obtained by calculating the difference between gamma correction values.

[0110] This step may refer to the description of any of the above embodiments, and will not be described in detail in this embodiment.

[0111] Step 430: Obtain historical gamma correction values, and determine historical original values ​​corresponding to the historical gamma correction values.

[0112] The historical gamma correction value refers to the gamma correction value determined before the current gamma correction. The historical original value refers to the original value corresponding to the historical gamma correction value. It is understood that the method for determining the historical gamma correction value can refer to the description of any of the above embodiments. For example, if the historical gamma correction value is 7.02, the corresponding historical original value is 4.

[0113] Step 440: Determine a third original value that is less than or equal to the target original value.

[0114] Among them, the target original value is the larger one of the historical original value and the first original value. Specifically, when the historical original value is greater than the first original value, the target original value is the historical original value; when the historical original value is less than the first original value, the target original value is the first original value. The third original value refers to an original value that is less than or equal to the target original value. Specifically, the third original value includes the target original value itself. For example, if the historical original value is 4 and the first original value is 2, then the third original value includes 0, 1, 2, 3 and 4; for another example, if the historical original value is 1 and the first original value is 2, then the third original value includes 0, 1 and 2.

[0115] Step 450: Obtain the Mth-order correction difference value corresponding to each third original value from the correction difference value group.

[0116] In this step, since the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, the M-th order correction difference value corresponding to each third original value can be obtained from the correction difference value group. For example, if the third original values ​​include 3 and 4, the M-th order correction difference value corresponding to the third original value 3 and the M-th order correction difference value corresponding to the third original value 4 are obtained from the correction difference value group.

[0117] Step 460: Use the M-th order correction difference value corresponding to each third original value as the M-th order correction difference value associated with the first original value.

[0118] In this step, the M-th order correction difference values ​​corresponding to the third original values ​​are used as the M-th order correction difference values ​​associated with the first original values.

[0119] Step 470: Using the historical gamma correction value as the initial correction value, perform M-th order accumulation or M-th order accumulation on the M-th order correction difference associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

[0120] In this step, performing M-order accumulation or M-order cumulative subtraction on the M-th order correction difference associated with the first original value is equivalent to performing M-order accumulation or cumulative subtraction on the M-th order correction difference corresponding to at least one third original value. Since the M-th order correction difference is the difference between the M-1-th order correction differences, using the historical gamma correction value as the initial correction value and performing M-order accumulation or M-order cumulative subtraction on the at least one M-th order correction difference corresponding to each of the third original values ​​can be understood as a reverse calculation process based on the historical gamma correction value.

[0121] It should be noted that if the historical original value is greater than the first original value, the historical gamma correction value is used as the initial correction value, and at least one M-th order correction difference associated with the first original value is subtracted in M ​​orders; if the historical original value is less than the first original value, the historical gamma correction value is used as the initial correction value, and at least one M-th order correction difference associated with the first original value is added in M ​​orders.

[0122] Specifically, no matter what the number M is, the first-order correction difference can always be determined based on the M-th-order correction difference. Since the first-order correction difference is the difference between the gamma correction values, the first gamma correction value can be determined.

[0123] Continuing to refer to Table 1, for example, assuming that the historical gamma correction value is 3.73, the corresponding historical original value is 3. Assuming that the first original value is 2 and M is 2, the third original values ​​are 0, 1, 2, and 3. The second-order correction differences corresponding to the third original values ​​are 0, 0.33, 0.86, and 1.01, respectively. The first gamma correction value = 3.73 - (0 + 0.33 + 0.86 + 1.01) = 1.53.

[0124] Continuing to refer to Table 1, for example, assuming that the historical gamma correction value is 0.33, the corresponding historical original value is 1. Assuming that the first original value is 2 and M is 2, the third original value is 0, 1, and 2. The second-order correction difference values ​​corresponding to the third original value are 0, 0.33, and 0.86, respectively. Therefore, the first gamma correction value = 0.33 + (0.33 + 0.86) = 1.53.

[0125] First original value First gamma correction value 1st-order correction difference 2nd order correction difference 3rd order correction difference 0 0 0 0 0 1 0.33 0.33 0.33 0.33 2 1.53 1.2 0.86 0.53 3 3.73 2.2 1.01 0.14 4 7.02 3.29 1.09 0.09 5 11.48 4.45 1.16 0.07 6 17.14 5.66 1.21 0.05 7 24.06 6.92 1.26 0.05 8 32.28 8.22 1.3 0.04

[0126] Table 1

[0127] In a possible implementation, when M=1, obtaining at least one M-th order correction difference associated with the first original value from the correction difference value group includes:

[0128] Obtain a historical gamma correction value and determine a historical original value corresponding to the historical gamma correction value; determine a fourth original value between the historical original value and the first original value; obtain an M-th order correction difference corresponding to each fourth original value from the correction difference value group; and use the M-th order correction difference corresponding to each fourth original value as the M-th order correction difference associated with the first original value.

[0129] In one possible implementation, performing gamma correction according to at least one M-th order correction difference value associated with the first original value to obtain a first gamma-corrected value corresponding to the first original value includes:

[0130] The historical gamma correction value is used as an initial correction value, and the M-th order correction difference value associated with the first original value is accumulated or subtracted to obtain a first gamma correction value corresponding to the first original value.

[0131] refer to Figure 5 , Figure 5 This is a fourth flow chart of a gamma correction method provided in an embodiment. Figure 5 As shown, the gamma correction method includes steps 510 to 570.

[0132] Step 510: In response to the gamma correction instruction, obtain a first original value to be corrected.

[0133] This step may refer to the description of any of the above embodiments, and will not be described in detail in this embodiment.

[0134] Step 520: Search for a pre-stored correction difference value group, where the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, and the M-th order correction difference value is obtained by calculating the difference between gamma correction values.

[0135] This step may refer to the description of any of the above embodiments, and will not be described in detail in this embodiment.

[0136] Step 530: Obtain historical gamma correction values, and determine historical original values ​​corresponding to the historical gamma correction values.

[0137] This step may refer to the description of any of the above embodiments, and will not be described in detail in this embodiment.

[0138] Step 540: Determine a fourth original value between the historical original value and the first original value.

[0139] The fourth original value refers to the original value between the historical original value and the first original value. Specifically, the fourth original value includes the larger of the historical original value and the first original value, but excludes the smaller one. For example, if the historical original value is 4 and the first original value is 2, then the fourth original value includes 3 and 4. For another example, if the historical original value is 1 and the first original value is 2, then the fourth original value includes 2.

[0140] Step 550: Obtain the Mth-order correction difference value corresponding to each fourth original value from the correction difference value group.

[0141] Step 560: Use the M-th order correction difference value corresponding to each fourth original value as the M-th order correction difference value associated with the first original value.

[0142] Step 570: Using the historical gamma correction value as an initial correction value, cumulatively add or subtract the M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

[0143] In this step, it is equivalent to taking the historical gamma correction value as the initial correction value, and accumulating or subtracting the M-th order correction difference corresponding to each fourth original value, so as to obtain the first gamma correction value corresponding to the first original value.

[0144] In this embodiment, since only the M-th order gamma correction difference corresponding to the fourth original value between the historical original value and the first original value needs to be obtained, the amount of calculation can be further reduced.

[0145] It should be noted that the calculation result between the gamma correction values ​​can be directly used as the M-th order correction difference value, or the calculation result between the gamma correction values ​​can be converted into an integer and the converted integer value is used as the M-th order correction difference value, thereby calculating the first gamma correction value.

[0146] As can be seen from Table 1, if the result of the calculation between the gamma correction values ​​is directly used as the Mth-order correction difference, a decimal point will be present. Consequently, a large number of floating-point operations will inevitably occur when calculating the first gamma correction value, resulting in an increased computational load. Furthermore, in actual operations, only an estimate of the first gamma correction value, i.e., an integer value, is required, without excessive precision. Therefore, to reduce the computational load, in one embodiment, the Mth-order gamma correction value is obtained by converting the result of the calculation between the gamma correction values ​​into an integer.

[0147] In one embodiment, before step 130, searching for a pre-stored correction difference value set, the following steps are included:

[0148] Determine the M-th order correction difference corresponding to different original values ​​according to any two adjacent gamma correction values;

[0149] The M-th order correction differences corresponding to different original values ​​are converted into integers and stored.

[0150] In this embodiment, the M-th order correction differences corresponding to different original values ​​are determined according to any two adjacent gamma correction values, and the M-th order correction differences corresponding to different original values ​​are converted into integers and then stored.

[0151] Alternatively, the conversion may be performed from the first M-th order correction difference value to the last one, thereby obtaining a set of M-th order correction differences that are all integers. It should be noted that the conversion process needs to ensure that the result of the M-th order accumulation can accurately obtain the first gamma correction value.

[0152] For example, 16-bit data is obtained by performing gamma correction on 8-bit data, and a gamma correction coefficient of 2.2 is used as an example. As shown in Table 2, Table 2 provides the second-order correction difference value, the rounded second-order correction difference value, the first gamma correction value, and the actual gamma correction value corresponding to some first original values ​​of the 8-bit data.

[0153] The actual gamma correction value is calculated using the algorithm: Y = (X / 255)2.2*65535. Y is the actual gamma correction value, and X is the original value to be corrected. 255 is the maximum value for 8 bits, 2.2 is the gamma correction coefficient, and 65535 is the maximum value for 16 bits. This formula converts 8-bit data with a maximum value of 255 into 16-bit data with a gamma coefficient of 2.2. The second-order correction difference is the correction difference determined based on the two gamma correction values, unconverted to an integer. The converted second-order correction difference is the result obtained by converting the second-order correction parameter to an integer. The first gamma correction value is the final gamma correction value to be determined.

[0154] According to the data in Table 2 and by using the gamma correction method of any of the above embodiments, if the first original value is 2, then the first gamma correction value can be determined to be 0+1+1=2. If the first original value is 3, then the first gamma correction value can be determined to be 0+1+1+2=4.

[0155]

[0156] Table 2

[0157] It can be understood that by converting the M-th order correction difference into an integer and then storing it, floating-point operations are not required, which reduces the amount of operations and is equivalent to further reducing the resources for gamma correction.

[0158] In some examples, the gamma correction coefficient is not fixed but needs to be changed according to actual conditions. Therefore, the following embodiments are adapted to scenarios with different gamma correction coefficients based on any of the above embodiments.

[0159] In one embodiment, searching for a pre-stored correction difference value set includes:

[0160] Get the gamma correction coefficient;

[0161] Find the correction difference value group corresponding to the gamma correction coefficient.

[0162] In this embodiment, correction difference value groups corresponding to different gamma correction coefficients are pre-stored, and the correction difference value groups corresponding to the gamma correction coefficients can be searched as needed, thereby adapting to scenes with different gamma correction coefficients and improving the applicability of gamma correction.

[0163] In one embodiment, the difference between the average value of the M-th order correction differences corresponding to different original values ​​and the gamma correction coefficient is the smallest.

[0164] Specifically, research has found that when the difference between the average of the Mth-order correction differences corresponding to different original values ​​and the gamma correction coefficient is minimized, the minimum resources are used and the gamma correction value can be accurately calculated. Generally, the average of the Mth-order correction differences is the same as the gamma correction coefficient. For example, if the gamma correction coefficient is 2.2, the average of the Mth-order correction differences is 2.2.

[0165] In one embodiment, before step 120, searching for a pre-stored correction difference value set, the following steps are included:

[0166] Obtain N-order correction differences corresponding to different original values, M≤N;

[0167] Determine the difference between the average value of each order correction difference corresponding to different original values ​​and the gamma correction coefficient;

[0168] The M-th order correction difference having the smallest difference between the average value and the gamma correction coefficient is stored.

[0169] In this embodiment, the average value of each correction difference in N orders is obtained and compared with the gamma correction coefficient, and the Mth order correction difference with the smallest difference is stored as a group of correction difference values ​​for retrieval when needed.

[0170] For example, assuming N=3, the first-order correction difference, second-order correction difference, and third-order correction difference corresponding to different original values ​​are obtained. The first-order correction difference corresponding to different original values ​​is calculated and compared with the gamma coefficient; the second-order correction difference corresponding to different original values ​​is calculated and compared with the gamma coefficient; and the third-order correction difference corresponding to different original values ​​is calculated and compared with the gamma coefficient. If the difference between the second-order correction difference corresponding to different original values ​​and the gamma coefficient is the smallest, then M=2.

[0171] It should be understood that although Figure 1-5 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. In addition, Figure 1-5 At least part of the steps may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least part of the sub-steps or stages of other steps.

[0172] Refer to him 6, Figure 6 This is a schematic diagram of the structure of a gamma correction device provided by an embodiment. Figure 6 As shown, the gamma correction device includes an acquisition module 610, a search module 620 and a correction module 630, wherein:

[0173] The acquisition module 610 is used to respond to a gamma correction instruction to obtain a first original value to be corrected; the search module 620 is used to search a pre-stored correction difference value group, wherein the correction difference value group includes M-th order correction difference values ​​corresponding to different original values, and the M-th order correction difference value is obtained by calculating the difference between gamma correction values, where M is a natural number greater than 1; the correction module 630 is used to perform gamma correction based on the correction difference value group to obtain a first gamma correction value corresponding to the first original value.

[0174] In one embodiment, the correction module 630 includes: an acquisition unit for acquiring at least one M-th order correction difference associated with the first original value from the correction difference group; a correction unit for performing gamma correction based on at least one M-th order correction difference associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

[0175] In one embodiment, the acquisition unit includes: a first acquisition unit, used to determine a second original value that is less than or equal to the first original value; identifying the Mth-order correction difference values ​​corresponding to all the second original values ​​from the correction difference group; and using the Mth-order correction difference values ​​corresponding to all the second original values ​​as the Mth-order correction difference values ​​associated with the first original value.

[0176] In one embodiment, the correction unit includes: a first correction unit, configured to perform an M-th order accumulation on at least one M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

[0177] In one embodiment, the acquisition unit includes: a second acquisition unit, used to acquire a historical gamma correction value and determine a historical original value corresponding to the historical gamma correction value; determine a third original value that is less than or equal to a target original value, where the target original value is the larger of the historical original value and the first original value; acquire an Mth-order correction difference corresponding to each third original value from the correction difference group; and use the Mth-order correction difference corresponding to each third original value as the Mth-order correction difference associated with the first original value.

[0178] In one embodiment, the correction unit includes: a second correction unit, configured to use the historical gamma correction value as an initial correction value, perform M-order accumulation or M-order subtraction on the M-th order correction difference associated with the first original value, and obtain a first gamma correction value corresponding to the first original value.

[0179] In one embodiment, the acquisition unit includes: a third acquisition unit, used to acquire a historical gamma correction value and determine a historical original value corresponding to the historical gamma correction value; determine a fourth original value between the historical original value and the first original value; acquire an M-th order correction difference corresponding to each fourth original value from the correction difference group; and use the M-th order correction difference corresponding to each fourth original value as the M-th order correction difference associated with the first original value.

[0180] In one embodiment, the correction unit includes: a third correction unit, configured to use the historical gamma correction value as an initial correction value, accumulate or subtract the Mth-order correction difference associated with the first original value, and obtain a first gamma correction value corresponding to the first original value.

[0181] In one embodiment, the device further includes: a storage module for determining the Mth order correction difference values ​​corresponding to different original values ​​according to any two adjacent gamma correction values; and converting the Mth order correction difference values ​​corresponding to different original values ​​into integers and storing them.

[0182] In one embodiment, the search module 620 is specifically configured to obtain a gamma correction coefficient and search for a correction difference value group corresponding to the gamma correction coefficient.

[0183] In one embodiment, the difference between the average value of the M-th order correction differences corresponding to different original values ​​and the gamma correction coefficient is the smallest.

[0184] In one embodiment, the storage module is also used to obtain N-order correction differences corresponding to different original values, M≤N; determine the average value of each order correction difference corresponding to different original values, and the difference between the average value and the gamma correction coefficient; and store the M-th order correction difference with the smallest difference between the average value and the gamma correction coefficient.

[0185] The division of the various modules in the above gamma correction device is only for illustration. In other embodiments, the XXX device may be divided into different modules as needed to complete all or part of the functions of the above gamma correction device.

[0186] The specific definition of the gamma correction device can be found in the definition of the gamma correction method above and will not be repeated here. Each module in the aforementioned gamma correction device can be implemented in whole or in part via software, hardware, or a combination thereof. Each of these modules can be embedded in or independent of a processor in a computer device in hardware form, or stored in a computer device memory in software form, so that the processor can call and execute the corresponding operations of each module.

[0187] Figure 7 FIG. 1 is a schematic diagram of the internal structure of a driver chip in one embodiment. Figure 7As shown, the driver chip includes a processor and a memory connected via a system bus. The processor is used to provide computing and control capabilities to support the operation of the entire driver chip. The memory may include a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The computer program can be executed by the processor to implement a gamma correction method provided in the following embodiments. The internal memory provides a high-speed cache operating environment for the operating system computer program in the non-volatile storage medium. The driver chip can be used in any terminal device with a display component, such as a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a POS (Point of Sales), an on-board computer, a wearable device, etc.

[0188] The various modules in the gamma correction device provided in the embodiments of the present application may be implemented in the form of a computer program. This computer program may be executed on a terminal or server. The program modules comprising this computer program may be stored in the memory of a driver chip. When executed by a processor, this computer program implements the steps of the method described in the embodiments of the present application.

[0189] The present application also provides a computer-readable storage medium, one or more non-volatile computer-readable storage media containing computer-executable instructions, which, when executed by one or more processors, cause the processors to perform the steps of the gamma correction method.

[0190] A computer program product comprising instructions, when executed on a computer, causes the computer to perform a gamma correction method.

[0191] In one embodiment, a display assembly is further provided, comprising a light-emitting unit and a driver chip. The light-emitting unit is configured to emit light under the drive of the driver chip. The driver chip can be described in any of the above embodiments and is not further described in this embodiment.

[0192] As used herein, any reference to memory, storage, database, or other medium may include nonvolatile and / or volatile memory. Nonvolatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM), which serves as an external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and RAMbus dynamic RAM (RDRAM).

[0193] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present invention. It should be noted that a person of ordinary skill in the art may make various modifications and improvements without departing from the spirit of the present invention, all of which fall within the scope of protection of the present invention. Therefore, the scope of protection of the present invention shall be determined by the appended claims.

Claims

1. A gamma correction method, characterized in that: The method comprises: In response to a gamma correction instruction, obtaining a first original value to be corrected; Searching for a pre-stored correction difference group: obtaining a gamma correction coefficient; searching for a correction difference group corresponding to the gamma correction coefficient, the correction difference group including M-th order correction differences corresponding to different original values, the K-th order correction difference corresponding to any original value being obtained by calculating the difference between the K-1-th order correction difference corresponding to any original value and the K-1-th order correction difference corresponding to an adjacent original value of the any original value, the 1-th order correction difference corresponding to any original value being obtained by calculating the difference between the gamma correction value corresponding to any original value and the gamma correction value corresponding to the adjacent original value of the any original value, M being a natural number greater than 2, 1<K≤M, and K being an integer, the M-th order correction difference being obtained by: obtaining N-th order correction differences corresponding to different original values, M≤N; respectively determining the average value of each order correction difference corresponding to different original values ​​and the difference between the average value and the gamma correction coefficient; and storing the M-th order correction difference having the smallest difference between the average value and the gamma correction coefficient as a group of correction difference groups; Gamma correction is performed according to the correction difference value group to obtain a first gamma correction value corresponding to the first original value.

2. The gamma correction method according to claim 1, wherein: The performing gamma correction according to the correction difference value group to obtain a first gamma-corrected value corresponding to the first original value includes: Obtaining at least one M-th order correction difference value associated with the first original value from the correction difference value group; Gamma correction is performed according to at least one Mth-order correction difference value associated with the first original value to obtain a first gamma-corrected value corresponding to the first original value.

3. The gamma correction method according to claim 2, wherein: The obtaining, from the correction difference value group, at least one M-th order correction difference value associated with the first original value includes: determining a second original value that is less than or equal to the first original value; Identifying, from the correction difference value group, M-th order correction difference values ​​corresponding to all the second original values; using the M-th order correction difference values ​​corresponding to all the second original values ​​as the M-th order correction difference values ​​associated with the first original value; The performing gamma correction according to at least one M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value includes: Performing an M-th order accumulation on at least one M-th order correction difference value associated with the first original value to obtain a first gamma correction value corresponding to the first original value.

4. The gamma correction method according to claim 2, wherein: The obtaining, from the correction difference value group, at least one M-th order correction difference value associated with the first original value includes: Obtaining historical gamma correction values ​​and determining historical original values ​​corresponding to the historical gamma correction values; determining a third original value that is less than or equal to a target original value, the target original value being the larger of the historical original value and the first original value; Obtaining an M-th order correction difference value corresponding to each third original value from the correction difference value group; Using the M-th order correction difference value corresponding to each third original value as the M-th order correction difference value associated with the first original value; The historical gamma correction value is used as an initial correction value, and an M-th order correction difference value associated with the first original value is accumulated or subtracted in an M-th order to obtain a first gamma correction value corresponding to the first original value.

5. The gamma correction method according to claim 1, wherein: The method further comprises: Determine the M-th order correction difference corresponding to different original values ​​according to any two adjacent gamma correction values; The M-th order correction difference values ​​corresponding to different original values ​​are converted into integers and stored; The M-th order correction difference having the smallest difference between the average value and the gamma correction coefficient is stored.

6. A gamma correction device, characterized in that: The device comprises: an acquisition module, configured to acquire a first original value to be corrected in response to a gamma correction instruction; A search module is configured to search for a pre-stored correction difference value group: obtain a gamma correction coefficient; search for a correction difference value group corresponding to the gamma correction coefficient, the correction difference value group including M-th order correction difference values ​​corresponding to different original values, the K-th order correction difference value corresponding to any original value being obtained by calculating the difference between the K-1-th order correction difference value corresponding to any original value and the K-1-th order correction difference value corresponding to an adjacent original value of the original value, the 1-th order correction difference value corresponding to any original value being obtained by calculating the difference between the gamma correction value corresponding to any original value and the gamma correction value corresponding to the adjacent original value, M being a natural number greater than 2, 1<K≤M, and K being an integer, the M-th order correction difference value being obtained by: obtaining N-th order correction difference values ​​corresponding to different original values, M≤N; respectively determining the average value of each order correction difference value corresponding to different original values ​​and the difference between the average value and the gamma correction coefficient; and storing the M-th order correction difference value having the smallest difference between the average value and the gamma correction coefficient as a group of correction difference values; A correction module is configured to perform gamma correction according to the correction difference value group to obtain a first gamma correction value corresponding to the first original value.

7. A driver chip comprising a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor performs the steps of the gamma correction method according to any one of claims 1 to 5.

8. A display component, characterized in that: The method comprises a light emitting unit and a driving chip, wherein the driving chip is used to execute the steps of the method according to any one of claims 1 to 5.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.

Citation Information

Patent Citations

  • An efficient method for gamma correction table update based on residual data

    EP2009905A2