Display data conversion method and device and storage medium
By adopting an interpolation method in the display technology field, the sampling points and their mapping relationship are determined based on the target electrical signal data, the problem of excessive hardware storage space occupied in the prior art is solved, and higher data conversion accuracy and better display effect are achieved.
Patent Information
- Application Number
- CN202510205745.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-24
- Publication Date
- 2025-03-28
AI Technical Summary
In the field of display technology, the prior art requires a large amount of hardware storage space in the mapping between electrical signals and optical signals, especially when multi-pixel parallel processing, resulting in a high hardware resource occupancy.
By determining the target sampling point adjacent to the target electrical signal data in the sample point and its corresponding electrical signal and optical signal, the target optical signal data is calculated by using the interpolation method to be used to reduce the occupation of hardware storage space, and the accuracy of interpolation calculation is improved through non-equal sampling points.
It realizes that while reducing the hardware storage space, it improves the accuracy of data conversion, achieves better display effects, and reduces the use of hardware resources.
Smart Images

Figure CN119724076A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of display technology, and in particular to a display data conversion method, device and storage medium. Background Art
[0002] In the field of display technology, the mapping between electrical signals and optical signals is one of the key links. Since the human eye has a wide range of perception of linear optical signals, the amount of data required to directly transmit linear optical signals is very large. Therefore, in order to optimize the transmission efficiency of image data, linear optical signals are usually first converted into nonlinear electrical signals for transmission, and then the nonlinear electrical signals are restored to linear optical signals for display in the display device.
[0003] In hardware design, the table lookup method is often used to achieve the conversion of electrical signal data to optical signal data. However, this method requires a lot of hardware storage space to save the mapping table, especially when multi-pixel parallel processing, a copy of the mapping table needs to be made for each processing unit, which further increases the storage requirements and occupies a high amount of hardware resources. Summary of the invention
[0004] In view of this, the present disclosure proposes a display data conversion method, device and storage medium.
[0005] According to one aspect of the present disclosure, a display data conversion method is provided. The method comprises:
[0006] Based on the target electrical signal data of the image to be displayed, determining the target sampling points adjacent to the target electrical signal data among the sampling points, and the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling points;
[0007] Based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling point, the target optical signal data corresponding to the target electrical signal data is interpolated and calculated, and the target optical signal data is used for display; the sampling point includes a plurality of non-equidistant sampling points.
[0008] In a possible implementation, the number of target sampling points is 2, and the interpolation includes linear interpolation.
[0009] In a possible implementation, the step length between sampling points in a low-gray interval is smaller than the step length between sampling points outside the low-gray interval, and the low-gray interval represents an interval in which the data value of the electrical signal is smaller than a preset threshold.
[0010] In a possible implementation manner, the sampling points include N sampling points, and the method further includes:
[0011] Determine N pre-sampling points in the original mapping table, the original mapping table includes mapping relationships between M pairs of electrical signal data and optical signal data, the N pre-sampling points respectively correspond to the mapping relationships between the N pairs of electrical signal data and optical signal data in the original mapping table, N and M are positive integers, and the value of M is greater than N;
[0012] Randomly generate sampling points between two adjacent pre-sampling points, and determine N randomly generated sampling points;
[0013] Based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the N randomly generated sampling points, interpolation is performed to calculate the interpolated optical signal data corresponding to the M electrical signal data respectively;
[0014] The N randomly generated sampling points are adjusted based on the interpolated optical signal data to determine the N sampling points.
[0015] In a possible implementation, sampling points are randomly generated between two adjacent pre-sampling points, and N randomly generated sampling points are determined, including:
[0016] Based on a random generation function, sampling points are respectively generated between two adjacent pre-sampling points to determine N randomly generated sampling points, wherein the random generation function is multiplied by a preset coefficient less than 1.
[0017] In a possible implementation, the position of the first sampling point among the N sampling points is fixed to correspond to 0, the position of the last sampling point among the N sampling points is fixed to correspond to the maximum value of the electrical signal data, and the N pre-sampling points determined for the first time are pre-sampling points with equal spacing.
[0018] In a possible implementation, adjusting N randomly generated sampling points based on the interpolated optical signal data to determine the N sampling points includes:
[0019] Calculating the error between the interpolated optical signal data and the corresponding optical signal data in the original mapping table;
[0020] The N randomly generated sampling points are adjusted based on the error to determine the N sampling points.
[0021] In a possible implementation, adjusting N randomly generated sampling points based on the error to determine the N sampling points includes:
[0022] In response to the sum of errors corresponding to the M optical signal data being greater than an error threshold, taking the current N randomly generated sampling points as new N pre-sampling points, re-executing the steps of randomly generating sampling points between two adjacent pre-sampling points, determining the N randomly generated sampling points and subsequent steps;
[0023] In response to the sum of errors corresponding to the M optical signal data being no greater than an error threshold, the current N randomly generated sampling points are used as N sampling points.
[0024] According to another aspect of the present disclosure, a display data conversion device is provided. The device comprises:
[0025] A first determination module, configured to determine, based on the target electrical signal data of the image to be displayed, a target sampling point adjacent to the target electrical signal data among the sampling points, and a mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling point;
[0026] The first interpolation calculation module is used to interpolate and calculate target optical signal data corresponding to the target electrical signal data based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling point, and the target optical signal data is used for display; the sampling points include multiple non-equidistant sampling points.
[0027] In a possible implementation, the number of target sampling points is 2, and the interpolation includes linear interpolation.
[0028] In a possible implementation, the step length between sampling points in a low-gray interval is smaller than the step length between sampling points outside the low-gray interval, and the low-gray interval represents an interval in which the data value of the electrical signal is smaller than a preset threshold.
[0029] In a possible implementation manner, the sampling points include N sampling points, and the device further includes:
[0030] A second determination module is used to determine N pre-sampling points in an original mapping table, the original mapping table includes mapping relationships between M pairs of electrical signal data and optical signal data, the N pre-sampling points respectively correspond to the mapping relationships between the N pairs of electrical signal data and optical signal data in the original mapping table, N and M are positive integers, and the value of M is greater than N;
[0031] A third determination module is used to randomly generate sampling points between two adjacent pre-sampling points, and determine N randomly generated sampling points;
[0032] A second interpolation calculation module is used to interpolate and calculate the interpolated optical signal data corresponding to the M electrical signal data respectively based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the N randomly generated sampling points;
[0033] The adjustment module is used to adjust the N randomly generated sampling points based on the interpolated optical signal data to determine the N sampling points.
[0034] In a possible implementation manner, the third determining module is configured to:
[0035] Based on a random generation function, sampling points are respectively generated between two adjacent pre-sampling points to determine N randomly generated sampling points, wherein the random generation function is multiplied by a preset coefficient less than 1.
[0036] In a possible implementation, the position of the first sampling point among the N sampling points is fixed to correspond to 0, the position of the last sampling point among the N sampling points is fixed to correspond to the maximum value of the electrical signal data, and the N pre-sampling points determined for the first time are pre-sampling points with equal spacing.
[0037] In a possible implementation, the adjustment module is used to:
[0038] Calculating the error between the interpolated optical signal data and the corresponding optical signal data in the original mapping table;
[0039] The N randomly generated sampling points are adjusted based on the error to determine the N sampling points.
[0040] In a possible implementation, adjusting N randomly generated sampling points based on the error to determine the N sampling points includes:
[0041] In response to the sum of errors corresponding to the M optical signal data being greater than an error threshold, taking the current N randomly generated sampling points as new N pre-sampling points, re-executing the steps of randomly generating sampling points between two adjacent pre-sampling points, determining the N randomly generated sampling points and subsequent steps;
[0042] In response to the sum of errors corresponding to the M optical signal data being no greater than an error threshold, the current N randomly generated sampling points are used as N sampling points.
[0043] According to another aspect of the present disclosure, there is provided a ... device, comprising: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to implement the above method when executing the instructions stored in the memory.
[0044] According to another aspect of the present disclosure, a non-volatile computer-readable storage medium is provided, on which computer program instructions are stored, wherein the computer program instructions implement the above method when executed by a processor.
[0045] According to another aspect of the present disclosure, a computer program product is provided, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of an electronic device, the processor in the electronic device executes the above method.
[0046] According to an embodiment of the present disclosure, based on the target electrical signal data of the image to be displayed, the target sampling points adjacent to the target electrical signal data in the sampling points, and the mapping relationship between the electrical signal data corresponding to the target sampling points and the optical signal data are determined, and further based on the mapping relationship between the electrical signal data corresponding to the target sampling points and the optical signal data, the target optical signal data corresponding to the target electrical signal data is interpolated and calculated to obtain the target optical signal data for display, thereby realizing the conversion of electrical signals to optical signals using the interpolation method, reducing the occupation of hardware storage space, and by making the sampling points include multiple sampling points with non-equidistant intervals, the error of the interpolation calculation can be reduced, so that the accuracy of the interpolation calculation is higher, while reducing the occupation of hardware storage space, the accuracy of data conversion is guaranteed, so as to achieve a better display effect.
[0047] Further features and aspects of the present disclosure will become apparent from the following detailed description of exemplary embodiments with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate exemplary embodiments, features, and aspects of the disclosure and, together with the description, serve to explain the principles of the disclosure.
[0049] Figure 1 A schematic diagram showing an application scenario according to an embodiment of the present disclosure.
[0050] Figure 2 A flow chart of a display data conversion method according to an embodiment of the present disclosure is shown.
[0051] Figure 3 A schematic diagram showing an EOTF curve according to an embodiment of the present disclosure.
[0052] Figure 4 A flow chart of a display data conversion method according to an embodiment of the present disclosure is shown.
[0053] Figure 5 A schematic diagram showing a method of determining a pre-sampling point according to an embodiment of the present disclosure is shown.
[0054] Figure 6 A schematic diagram showing generation of sampling points according to an embodiment of the present disclosure is shown.
[0055] Figure 7 A schematic diagram showing interpolation calculation according to an embodiment of the present disclosure is shown.
[0056] Figure 8 A schematic diagram of determining sampling points according to an embodiment of the present disclosure is shown.
[0057] Fig. 9 A structural diagram of a display data conversion device according to an embodiment of the present disclosure is shown.
[0058] Fig.10 It is a block diagram of a device 1900 for display data conversion according to an exemplary embodiment. DETAILED DESCRIPTION
[0059] Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise specified.
[0060] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.
[0061] In addition, in order to better illustrate the present disclosure, numerous specific details are given in the following specific embodiments. It should be understood by those skilled in the art that the present disclosure can also be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the main purpose of the present disclosure.
[0062] In the field of display technology, the mapping between electrical signals and optical signals is one of the key links. Since the human eye has a wide range of perception of linear optical signals, the amount of data required to directly transmit linear optical signals is very large. Therefore, in order to optimize the transmission efficiency of image data, linear optical signals are usually first converted into nonlinear electrical signals for transmission, and then the nonlinear electrical signals are restored to linear optical signals in the display device for display. In hardware design, the table lookup method is often used to realize the conversion of electrical signal data to optical signal data. However, this method requires a large amount of hardware storage space to save the mapping table, especially when multi-pixel parallel processing, a copy of the mapping table needs to be copied for each processing unit, which further increases the storage requirements and occupies a high amount of hardware resources.
[0063] In view of this, the present disclosure provides a display data conversion method, device and storage medium. The method determines the target sampling points adjacent to the target electrical signal data in the sampling points based on the target electrical signal data of the image to be displayed, and the mapping relationship between the electrical signal data corresponding to the target sampling points and the optical signal data, and further interpolates and calculates the target optical signal data corresponding to the target electrical signal data based on the mapping relationship between the electrical signal data corresponding to the target sampling points and the optical signal data, so as to obtain the target optical signal data for display, thereby realizing the conversion of electrical signals to optical signals using the interpolation method, reducing the occupation of hardware storage space, and reducing the error of interpolation calculation by making the sampling points include multiple sampling points with non-equal spacing, so as to make the interpolation calculation more accurate, and ensure the accuracy of data conversion while reducing the occupation of hardware storage space, so as to achieve better display effect.
[0064] Figure 1 Schematic diagram showing an application scenario according to an embodiment of the present disclosure. The method of the embodiment of the present disclosure can be used in a scenario where display image data is transmitted. Figure 1 As shown, the optical signal data of the display image can be collected at the data collection end, converted into electrical signal data and then transmitted to the display device end; the display device end can use the method of the embodiment of the present disclosure to convert the received electrical signal data into optical signal data for display on the display device.
[0065] The data collection end and the display device end may be deployed on the same terminal device or on different terminal devices, and connected via wired or wireless means.
[0066] Figure 2 The flowchart of the display data conversion method according to the embodiment of the present disclosure is shown. The display data conversion method according to the embodiment of the present disclosure can be used for the above-mentioned display device end, such as Figure 2 As shown, the method includes:
[0067] Step S201 : based on the target electrical signal data of the image to be displayed, determining the target sampling points adjacent to the target electrical signal data among the sampling points, and the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling points.
[0068] The target electrical signal data may be electrical signal data transmitted after the original optical signal data is converted by the optical-electro transfer function (OETF) sent by the above-mentioned data acquisition end. For example, a target electrical signal data may correspond to a pixel of the image to be displayed, and the display device end may obtain the electrical signal data corresponding to one or more pixels sent by the data acquisition end each time, and use the electrical signal data corresponding to each pixel as the target electrical signal data, and use the method of the embodiment of the present disclosure to convert the target electrical signal data into the corresponding target optical signal data for each pixel.
[0069] The method of the embodiment of the present disclosure can restore the target electrical signal data to optical signal data on the display device side. In the process of converting the target electrical signal data to the corresponding target optical signal data, the corresponding electro-optical transfer function (EOTF) is usually used for conversion. Figure 3 Schematic diagram of an EOTF curve according to an embodiment of the present disclosure is shown. Figure 3 As shown, the horizontal axis can represent the electrical signal data value, and the vertical axis can represent the optical signal data value.
[0070] In hardware design, the EOTF curve is usually discretized into multiple points (for example, 1024 points), each of which corresponds to an optical signal data value, indicating a mapping relationship between a pair of electrical signal data and optical signal data, thereby obtaining an original mapping table, which is converted by looking up the table. However, when performing multi-pixel processing on the display device side, it is usually necessary to copy the original mapping table multiple times, which will result in a large storage space occupied by the hardware device.
[0071] The present disclosure uses an interpolation method to sample the original mapping table with multiple sampling points (for example, 33 sampling points), and obtains optical signal data of intermediate points (non-sampling points) through an interpolation process, thereby reducing the storage space of the hardware device.
[0072] The sampling point may be a portion of the electrical signal data in the original mapping table, and each sampling point may correspond to a mapping relationship between a pair of electrical signal data and optical signal data in the original mapping table. The number of target sampling points may be 2, and the target sampling points adjacent to the target electrical signal data may include two sampling points closest to the value of the target electrical signal data, such as a nearest sampling point before the target electrical signal data and a nearest sampling point after the target electrical signal data.
[0073] Step S202: interpolate and calculate target optical signal data corresponding to the target electrical signal data based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling point.
[0074] The target light signal data may be used for display, for example, on a display screen of a display device.
[0075] The above interpolation may include linear interpolation and nonlinear interpolation. In the embodiment of the present disclosure, in order to make the target optical signal data obtained by the interpolation calculation more accurate, that is, close to the original optical signal data at the data acquisition end, the sampling points may include a plurality of non-equidistant sampling points, wherein the spacing between adjacent sampling points may be partially different or completely different, and the embodiment of the present disclosure does not limit this.
[0076] Compared with the sampling points obtained by sampling at equal intervals, the target optical signal data obtained by the present disclosure has smaller errors than the corresponding optical signal data in the above-mentioned original mapping table.
[0077] According to an embodiment of the present disclosure, based on the target electrical signal data of the image to be displayed, the target sampling points adjacent to the target electrical signal data in the sampling points, and the mapping relationship between the electrical signal data corresponding to the target sampling points and the optical signal data are determined, and further based on the mapping relationship between the electrical signal data corresponding to the target sampling points and the optical signal data, the target optical signal data corresponding to the target electrical signal data is interpolated and calculated to obtain the target optical signal data for display, thereby realizing the conversion of electrical signals to optical signals using the interpolation method, reducing the occupation of hardware storage space, and by making the sampling points include multiple sampling points with non-equidistant intervals, the error of the interpolation calculation can be reduced, so that the accuracy of the interpolation calculation is higher, while reducing the occupation of hardware storage space, the accuracy of data conversion is guaranteed, so as to achieve a better display effect.
[0078] In the low gray interval of the above-mentioned EOTF curve (for example, for the High Dynamic Range (HDR) electro-optical conversion function, it can be the Perceptual Quantizer (PQ) electro-optical conversion function or the Hybrid Log-Gamma (HLG) electro-optical conversion function, etc.), since the brightness is very small (for example, 0, 1, 2, 3, etc.), the interpolation operation will cause the light signal data values of multiple interpolation points to be the same, resulting in the grayscale merging problem during display (i.e., the dark texture of low grayscale disappears). In order to further improve the sampling accuracy in the low gray range and reduce the grayscale merging phenomenon in the low gray range, among the sampling points of the embodiment of the present disclosure, the step length between the sampling points in the low gray interval can be smaller than the step length between the sampling points outside the low gray interval. In other words, the intervals between the sampling points in the low gray interval are smaller than those between other sampling points.
[0079] The low gray interval may represent an interval in which the electrical signal data value is less than a preset threshold value, and may be considered as an interval with relatively low brightness.
[0080] In the process of determining the sampling points in the embodiment of the present disclosure, the pre-sampling points can be set, the sampling points can be randomly generated within the pre-sampling point range, interpolation can be performed based on the generated set of sampling points, and the error between the interpolated points and the original mapping table can be calculated. The above process is repeated until a set of sampling points with an error threshold value is selected.
[0081] The following Figure 4 For details on how to determine the sampling points, see Figure 4 , showing a flow chart of a display data conversion method according to an embodiment of the present disclosure. Figure 4 As shown, the method may also include:
[0082] Step S401: determine N pre-sampling points in the original mapping table.
[0083] The original mapping table can be determined by discretizing the above EOTF curve into multiple points (e.g., 1024 points), and can include mapping relationships between M pairs of electrical signal data and optical signal data. The N pre-sampling points can respectively correspond to the mapping relationships between N pairs of electrical signal data and optical signal data in the original mapping table, N and M are positive integers, and the value of M can be greater than N.
[0084] The number of pre-sampling points can be set according to the space requirements of the display device. For example, for a 10-bit original mapping table, the value of M is 1024, and the minimum number of pre-sampling points can be set to 33 (that is, the value of N is set to 33). The number of pre-sampling points can be used to control the number of sampling points finally obtained.
[0085] Figure 5 FIG. 2 is a schematic diagram showing a pre-sampling point determination according to an embodiment of the present disclosure. Figure 5 As shown, p0~p32 can correspond to 33 pre-sampling points respectively, the horizontal axis represents the electrical signal data, and the vertical axis represents the optical signal data. Figure 5 As shown, the first determined multiple pre-sampling points can be equally spaced pre-sampling points, that is, when the pre-sampling points are determined for the first time, the spacing (also referred to as the step length) between adjacent pre-sampling points can be equal. In subsequent iterations, the positions of the pre-sampling points can be readjusted based on the positions of the sampling points.
[0086] Among them, the first pre-sampling point (such as Figure 5 The position of p0 in is fixed to 0. The last pre-sampling point (such as Figure 5The position of p32 in the figure is fixed to the maximum value of the electrical signal data (for example, the maximum value is 1023 for 10-bit electrical signal data), and the corresponding optical signal data can be the maximum fixed-point value determined by the hardware device (i.e., the display device end) (for example, the maximum value is 262143 for 18-bit optical signal data).
[0087] Step S402: randomly generate sampling points between two adjacent pre-sampling points, and determine N randomly generated sampling points.
[0088] The sampling points may be randomly generated starting from the first pre-sampling point (p0). In step S402, the following may be performed:
[0089] Based on a random generation function (such as rand()), sampling points are generated between two adjacent pre-sampling points to determine N randomly generated sampling points. For example, for each pair of adjacent pre-sampling points, a sampling point can be randomly generated based on rand() using the position of the pre-sampling points. Figure 6 , showing a schematic diagram of generating sampling points according to an embodiment of the present disclosure. Figure 6 As shown, pr01 and pr02 can represent randomly generated sampling points, wherein the position of sampling point pr01 can be obtained by a random generation function in the interval p0~p1, and the position of sampling point pr02 can be obtained by a random generation function in the interval p1~p2, and so on, the positions of 33 sampling points can be obtained, and there can be one sampling point between each pair of adjacent pre-sampling points. Among them, the position of the first sampling point (pr00) can be fixed to correspond to 0, and the position of the last sampling point (pr32) can be fixed to correspond to the maximum value of the electrical signal data. If the number of sampling points after random generation is to be kept consistent with the number of pre-sampling points, the process of randomly generating sampling points may not be performed between the last two pre-sampling points, that is, after step S402, the sampling points obtained are the first sampling point pr00 (i.e., the fixed position p0), the last sampling point pr32 (i.e., the fixed maximum value p32), and the sampling points pr01 to pr31 randomly generated in pairs between the pre-sampling points p0-p31, for a total of 33. Optionally, in order to ensure that there is no precision loss in the low gray interval, the step size of the sampling points in the low gray interval may be reduced (this may be achieved by setting the first few sampling points to a smaller step size, for example, the first few sampling points may be fixed to the same continuous points as the original mapping table, and in order to prevent the partial error outside the low gray interval from expanding, the number of the first few sampling points may be controlled so as not to exceed the threshold), so that the density of the sampling points in the low gray interval is greater than that in other intervals, so as to ensure that the sampling error in the low gray interval is small and reduce the problem of grayscale merging.
[0090] If two identical sampling points appear, or there is a sampling point greater than the maximum sampling point (i.e. p32 mentioned above), it can be considered that the random sampling has failed and resampling can be performed.
[0091] Optionally, in order to reduce the above-mentioned phenomenon of reducing grayscale merging in the low gray interval, the step length between the sampling points in the low gray interval in the finally generated sampling points is smaller than the step length between the sampling points outside the low gray interval. When the position of the sampling point is determined by a random generation function, the random generation function can be multiplied by a preset coefficient less than 1, so that the generated N sampling points fall more into the low gray interval, thereby making the step length between the sampling points in the low gray interval smaller.
[0092] Step S403 , based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the N randomly generated sampling points, interpolation is performed to calculate the interpolated optical signal data corresponding to the M electrical signal data.
[0093] That is to say, the interpolated optical signal data corresponding to each electrical signal data in the original mapping table can be calculated by interpolation based on N randomly generated sampling points, and the interpolation can be linear interpolation or nonlinear interpolation. The interpolated optical signal data corresponding to the electrical signal data between two sampling points can be obtained by interpolation based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the two adjacent sampling points. Taking linear interpolation as an example, one way of interpolation can be referred to the following formula:
[0094]
[0095] Among them, optical i It can represent the interpolated optical signal data value corresponding to the interpolation point i (representing the electrical signal data), optical_pr n It can represent the sampling point pr n The corresponding optical signal data value, optical_pr n-1 It can represent the sampling point pr n-1 The corresponding optical signal data value, pr n-1 ≤i<pr n .
[0096] Taking the above as an example, the sampling point pr in the interpolation formula n ,pr n-1 The adjacent sampling points among the N randomly generated sampling points can be brought in, for example Figure 6 In pr01 and pr02, i can take any value between pr01 and pr02. In this way, the interpolated optical signal data corresponding to the M electrical signal data in the original mapping table can be interpolated and calculated based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the adjacent sampling points in the N randomly generated sampling points.
[0097] For example, for 10-bit electrical signal data (i.e., all electrical signal data in the original mapping table), the 1024 electrical signal data of [0-1023] can be used as interpolation points, and the above formula can be used to interpolate and calculate the interpolated optical signal data corresponding to the 1024 interpolation points. n-1 pr00, pr n is pr01; at the interpolation point i between pr01 and pr02, pr n-1 pr01, pr n Based on the mapping relationship between the electrical signal data and the optical signal data corresponding to pr00-pr32, the interpolated optical signal data corresponding to the 1024 interpolation points can be interpolated and calculated, that is, the interpolated optical signal data corresponding to the 1024 electrical signal data (in this case, the value of N is 33 and the value of M is 1024).
[0098] Figure 7 FIG. 2 is a schematic diagram showing an interpolation calculation according to an embodiment of the present disclosure. Figure 7 As shown, in Figure 3 The EOTF curve shown (i.e. Figure 7 Based on the curve in FIG, the interpolated optical signal data corresponding to the 1024 interpolation points obtained by the above interpolation calculation are connected to obtain Figure 7 The broken line in .
[0099] Step S404: adjusting the N randomly generated sampling points based on the interpolated optical signal data to determine N sampling points.
[0100] Therefore, by randomly generating sampling points within the pre-sampling point range, interpolating and calculating the interpolated optical signal data corresponding to the M electrical signal data based on a set of randomly generated sampling points, and adjusting the N randomly generated sampling points based on the interpolated optical signal data, the sampling points can be controlled. Compared with the method of setting sampling points at equal intervals in the prior art, the accuracy of data conversion can be further guaranteed.
[0101] In step S404, you can:
[0102] The error between the interpolated optical signal data and the corresponding optical signal data in the original mapping table is calculated; and the N randomly generated sampling points are adjusted based on the error to determine the N sampling points.
[0103] For example, for the interpolated optical signal data corresponding to the 1024 electrical signal data obtained above, and the optical signal data corresponding to the 1024 electrical signal data in the original mapping table, the corresponding electrical signal data can be the same (ie, Figure 7The interpolated optical signal data (with the same horizontal axis as shown) is subtracted from the optical signal data in the original mapping table to obtain an error value between the two. The error value between the optical signal data in the original mapping table and the interpolated optical signal data can be calculated point by point, and the errors corresponding to each optical signal data are summed to calculate the error sum (error).
[0104] Among them, you can:
[0105] In response to the sum of errors (error) corresponding to the M optical signal data being greater than an error threshold (error_threshold), the current N randomly generated sampling points are used as new pre-sampling points, and step S402 and subsequent steps are re-executed; in response to the sum of errors corresponding to the M optical signal data being not greater than the error threshold, the current N randomly generated sampling points are used as N sampling points.
[0106] Therefore, by controlling the error threshold, it is possible to reduce the occupation of hardware storage space while ensuring the accuracy of subsequent data conversion.
[0107] For example, when error>error_threshold, Figure 6 The positions of the sampling points p0 (i.e., pr00), pr01, pr02 ... p32 (i.e., pr32) shown in replace the positions of the pre-sampling points p0, p1, p2 ... p32 respectively, wherein the positions of the pre-sampling points p0 and p32 are kept unchanged, thereby obtaining a new set of pre-sampling points (including 33 pre-sampling points), and then a new set of N sampling points can be generated by the method described in step S402, and the subsequent steps are executed.
[0108] When error≤error_threshold, the current Figure 6 The positions of the sampling points p0 (ie, pr00), pr01, pr02, ..., p32 (ie, pr32) shown in the figure are used as the positions of the N sampling points finally obtained.
[0109] The error threshold can be set in advance. By controlling the error threshold, the value range of the generated sampling points after interpolation can be effectively controlled. The smaller the error threshold is set, the higher the accuracy of subsequent data conversion. For example, the minimum error threshold can be set to 0. When the error threshold is set to 0, the generated valid sampling points are lossless optimal sampling points.
[0110] Optionally, in order to ensure that grayscale merging does not occur in the low gray interval, the error of the interpolation calculation result in the low gray interval can also be calculated separately, and the errors corresponding to all the above optical signal data can be combined to jointly control the N sampling points finally generated. The above calculation of the error between the interpolated optical signal data and the corresponding optical signal data in the original mapping table can also include: calculating the error between the optical signal data in the low gray interval and the corresponding optical signal data in the original mapping table, wherein the sum of the errors of the optical signal data corresponding to the electrical signal data in the low gray interval can be calculated, and the error threshold corresponding to the low gray interval can be set separately (the error threshold corresponding to the low gray interval can be set to be less than the above error threshold). Thus, in the process of adjusting the N randomly generated sampling points based on the errors and determining the N sampling points, it is also possible to: in response to the sum of the errors corresponding to the M optical signal data being greater than the error threshold, or the sum of the errors of the optical signal data in the low-gray interval being greater than the error threshold corresponding to the low-gray interval, use the current N randomly generated sampling points as new pre-sampling points and re-execute step S402 and subsequent steps; in response to the sum of the errors corresponding to the M optical signal data being not greater than the error threshold and the sum of the errors of the optical signal data in the low-gray interval being not greater than the error threshold corresponding to the low-gray interval, use the current N randomly generated sampling points as the N sampling points.
[0111] The N sampling points corresponding to each iteration may also be stored in a sampling point queue, and the corresponding sum of errors (which may be the sum of errors corresponding to all M optical signal data, or the sum of errors plus the sum of errors of the optical signal data corresponding to the low gray interval) may be stored in an error queue. A threshold of the number of iterations may be set. For example, when the number of iterative calculations reaches the threshold, the one with the smallest sum of errors is selected from the error queue, and the corresponding N sampling points are taken out of the sampling point queue as the final N sampling points.
[0112] Figure 8 FIG. 2 is a schematic diagram showing a sampling point determination according to an embodiment of the present disclosure. Figure 8 As shown, the position of the first sampling point (p0) is fixed to correspond to 0, the position of the last sampling point (p32) is fixed to correspond to the maximum value of the electrical signal data, and pr01, pr02, ... are the N sampling points finally determined through the above iterations.
[0113] After the sampling points are determined, the target optical signal data corresponding to the target electrical signal data can be interpolated based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling points in the above-determined sampling points. The interpolation can be linear interpolation or nonlinear interpolation. The linear interpolation method can refer to the above formula. For example, the target electrical signal data can be substituted into the point to be interpolated. , substitute the two target sampling points into pr n and pr n-1, substitute the optical signal data values corresponding to the two target sampling points into optical_pr n and optical_pr n-1 , to calculate the optical i As the target optical signal data corresponding to the target electrical signal data.
[0114] Fig. 9 FIG. 2 shows a structural diagram of a display data conversion device according to an embodiment of the present disclosure. Fig. 9 As shown, the device comprises:
[0115] A first determination module 901 is used to determine, based on the target electrical signal data of the image to be displayed, a target sampling point adjacent to the target electrical signal data among the sampling points, and a mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling point;
[0116] The first interpolation calculation module 902 is used to interpolate and calculate target optical signal data corresponding to the target electrical signal data based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling point, and the target optical signal data is used for display; the sampling point includes a plurality of non-equidistant sampling points.
[0117] In a possible implementation, the number of target sampling points is 2, and the interpolation includes linear interpolation.
[0118] In a possible implementation, the step length between sampling points in a low-gray interval is smaller than the step length between sampling points outside the low-gray interval, and the low-gray interval represents an interval in which the data value of the electrical signal is smaller than a preset threshold.
[0119] In a possible implementation manner, the sampling points include N sampling points, and the device further includes:
[0120] A second determination module is used to determine N pre-sampling points in an original mapping table, the original mapping table includes mapping relationships between M pairs of electrical signal data and optical signal data, the N pre-sampling points respectively correspond to the mapping relationships between the N pairs of electrical signal data and optical signal data in the original mapping table, N and M are positive integers, and the value of M is greater than N;
[0121] A third determination module is used to randomly generate sampling points between two adjacent pre-sampling points, and determine N randomly generated sampling points;
[0122] A second interpolation calculation module is used to interpolate and calculate the interpolated optical signal data corresponding to the M electrical signal data respectively based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the N randomly generated sampling points;
[0123] The adjustment module is used to adjust the N randomly generated sampling points based on the interpolated optical signal data to determine the N sampling points.
[0124] In a possible implementation manner, the third determining module is configured to:
[0125] Based on a random generation function, sampling points are respectively generated between two adjacent pre-sampling points to determine N randomly generated sampling points, wherein the random generation function is multiplied by a preset coefficient less than 1.
[0126] In a possible implementation, the position of the first sampling point among the N sampling points is fixed to correspond to 0, the position of the last sampling point among the N sampling points is fixed to correspond to the maximum value of the electrical signal data, and the N pre-sampling points determined for the first time are pre-sampling points with equal spacing.
[0127] In a possible implementation, the adjustment module is used to:
[0128] Calculating the error between the interpolated optical signal data and the corresponding optical signal data in the original mapping table;
[0129] The N randomly generated sampling points are adjusted based on the error to determine the N sampling points.
[0130] In a possible implementation, adjusting N randomly generated sampling points based on the error to determine the N sampling points includes:
[0131] In response to the sum of errors corresponding to the M optical signal data being greater than an error threshold, taking the current N randomly generated sampling points as new N pre-sampling points, re-executing the steps of randomly generating sampling points between two adjacent pre-sampling points, determining the N randomly generated sampling points and subsequent steps;
[0132] In response to the sum of errors corresponding to the M optical signal data being no greater than an error threshold, the current N randomly generated sampling points are used as N sampling points.
[0133] According to an embodiment of the present disclosure, based on the target electrical signal data of the image to be displayed, the target sampling points adjacent to the target electrical signal data in the sampling points, and the mapping relationship between the electrical signal data corresponding to the target sampling points and the optical signal data are determined, and further based on the mapping relationship between the electrical signal data corresponding to the target sampling points and the optical signal data, the target optical signal data corresponding to the target electrical signal data is interpolated and calculated to obtain the target optical signal data for display, thereby realizing the conversion of electrical signals to optical signals using the interpolation method, reducing the occupation of hardware storage space, and by making the sampling points include multiple sampling points with non-equidistant intervals, the error of the interpolation calculation can be reduced, so that the accuracy of the interpolation calculation is higher, while reducing the occupation of hardware storage space, the accuracy of data conversion is guaranteed, so as to achieve a better display effect.
[0134] In some embodiments, the functions or modules included in the device provided by the embodiments of the present disclosure can be used to execute the method described in the above method embodiments. The specific implementation can refer to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.
[0135] The embodiment of the present disclosure also provides a computer-readable storage medium on which computer program instructions are stored, and the computer program instructions implement the above method when executed by a processor. The computer-readable storage medium can be a volatile or non-volatile computer-readable storage medium.
[0136] The embodiment of the present disclosure also proposes a display data conversion device, comprising: a processor; a memory for storing instructions executable by the processor; wherein the processor is configured to implement the above method when executing the instructions stored in the memory.
[0137] The embodiments of the present disclosure also provide a computer program product, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of an electronic device, the processor in the electronic device executes the above method.
[0138] Fig.10 1 is a block diagram of a device 1900 for display data conversion according to an exemplary embodiment. For example, the device 1900 can be provided as a server or a terminal device. Fig.10 , the apparatus 1900 includes a processing component 1922, which further includes one or more processors, and a memory resource represented by a memory 1932 for storing instructions, such as an application, that can be executed by the processing component 1922. The application stored in the memory 1932 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 1922 is configured to execute instructions to perform the above method.
[0139] The device 1900 may also include a power supply component 1926 configured to perform power management of the device 1900, a wired or wireless network interface 1950 configured to connect the device 1900 to a network, and an input / output interface 1958 (I / O interface). The device 1900 may operate based on an operating system stored in the memory 1932, such as Windows Server 2000. TM , MacOS X TM , Unix TM , Linux TM , FreeBSD TM or similar.
[0140] In an exemplary embodiment, a non-volatile computer-readable storage medium is also provided, such as a memory 1932 including computer program instructions, which can be executed by the processing component 1922 of the device 1900 to perform the above method.
[0141] The present disclosure may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.
[0142] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the above. More specific examples (a non-exhaustive list) of computer-readable storage media include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the above. The computer-readable storage medium used herein is not to be interpreted as a transient signal itself, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.
[0143] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.
[0144] The computer program instructions for performing the operations of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. The computer-readable program instructions may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer, partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect through the Internet). In some embodiments, by using the state information of the computer-readable program instructions to personalize an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), the electronic circuit may execute the computer-readable program instructions, thereby implementing various aspects of the present disclosure.
[0145] Various aspects of the present disclosure are described herein with reference to flowcharts and / or block diagrams of methods, devices (systems) and computer program products according to embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of boxes in the flowchart and / or block diagram can be implemented by computer-readable program instructions.
[0146] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processor of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0147] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0148] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of the module, program segment or instruction includes one or more executable instructions for realizing the specified logical function. In some alternative implementations, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of special hardware and computer instructions.
[0149] The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.
Claims
1. A display data conversion method, characterized in that: The method comprises: Based on the target electrical signal data of the image to be displayed, determining the target sampling points adjacent to the target electrical signal data among the sampling points, and the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling points; Based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling points, target optical signal data corresponding to the target electrical signal data is interpolated and calculated, and the target optical signal data is used for display; the sampling points include multiple sampling points with non-equidistant intervals.
2. The method according to claim 1, characterized in that The step length between sampling points in a low-gray interval is smaller than the step length between sampling points outside the low-gray interval, and the low-gray interval represents an interval in which the data value of the electrical signal is smaller than a preset threshold.
3. The method according to claim 1, characterized in that The sampling points include N sampling points, and the method further includes: Determine N pre-sampling points in an original mapping table, the original mapping table includes mapping relationships between M pairs of electrical signal data and optical signal data, the N pre-sampling points respectively correspond to the mapping relationships between the N pairs of electrical signal data and optical signal data in the original mapping table, N and M are positive integers, and the value of M is greater than N; Randomly generate sampling points between two adjacent pre-sampling points, and determine N randomly generated sampling points; Based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the N randomly generated sampling points, interpolation is performed to calculate the interpolated optical signal data corresponding to the M electrical signal data respectively; The N randomly generated sampling points are adjusted based on the interpolated optical signal data to determine the N sampling points.
4. The method according to claim 3, characterized in that The adjusting the N randomly generated sampling points based on the interpolated optical signal data to determine the N sampling points includes: Calculating the error between the interpolated optical signal data and the corresponding optical signal data in the original mapping table; The N randomly generated sampling points are adjusted based on the error to determine the N sampling points.
5. The method according to claim 4, characterized in that The adjusting the N randomly generated sampling points based on the error to determine the N sampling points includes: In response to the sum of errors corresponding to the M optical signal data being greater than an error threshold, using the current N randomly generated sampling points as new N pre-sampling points, and re-performing the steps of randomly generating sampling points between two adjacent pre-sampling points, determining the N randomly generated sampling points, and subsequent steps; In response to the sum of errors corresponding to the M optical signal data being no greater than the error threshold, currently N randomly generated sampling points are used as the N sampling points.
6. The method according to claim 3, characterized in that The randomly generating sampling points between two adjacent pre-sampling points and determining N randomly generated sampling points comprises: Based on a random generation function, sampling points are respectively generated between two adjacent pre-sampling points to determine N randomly generated sampling points, wherein the random generation function is multiplied by a preset coefficient less than 1.
7. The method according to claim 3, characterized in that The position of the first sampling point among the N sampling points is fixed to correspond to 0, the position of the last sampling point among the N sampling points is fixed to correspond to the maximum value of the electrical signal data, and the N pre-sampling points determined for the first time are pre-sampling points with equal spacing.
8. The method according to claim 1, characterized in that The number of the target sampling points is 2, and the interpolation includes linear interpolation.
9. A display data conversion device, characterized in that: The device comprises: A first determination module, configured to determine, based on target electrical signal data of an image to be displayed, target sampling points adjacent to the target electrical signal data among the sampling points, and a mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling points; The first interpolation calculation module is used to interpolate and calculate the target optical signal data corresponding to the target electrical signal data based on the mapping relationship between the electrical signal data and the optical signal data corresponding to the target sampling points, wherein the target optical signal data is used for display; the sampling points include a plurality of non-equidistant sampling points.
10. A display data conversion device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to implement the method described in any one of claims 1 to 8 when executing the instructions stored in the memory.
11. A non-volatile computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 8 is implemented.
Citation Information
Patent Citations
Image processing method and device
CN112634383A
Video playing method and device, computer equipment and storage medium
CN116137674A
Color lookup table generation method and color correction method
CN117612470A
Image processing method and device
CN119006280A
IMPROVING VIDEO SIGNAL TRANSFER USING VARIABLE SEGMENTED LOOKUP TABLES
DE102019102308A1