Image data conversion method and device and computer equipment

By determining and adjusting the fill pixel values ​​of multiple color channels in the image data conversion method, the problems of grayscale deviation and color distortion in image data processing in the prior art are solved, and a more efficient image data decompression and restoration effect is achieved.

CN119922318APending Publication Date: 2025-05-02KUNSHAN GO VISIONOX OPTO ELECTRONICS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510072870.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-16
Publication Date
2025-05-02

AI Technical Summary

Technical Problem

The performance of existing OLED and other display products needs to be improved, especially in image data processing, there are problems of grayscale deviation and color distortion.

Method used

An image data conversion method is provided, by obtaining the pixel values ​​of each pixel point of the target image, determining the fill pixel values ​​of the target color channel in a plurality of color channels, and determining the fill pixel values ​​of the remaining color channels based on the subpixel values ​​of the target color channel, thereby obtaining the target subpixel values ​​of each color channel. This method reduces distortion of the fill pixel values ​​of the remaining color channels and reduces grayscale deviation values ​​before and after compression.

Benefits of technology

By reducing the distortion of the fill pixel values ​​of the remaining color channels, the distortion of the target subpixel values ​​is reduced, and the grayscale uniformity and color loyalty of the image are improved, thereby improving the performance of the display product.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119922318A_ABST
    Figure CN119922318A_ABST
Patent Text Reader

Abstract

The invention relates to an image data conversion method and device and computer equipment. The image data conversion method comprises the steps that image data are acquired, the image data comprise pixel values of all pixel points in a target image, and the pixel values comprise sub-pixel values corresponding to a plurality of color channels respectively; for each pixel value, determining a filling pixel value corresponding to a target color channel in the plurality of color channels, and determining one or more or each corresponding filling pixel value in other color channels based on a sub-pixel value corresponding to the target color channel, obtaining a target sub-pixel value corresponding to each color channel based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel; and taking the target sub-pixel values corresponding to the color channels of the plurality of pixel points as the image data after the image data is subjected to decompression processing. By adopting the method, the gray scale deviation value before compression and after decompression reduction can be reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of image data processing, and in particular to an image data conversion method, device and computer equipment. Background Art

[0002] The development of semiconductor technology plays a vital role in the progress of the electronics industry. Organic Light-Emitting Diode (OLED) and other products have attracted great attention and are widely used in electronic display products due to their advantages such as simple preparation process, low cost, low power consumption, high brightness, wide viewing angle, high contrast and flexible display.

[0003] However, the performance of current display products such as OLED needs to be improved. Summary of the invention

[0004] Based on this, it is necessary to provide an image data conversion method, device and computer equipment to address the above technical problems.

[0005] In a first aspect, the present application provides an image data conversion method, the method comprising: acquiring image data, the image data comprising pixel values ​​of each pixel point in a target image, the pixel values ​​comprising sub-pixel values ​​corresponding to a plurality of color channels respectively; for each pixel value, determining a fill pixel value corresponding to a target color channel among a plurality of color channels, and based on the sub-pixel value corresponding to the target color channel, determining one or more or each corresponding fill pixel value in the remaining color channels, and obtaining a target sub-pixel value corresponding to each color channel based on the sub-pixel value corresponding to each color channel and the fill pixel value corresponding to each color channel; using the target sub-pixel value corresponding to each color channel of the plurality of pixel points as image data after decompression processing of the image data.

[0006] In one of the embodiments, the number of bits of the sub-pixel value corresponding to the target color channel is greater than the number of bits of the sub-pixel value corresponding to one or more or each of the remaining color channels;

[0007] Optionally, the number of bits of the filling pixel value corresponding to the target color channel is less than the number of bits of the filling pixel value corresponding to one or more or each of the remaining color channels;

[0008] Optionally, the sum of the number of bits of the sub-pixel value and the padding pixel value corresponding to the target color channel is equal to the sum of the number of bits of the sub-pixel value and the padding pixel value corresponding to one or more or each of the remaining color channels;

[0009] Optionally, the number of bits of the sub-pixel value corresponding to the target color channel is N greater than the number of bits of one or more or each corresponding sub-pixel value in the remaining color channels, where N is an integer greater than or equal to 1;

[0010] And / or, determining a fill pixel value corresponding to a target color channel among multiple color channels, and determining one or more or each corresponding fill pixel value in the remaining color channels based on the sub-pixel value corresponding to the target color channel, including: obtaining a value of a first target bit in the sub-pixel value corresponding to the target color channel; determining a fill pixel value corresponding to the target color channel, and determining one or more or each corresponding fill pixel value in the remaining color channels based on the value of the first target bit;

[0011] Optionally, the first target bit is the lowest bit in the sub-pixel value corresponding to the target color channel.

[0012] In one of the embodiments, determining the fill pixel value corresponding to the target color channel, and determining one or more or each corresponding fill pixel value in the remaining color channels based on the value of the first target bit, includes: using the value of the first target bit as the value of the second target bit in one or more or each corresponding fill pixel value in the remaining color channels; determining the fill pixel value corresponding to the target color channel, and determining the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels; using the value of the second target bit and the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels as one or more or each corresponding fill pixel value in the remaining color channels;

[0013] Optionally, the second target bit is the highest bit in one or more or each corresponding filling pixel value in the remaining color channels.

[0014] In one embodiment, the fill pixel value corresponding to the target color channel is determined, and the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels are determined, including: using a preset value as the value of each bit in the fill pixel value corresponding to the target color channel, and the value of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels.

[0015] In one of the embodiments, determining the fill pixel value corresponding to the target color channel, and determining the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels, includes: using a preset value as the initial value of each bit in the fill pixel value corresponding to the target color channel, and using the preset value as the initial value of each bit in the fill pixel value corresponding to the target color channel, and using the preset value as the initial value of each bit in the fill pixel value corresponding to the target color channel, and the initial value of each bit in the fill pixel value corresponding to the target color channel, and the initial value of each bit in the fill pixel value corresponding to the target color channel, and the initial value of each bit in the fill pixel value corresponding to the target color channel, and the value of each bit in the fill pixel value corresponding to the target color channel.

[0016] Optionally, the initial value of each bit in the filling pixel value corresponding to the target color channel and the initial value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels are compensated to obtain the value of each bit in the filling pixel value corresponding to the target color channel and the value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels, including:

[0017] Taking the pixel values ​​of a preset number of pixels as an array unit, for each array unit, based on the i-th element in the compensation matrix, determine the value of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels, where i is an integer greater than or equal to 1;

[0018] Optionally, the compensation matrix comprises at least two filling values,

[0019] Optionally, at least two filling values ​​in the compensation matrix are greater than or equal to a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and less than or equal to a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel;

[0020] Optionally, at least one filling value in the compensation matrix is ​​greater than a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and less than a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel;

[0021] Optionally, at least two filling values ​​in the compensation matrix are greater than a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; and less than a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel;

[0022] Optionally, at least one filling value in the compensation matrix is ​​greater than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and at least one filling value in the compensation matrix is ​​less than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel;

[0023] Optionally, the average value of all filling values ​​in the compensation matrix is ​​equal to the average value of the maximum value and the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel;

[0024] Optionally, adjacent filling values ​​along the row direction in the compensation matrix are different, and / or adjacent filling values ​​along the column direction in the compensation matrix are different, and the row direction and the column direction intersect;

[0025] And / or, adjacent filling values ​​along the first diagonal direction in the compensation matrix are the same, and / or, adjacent filling values ​​along the second diagonal direction in the compensation matrix are the same, the first diagonal direction intersects with the row direction, the first diagonal direction intersects with the column direction, the second diagonal direction intersects with the row direction, the second diagonal direction intersects with the column direction, and the first diagonal direction intersects with the second diagonal direction.

[0026] In one embodiment, determining the filling pixel value corresponding to the target color channel and determining the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels includes: taking the pixel values ​​of a preset number of pixels as an array unit, and for each array unit, determining the values ​​of the bits in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels based on the i-th element in the compensation matrix;

[0027] And / or, in the pixel array corresponding to the target image, the target color channels of two adjacent pixel points along the row direction have different filling pixel values, and the values ​​of the remaining bits in one or more or each of the filling pixel values ​​corresponding to the remaining color channels of the two adjacent pixel points along the row direction are different; the row direction and the column direction intersect;

[0028] And / or, in the pixel array corresponding to the target image, the average value of the filling pixel values ​​corresponding to the target color channels of all pixels is equal to the average value of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels;

[0029] And / or, in the pixel point array corresponding to the target image, one of the filling pixel values ​​corresponding to the target color channels of two pixel points adjacent along the row direction is greater than the average value, and the other is less than the average value; one of the values ​​of the remaining bits of the filling pixel values ​​corresponding to one or more or each of the remaining color channels of the two pixel points adjacent along the row direction is greater than the average value, and the other is less than the average value; the average value is equal to the average value of the maximum and minimum values ​​corresponding to the bit number of the filling pixel values ​​corresponding to the target color channel;

[0030] And / or, in the pixel array corresponding to the target image, the average value of the filling pixel values ​​corresponding to the target color channels of all the pixels is the middle value determined according to the deviation range;

[0031] And / or, in the pixel array corresponding to the target image, the target color channels of two adjacent pixel points along the column direction have different filling pixel values ​​corresponding to them, and the values ​​of the remaining bits in one or more or each of the filling pixel values ​​corresponding to the remaining color channels of the two adjacent pixel points along the column direction are different;

[0032] And / or, for the same pixel, the filling pixel value corresponding to the target color channel is the same as the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels;

[0033] And / or, among the four pixels located in two adjacent rows and two columns, the target color channels of two pixels located in different rows and columns have the same filling pixel values, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels are the same; and the target color channels of another two pixels located in different rows and columns have the same filling pixel values, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels are the same.

[0034] Optionally, the deviation range is obtained by taking the preset value as the value of each bit in the filling pixel value corresponding to the target color channel and the value of each remaining bit in the filling pixel value corresponding to one or more or each of the remaining color channels, and obtaining the difference between the target sub-pixel value corresponding to each color channel and the sub-pixel value corresponding to each color channel before the pixel value is compressed;

[0035] Optionally, the deviation range is for multiple different pixel values, and the steps of using preset values ​​as the values ​​of each bit in the filling pixel value corresponding to the target color channel, and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are executed to obtain target sub-pixel values ​​corresponding to each color channel of multiple different pixel values, and subtracting the target sub-pixel values ​​corresponding to each color channel of each pixel value from the sub-pixel values ​​corresponding to each color channel before the pixel values ​​are compressed to obtain difference values ​​corresponding to multiple different pixel values, which are obtained based on the maximum value of the multiple difference values.

[0036] In one embodiment, based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel, obtaining the target sub-pixel value corresponding to each color channel includes: for each color channel, concatenating the value of each bit in the sub-pixel value corresponding to the color channel with the value of each bit in the filling pixel value corresponding to the color channel to obtain the target sub-pixel value corresponding to the color channel;

[0037] Optionally, in the pixel array corresponding to the target image, the target color channels of at least two pixel points have different filling pixel values, and one or more or each of the remaining color channels of at least two pixel points have different filling pixel values;

[0038] Optionally, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixel points are greater than or equal to the minimum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels, and are less than or equal to the maximum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels;

[0039] Optionally, in the pixel array corresponding to the target image, a filling pixel value corresponding to a target color channel of at least one pixel is greater than a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and is less than a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel;

[0040] Optionally, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixel points are greater than the minimum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels; and are less than the maximum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels;

[0041] Optionally, in the pixel point array corresponding to the target image, a filling pixel value corresponding to a target color channel of at least one pixel point is greater than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and a filling pixel value corresponding to a target color channel of at least one pixel point is less than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel;

[0042] And / or, in the pixel array corresponding to the target image, the average value of the filling pixel values ​​corresponding to the target color channels of all pixels is equal to the average value of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels;

[0043] Optionally, for each color channel, each bit in the sub-pixel value is higher than each bit in the fill pixel value;

[0044] Optionally, for each color channel, the lowest bit in each bit in the sub-pixel value is higher than the highest bit in each bit in the padding pixel value;

[0045] Optionally, for each color channel, the number of bits of the padded pixel value is greater than or equal to M, where M is 1 or 2 or 3.

[0046] In a second aspect, the present application also provides an image data conversion method, the method comprising:

[0047] Acquire image data, the image data including pixel values ​​of each pixel in the target image, the pixel values ​​including sub-pixel values ​​corresponding to multiple color channels respectively;

[0048] For each pixel value, a filling pixel value corresponding to a target color channel among multiple color channels is determined, and one or more or each corresponding filling pixel value in the remaining color channels is determined, and a target sub-pixel value corresponding to each color channel is obtained based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel; the number of bits of the filling pixel value corresponding to the target color channel is different from the number of bits of the filling pixel value corresponding to one or more or each corresponding filling pixel value in the remaining color channels, and / or, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixels are different, and the filling pixel values ​​corresponding to one or more or each corresponding filling pixel value in the remaining color channels of at least two pixels are different.

[0049] In a third aspect, the present application further provides an image data conversion device, the device comprising:

[0050] An acquisition module is used to acquire image data, wherein the image data includes a pixel value of each pixel point in the target image, and the pixel value includes sub-pixel values ​​corresponding to multiple color channels respectively;

[0051] A first determination module is used to determine, for each pixel value, a filling pixel value corresponding to a target color channel among multiple color channels, and determine one or more or each corresponding filling pixel value in the remaining color channels based on the sub-pixel value corresponding to the target color channel, and obtain a target sub-pixel value corresponding to each color channel based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel;

[0052] The second determining module is used to use the target sub-pixel value corresponding to each color channel of the plurality of pixel points as the image data after decompressing the image data.

[0053] In a fourth aspect, the present application further provides an image data conversion device, the device comprising:

[0054] An acquisition module is used to acquire image data, wherein the image data includes a pixel value of each pixel point in the target image, and the pixel value includes sub-pixel values ​​corresponding to multiple color channels respectively;

[0055] A first determination module is used to determine, for each pixel value, a filling pixel value corresponding to a target color channel among multiple color channels, and to determine one or more or each corresponding filling pixel value in the remaining color channels, and to obtain a target sub-pixel value corresponding to each color channel based on a sub-pixel value corresponding to each color channel and a filling pixel value corresponding to each color channel; the number of bits of the filling pixel value corresponding to the target color channel is different from the number of bits of the one or more or each corresponding filling pixel value in the remaining color channels, and in a pixel point array corresponding to a target image, the filling pixel values ​​corresponding to the target color channels of at least two pixels are different, and the filling pixel values ​​corresponding to one or more or each corresponding filling pixel value in the remaining color channels of at least two pixels are different;

[0056] The second determining module is used to use the target sub-pixel value corresponding to each color channel of the plurality of pixel points as the image data after decompressing the image data.

[0057] In a fifth aspect, the present application further provides a computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the method described in any one of the first aspect or the second aspect when executing the computer program.

[0058] In a sixth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the method described in any one of the first aspect or the second aspect are implemented.

[0059] In a seventh aspect, the present application further provides a computer program product, comprising a computer program, which, when executed by a processor, implements the steps of the method described in any one of the first or second aspects above.

[0060] The above-mentioned image data conversion method, device and computer equipment obtain image data, the image data includes pixel values ​​of each pixel in the target image, and the pixel values ​​include sub-pixel values ​​corresponding to multiple color channels respectively, and then for each pixel value, determine the filling pixel value corresponding to the target color channel in multiple color channels, and based on the sub-pixel value corresponding to the target color channel, determine one or more or each corresponding filling pixel value in the remaining color channels, so that the distortion of one or more or each corresponding filling pixel value in the remaining color channels can be reduced. Then, based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel, the target sub-pixel value corresponding to each color channel is obtained, and the target sub-pixel value corresponding to each color channel of the multiple pixel points is used as the image data after decompression processing of the image data, so that since the distortion of one or more or each corresponding filling pixel value in the remaining color channels is reduced, the distortion of one or more or each corresponding target sub-pixel value in the remaining color channels can be reduced, that is, the grayscale deviation value before compression and after decompression and restoration is reduced, thereby improving the performance of the display product. BRIEF DESCRIPTION OF THE DRAWINGS

[0061] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the related technologies, the drawings required for use in the embodiments of the present application or the related technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, they can also obtain other related drawings based on these drawings without paying creative work.

[0062] Figure 1 It is a schematic diagram of RGB888 in the related art;

[0063] Figure 2 It is a schematic diagram of RGB565 in the related art;

[0064] Figure 3 It is a schematic diagram of RGB888 to RGB565 conversion in the related art;

[0065] Figure 4 This is a schematic diagram of an image after converting RGB565 to RGB888 in one embodiment;

[0066] Figure 5 A diagram showing an application environment of an image data conversion method in an embodiment;

[0067] Figure 6 is a flowchart of an image data conversion method in one embodiment;

[0068] Figure 7is a flow chart of an image data conversion method in another embodiment;

[0069] Figure 8 A schematic diagram of a plurality of pixel arrays in a decompressed target image in one embodiment;

[0070] Fig. 9 A schematic diagram of a plurality of pixel arrays in a decompressed target image in another embodiment;

[0071] Fig.10 is a schematic diagram of a compensation matrix;

[0072] Fig.11 is a structural block diagram of an image data conversion device in one embodiment;

[0073] Fig.12 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

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

[0075] Different color encoding formats can be used to create images, such as RGB888 format, RGB565 format, etc. Among them, the RGB888 format means that the sub-pixel value of the pixel in the three color channels of RGB (Chinese: red, green, and blue) occupies 8 bits each, occupying a total of 24 bits; the RGB565 format means that the sub-pixel value of the pixel in the R channel occupies 5 bits, the sub-pixel value in the G channel occupies 6 bits, and the sub-pixel value in the B channel occupies 5 bits, occupying a total of 16 bits.

[0076] In order to reduce the amount of image data transmitted, the sender usually converts the image data, that is, compresses it, such as converting the image data in RGB888 format to RGB565 format, and then sends the compressed image data to the receiver. After receiving the compressed image data, the receiver will decompress and restore the compressed image data, such as converting the image data in RGB565 format to RGB888 format.

[0077] In some cases, the wearable terminal platform creates images in RGB888 format (such as Figure 1 However, when sending images to wearable terminals, the image data in RGB888 format will be converted to RGB565 format (as shown in Figure 2 ) image data.

[0078] like Figure 3 As shown, when the RGB888 format is used, each pixel has 24 bits in total, and the sub-pixel value corresponding to each color channel occupies 8 bits, that is, [7:0]. When converting the RGB888 format to the RGB565 format, the last 3 bits of the sub-pixel value corresponding to the R channel are discarded. At this time, the sub-pixel value corresponding to the R channel occupies 5 bits, that is, [7:3]; the last 2 bits of the sub-pixel value corresponding to the G channel are discarded. At this time, the sub-pixel value corresponding to the G channel occupies 6 bits, that is, [7:2]; the last 3 bits of the sub-pixel value corresponding to the B channel are discarded. At this time, the sub-pixel value corresponding to the B channel occupies 5 bits, that is, [7:3]; compression from 24 bits to 16 bits is achieved. Among them, Figure 3 The bits discarded in are denoted by x.

[0079] When the wearable terminal receives the image data in the RGB565 format, the DDIC (Display Driver Integrated Circuit) in the wearable terminal decompresses the image data in the RGB565 format and restores it to the image data in the RGB888 format.

[0080] In the related art, the receiving party uses a method of directly adding 0 or 1 to the compressed image data during decompression and restoration. When decompressing and restoring the image data in RGB565 format to the image data in RGB888 format, it is implemented by directly adding 0 or 1. Taking 127 grayscale and 120 grayscale as examples, compression and restoration are performed, as shown in Table 1 and Table 2.

[0081] It can be seen that when the method of 0-filling is used, R / B / G: 127 / 127 / 127, after compression and restoration, it becomes 120 / 124 / 120, and the maximum deviation is 7; when the method of 1-filling is used, R / B / G: 120 / 120 / 120, after compression and restoration, it becomes 127 / 123 / 127, and the maximum deviation is 7. When the method of 0-filling or 1-filling is used, there will be a problem that the grayscale deviation value of the image before compression and after decompression and restoration is large. In other words, when the method of 0-filling or 1-filling is used, the grayscale deviation value range is 0~7, and there is a problem that the grayscale deviation value of the image before compression and after decompression and restoration is large. In addition, the different ratios of R, G, and B will result in uneven grayscale transition and grayscale color cast (such as Figure 4 Therefore, the performance of display products in the related technology needs to be further improved.

[0082] Table 1

[0083]

[0084] Table 2

[0085]

[0086] Based on this, it is necessary to propose effective technical means to solve the above problems. The technical solution of the present application and how the technical solution of the present application solves the above technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0087] The image data conversion method provided in the embodiment of the present application can be applied to Figure 5 In the application environment shown. Among them, the terminal 502 communicates with the server 504 through the network. The data storage system can store the data that the server 504 needs to process. The data storage system can be integrated on the server 504, or it can be placed on the cloud or other network servers. The image data conversion method can be executed on the terminal 502 or the server 504, or it can be implemented through the interaction between the terminal 502 and the server 504. Taking the execution on the terminal 502 as an example, the terminal 502 obtains image data, and the image data includes the pixel value of each pixel in the target image, and the pixel value includes the sub-pixel value corresponding to each of the multiple color channels; for each pixel value, the terminal 502 determines the filling pixel value corresponding to the target color channel in the multiple color channels, and based on the sub-pixel value corresponding to the target color channel, determines one or more or each corresponding filling pixel value in the remaining color channels, and based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel, obtains the target sub-pixel value corresponding to each color channel; the terminal 502 uses the target sub-pixel value corresponding to each color channel of the multiple pixels as the image data after decompression processing of the image data.

[0088] The terminal 502 may be, but is not limited to, various personal computers, laptops, smart phones, tablet computers, IoT devices, and portable wearable devices. The IoT devices may be smart speakers, smart TVs, smart air conditioners, smart vehicle-mounted devices, projection devices, etc. The portable wearable devices may be smart watches, smart bracelets, head-mounted devices, etc. The head-mounted devices may be virtual reality (VR) devices, augmented reality (AR) devices, smart glasses, etc.

[0089] The server 504 may be an independent physical server, a server cluster or a distributed system composed of multiple physical servers, or a cloud server providing cloud computing services. The terminal 502 and the server 504 may be directly or indirectly connected via wired or wireless communication, which is not limited in this application.

[0090] In an exemplary embodiment, Figure 6 As shown, a method for converting image data is provided, which is applied to Figure 5 The terminal in is used as an example to illustrate, including the following steps:

[0091] Step 601, acquiring image data, the image data including pixel values ​​of each pixel in the target image, the pixel values ​​including sub-pixel values ​​corresponding to a plurality of color channels.

[0092] The plurality of color channels may be at least two of an R channel, a G channel, and a B channel, and the sub-pixel values ​​corresponding to the plurality of color channels may be at least two of an R sub-pixel value, a G sub-pixel value, and a B sub-pixel value. R may correspond to a first color, such as red. G may correspond to a second color, such as green. B may correspond to a third color, such as blue.

[0093] The image data may be in RGB565 format or in other formats, such as RGB454 format, RGB556 format, etc. The RGB454 format means that the sub-pixel value of the pixel in the R channel occupies 4 bits, the sub-pixel value in the G channel occupies 5 bits, and the sub-pixel value in the B channel occupies 4 bits; the RGB556 format means that the sub-pixel value of the pixel in the R channel occupies 5 bits, the sub-pixel value in the G channel occupies 5 bits, and the sub-pixel value in the B channel occupies 6 bits.

[0094] Optionally, the wearable terminal platform compresses the initial image data in RGB888 format to obtain image data in RGB565 format, and sends the image data in RGB565 format to the terminal, so that the terminal receives the image data. In other words, the wearable terminal platform compresses the pixel value of each pixel in the initial image data from 24 bits to 16 bits, and then sends the compressed image data to the terminal.

[0095] Step 602, for each pixel value, determine the fill pixel value corresponding to the target color channel among the multiple color channels, and based on the sub-pixel value corresponding to the target color channel, determine one or more or each corresponding fill pixel value in the remaining color channels, and based on the sub-pixel value corresponding to each color channel and the fill pixel value corresponding to each color channel, obtain the target sub-pixel value corresponding to each color channel.

[0096] Wherein, the target color channel has at least one of the following characteristics;

[0097] The number of bits of the sub-pixel value corresponding to the target color channel is greater than the number of bits of the sub-pixel value corresponding to one or more or each of the remaining color channels;

[0098] The number of bits of the fill pixel value corresponding to the target color channel is less than the number of bits of the fill pixel value corresponding to one or more or each of the remaining color channels;

[0099] The sum of the number of bits of the sub-pixel value and the padding pixel value corresponding to the target color channel is equal to the sum of the number of bits of the sub-pixel value and the padding pixel value corresponding to one or more or each of the remaining color channels;

[0100] The number of bits of the sub-pixel value corresponding to the target color channel is N greater than the number of bits of the sub-pixel value corresponding to one or more or each of the remaining color channels, where N is an integer greater than or equal to 1;

[0101] The number of bits of the filling pixel value corresponding to the target color channel is N less than the number of bits of the filling pixel value corresponding to one or more or each of the remaining color channels, where N is an integer greater than or equal to 1.

[0102] In one example, the target color channel may be the G channel, and the image data may be in RGB565 format or RGB454 format; the target color channel may also be the B channel, and the image data may be in RGB556 format. After performing step 602 on the image data, the image data in RGB565 format, RGB454 format, or RGB556 format may be converted to image data in RGB888 format.

[0103] In another example, the number of bits of the sub-pixel value corresponding to the target color channel is 6, and the corresponding sub-pixel value of one or more or each of the remaining color channels is 5, which may correspond to image data in RGB565 format; the number of bits of the sub-pixel value corresponding to the target color channel is 6, and the corresponding sub-pixel value of one or more or each of the remaining color channels is 4, which may correspond to image data in RGB464 format.

[0104] When the target color channel is the G channel, one or more or each of the remaining color channels refers to one or more or each of the R channel and the B channel; when the target color channel is the B channel, one or more or each of the remaining color channels refers to one or more or each of the R channel and the G channel. It should be noted that when one or more or each of the remaining color channels is given as an example below, each of the remaining color channels is given as an example.

[0105] The fill pixel value corresponding to the target color channel refers to the pixel value used to be spliced ​​to the sub-pixel value corresponding to the target color channel, and the pixel value of the number of bits corresponding to the target color channel is changed. The fill pixel value corresponding to one or more or each of the remaining color channels refers to the pixel value used to be spliced ​​to the sub-pixel value corresponding to one or more or each of the remaining color channels, and the pixel value of the number of bits corresponding to one or more or each of the remaining color channels is changed. It should be noted that the sub-pixel value and the fill pixel value in this application are both binary numbers.

[0106] Step 602 may be implemented in the following ways:

[0107] The first method is to obtain, for each pixel value, the value of the first target bit in the sub-pixel value corresponding to the target color channel, and use the value of the first target bit as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels; then use the preset value as the value of each bit in the filling pixel value corresponding to the target color channel, and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels; use the value of the second target bit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels as one or more or each corresponding filling pixel value in the remaining color channels; splice the sub-pixel values ​​corresponding to each color channel and the filling pixel values ​​corresponding to each color channel to obtain the target sub-pixel values ​​corresponding to each color channel.

[0108] The preset value is 0 or 1; the first target bit is the lowest bit in the sub-pixel value corresponding to the target color channel, that is, the first bit, that is, the bit numbered 0. The second target bit is the highest bit in one or more or each corresponding filling pixel value in the remaining color channels, such as the third bit, that is, the bit numbered 2, and the remaining bits can be the second bit and the first bit, that is, the bit numbered 1 and the bit numbered 0, respectively.

[0109] Taking the acquired image data as 127 grayscale compressed from RGB888 to RGB565 as an example, the target color channel is the G channel, and one or more or each of the remaining color channels is one or more or each of the R channel and the B channel. The values ​​of the 6 bits numbered 5 to 0 of the sub-pixel value corresponding to the G channel as the target color channel are 011111 in sequence, the values ​​of the 5 bits numbered 4 to 0 of the sub-pixel value corresponding to the R channel are 01111 in sequence, and the values ​​of the 5 bits numbered 4 to 0 of the sub-pixel value corresponding to the B channel are 01111 in sequence, and the preset value may be 0. Among them, the value of the bit numbered 0 corresponding to the lowest bit as the first target bit in the sub-pixel value corresponding to the G channel as the target color channel is 1.

[0110] The 2 bits in the fill pixel value corresponding to the G channel as the target color channel are the bits corresponding to number 1-0 from high to low. The 3 bits in the fill pixel value corresponding to the R channel are the bits corresponding to number 2-0 from high to low. The 3 bits in the fill pixel value corresponding to the B channel are the bits corresponding to number 2-0 from high to low.

[0111] The preset value is used as the value of each bit in the filling pixel value corresponding to the target color channel. Therefore, the values ​​of the two bits numbered 1 to 0 of the filling pixel value corresponding to the G channel as the target color channel are 00 respectively. The value of the first target bit is used as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels. The value of the bit numbered 0 corresponding to the lowest bit as the first target bit in the sub-pixel value corresponding to the G channel as the target color channel is 1. Therefore, the value of the bit numbered 2 corresponding to the highest bit as the second target bit in the filling pixel value corresponding to the R channel is 1, and the value of the bit numbered 2 corresponding to the highest bit as the second target bit in the filling pixel value corresponding to the B channel is 1.

[0112] The preset value is used as the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels. Therefore, the values ​​of the remaining bits in the filling pixel value corresponding to the R channel are 0 and 0 respectively, and the values ​​of the remaining bits in the filling pixel value corresponding to the B channel are 0 and 0 respectively.

[0113] The value of the second target bit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are used as one or more or each corresponding filling pixel value in the remaining color channels. Therefore, the filling pixel value corresponding to the R channel is 100, and the filling pixel value corresponding to the B channel is 100.

[0114] The sub-pixel values ​​corresponding to each color channel and the filling pixel values ​​corresponding to each color channel are spliced ​​to obtain the target sub-pixel values ​​corresponding to each color channel. Therefore, for the G channel, the sub-pixel value corresponding to the G channel is spliced ​​with the filling pixel value corresponding to the G channel, that is, 011111 and 00 are spliced ​​to obtain the target sub-pixel value corresponding to the G channel 01111100. For the R channel, the sub-pixel value corresponding to the R channel is spliced ​​with the filling pixel value corresponding to the R channel, that is, 01111 and 100 are spliced ​​to obtain the target sub-pixel value corresponding to the R channel 01111100. For the B channel, the sub-pixel value corresponding to the B channel is spliced ​​with the filling pixel value corresponding to the B channel, that is, 01111 and 100 are spliced ​​to obtain the target sub-pixel value corresponding to the B channel 01111100.

[0115] The second method is to obtain, for each pixel value, the value of the first target bit in the sub-pixel value corresponding to the target color channel, and use the value of the first target bit as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels; then use the preset value as the initial value of each bit in the filling pixel value corresponding to the target color channel, and use the preset value as the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels; take the pixel values ​​of the preset number of pixel points as an array unit, and for each array unit, determine the value of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels based on the i-th element in the compensation matrix; use the value of the second target bit and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels as one or more or each corresponding filling pixel value in the remaining color channels; splice the sub-pixel values ​​corresponding to each color channel and the filling pixel value corresponding to each color channel to obtain the target sub-pixel value corresponding to each color channel.

[0116] The preset value is 0 or 1; the first target bit is the lowest bit in the sub-pixel value corresponding to the target color channel, that is, the first bit, that is, the bit numbered 0. The second target bit is the highest bit in one or more or each corresponding filling pixel value in the remaining color channels, such as the third bit, that is, the bit numbered 2, and the remaining bits can be the second bit and the first bit, that is, the bit numbered 1 and the bit numbered 0, respectively.

[0117] Taking the acquired image data as 127 grayscale compressed from RGB888 to RGB565 as an example, the target color channel is the G channel, and one or more or each of the remaining color channels is one or more or each of the R channel and the B channel. The values ​​of the 6 bits numbered 5 to 0 of the sub-pixel value corresponding to the G channel as the target color channel are 011111 in sequence, the values ​​of the 5 bits numbered 4 to 0 of the sub-pixel value corresponding to the R channel are 01111 in sequence, and the values ​​of the 5 bits numbered 4 to 0 of the sub-pixel value corresponding to the B channel are 01111 in sequence. The preset value can be 0, the preset number can be 4, and the binary form of the compensation matrix can be:

[0118]

[0119] Among them, 01 in the 1st row and 1st column of the compensation matrix is ​​the 1st element, 10 in the 1st row and 2nd column of the compensation matrix is ​​the 2nd element, 10 in the 2nd row and 1st column of the compensation matrix is ​​the 3rd element, and 01 in the 2nd row and 2nd column of the compensation matrix is ​​the 4th element.

[0120] The value of the bit numbered 0 corresponding to the lowest bit as the first target bit in the sub-pixel value corresponding to the G channel as the target color channel is 1, and the value of the first target bit is used as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels. Therefore, the second target bit in the filling pixel value corresponding to the R channel is 1, and the second target bit in the filling pixel value corresponding to the B channel is 1.

[0121] The preset value is used as the initial value of each bit in the filling pixel value corresponding to the target color channel, and the preset value is used as the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels. Therefore, the initial values ​​of each bit in the filling pixel value corresponding to the G channel are 0 and 0 respectively, the initial values ​​of the remaining bits in the filling pixel value corresponding to the R channel are 0 and 0 respectively, and the initial values ​​of the remaining bits in the filling pixel value corresponding to the B channel are 0 and 0 respectively.

[0122] The pixel values ​​of 4 pixels are taken as one array unit. For each array unit, based on the i-th element in the compensation matrix, the values ​​of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are determined. Therefore, in each array unit:

[0123] For the first pixel value, the values ​​of each bit in the filling pixel value corresponding to the G channel are 0 and 1 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the G channel are 0 and 1 respectively; the values ​​of the remaining bits in the filling pixel value corresponding to the R channel are 0 and 1 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the R channel are 0 and 1 respectively; the values ​​of the remaining bits in the filling pixel value corresponding to the B channel are 0 and 1 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the B channel are 0 and 1 respectively.

[0124] For the second pixel value, the values ​​of each bit in the filling pixel value corresponding to the G channel are 1 and 0 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the G channel are 1 and 0 respectively; the values ​​of the remaining bits in the filling pixel value corresponding to the R channel are 1 and 0 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the R channel are 1 and 0 respectively; the values ​​of the remaining bits in the filling pixel value corresponding to the B channel are 1 and 0 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the B channel are 1 and 0 respectively.

[0125] For the third pixel value, the values ​​of each bit in the filling pixel value corresponding to the G channel are 1 and 0 respectively; that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the G channel are 1 and 0 respectively, and the values ​​of the remaining bits in the filling pixel value corresponding to the R channel are 1 and 0 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the R channel are 1 and 0 respectively; the values ​​of the remaining bits in the filling pixel value corresponding to the B channel are 1 and 0 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the B channel are 1 and 0 respectively.

[0126] For the 4th pixel value, the values ​​of each bit in the filling pixel value corresponding to the G channel are 0 and 1 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the G channel are 0 and 1 respectively; the values ​​of the remaining bits in the filling pixel value corresponding to the R channel are 0 and 1 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the R channel are 0 and 1 respectively; the values ​​of the remaining bits in the filling pixel value corresponding to the B channel are 0 and 1 respectively, that is, the values ​​of the bits numbered 1-0 from high to low in the filling pixel value corresponding to the B channel are 0 and 1 respectively.

[0127] The value of the second target bit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are used as one or more or each corresponding filling pixel value in the remaining color channels. Therefore, for the first pixel value, the filling pixel value corresponding to the G channel is 01, the filling pixel value corresponding to the R channel is 101, and the filling pixel value corresponding to the B channel is 101; for the second pixel value, the filling pixel value corresponding to the G channel is 10, the filling pixel value corresponding to the R channel is 110, and the filling pixel value corresponding to the B channel is 110; for the third pixel value, the filling pixel value corresponding to the G channel is 10, the filling pixel value corresponding to the R channel is 110, and the filling pixel value corresponding to the B channel is 110; for the fourth pixel value, the filling pixel value corresponding to the G channel is 01, the filling pixel value corresponding to the R channel is 101, and the filling pixel value corresponding to the B channel is 101.

[0128] The sub-pixel values ​​corresponding to each color channel and the filling pixel values ​​corresponding to each color channel are spliced ​​to obtain the target sub-pixel values ​​corresponding to each color channel. Therefore, for the first pixel value, the target sub-pixel value corresponding to the G channel is 01111101, the target sub-pixel value corresponding to the R channel is 01111101, and the target sub-pixel value corresponding to the B channel is 01111101; for the second pixel value, the target sub-pixel value corresponding to the G channel is 01111110, and the target sub-pixel value corresponding to the R channel is 011111 10, the target sub-pixel value corresponding to the B channel is 01111110; for the third pixel value, the target sub-pixel value corresponding to the G channel is 01111110, the target sub-pixel value corresponding to the R channel is 01111110, and the target sub-pixel value corresponding to the B channel is 01111110; for the fourth pixel value, the target sub-pixel value corresponding to the G channel is 01111101, the target sub-pixel value corresponding to the R channel is 01111101, and the target sub-pixel value corresponding to the B channel is 01111101.

[0129] The third method is to take the pixel values ​​of a preset number of pixel points as an array unit, and for each array unit, determine the value of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels based on the i-th element in the compensation matrix; use the value of the second target bit and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels as one or more or each corresponding filling pixel value in the remaining color channels; and splice the sub-pixel values ​​corresponding to each color channel and the filling pixel values ​​corresponding to each color channel to obtain the target sub-pixel values ​​corresponding to each color channel.

[0130] This is equivalent to not first using the preset value as the initial value of each bit in the filling pixel value corresponding to the target color channel, and using the preset value as the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels, but directly executing the step of "taking the pixel values ​​of the preset number of said pixels as an array unit, for each array unit, based on the i-th element in the compensation matrix, determining the value of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels; using the value of the second target bit and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels as one or more or each corresponding filling pixel value in the remaining color channels; splicing the sub-pixel values ​​corresponding to each color channel and the filling pixel values ​​corresponding to each color channel to obtain the target sub-pixel value corresponding to each color channel".

[0131] Step 603: Use the target sub-pixel values ​​corresponding to the color channels of the plurality of pixel points as the image data after decompressing the image data.

[0132] Taking the first implementation in step 602 as an example, the pixel value of each pixel in the decompressed image data is: R / G / B is 01111100 / 01111100 / 01111100, which is 124 / 124 / 124 in decimal. It can be seen that the pixel value of each pixel in the decompressed image data of the present application is 3 times the original grayscale RGB888: 127 / 127 / 127. Therefore, compared with the direct 0 or 1 filling method in the related art, the present application can reduce the grayscale deviation value and make the proportions of R, G, and B the same, solving the problems of excessive grayscale unevenness and grayscale color cast.

[0133] Taking the second and third implementations in step 602 as an example, the pixel values ​​in each array unit in the decompressed image data are: the first pixel value, R / G / B is 01111101 / 01111101 / 01111101, which is 125 / 125 / 125 in decimal; the second pixel value, R / G / B is 01111110 / 01111110 / 0111 1110, decimal is 126 / 126 / 126; the third pixel value, R / G / B is 01111110 / 01111110 / 01111110, decimal is 126 / 126 / 126; the fourth pixel value, R / G / B is 01111101 / 01111101 / 01111101, decimal is 125 / 125 / 125. It can be seen that the pixel average value of each array unit in the image data after decompression processing of the present application is 125.5, compared with the original grayscale RGB888: 127 / 127 / 127, the maximum deviation is 1.5. Therefore, compared with the method of directly filling 0 or 1 in the related art, the present application can reduce the grayscale deviation value, and can make the proportions of R, G, and B the same, solving the problems of excessive grayscale unevenness and grayscale color cast.

[0134] The above-mentioned image data conversion method obtains image data, the image data includes pixel values ​​of each pixel in the target image, and the pixel values ​​include sub-pixel values ​​corresponding to multiple color channels respectively. Then, for each pixel value, the filling pixel value corresponding to the target color channel in the multiple color channels is determined, and based on the sub-pixel value corresponding to the target color channel, one or more or each corresponding filling pixel value in the remaining color channels is determined, so that the distortion of one or more or each corresponding filling pixel value in the remaining color channels can be reduced. Then, based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel, the target sub-pixel value corresponding to each color channel is obtained, and the target sub-pixel value corresponding to each color channel of the multiple pixel points is used as the image data after the image data is decompressed. In this way, since the distortion of one or more or each corresponding filling pixel value in the remaining color channels is reduced, the distortion of one or more or each corresponding target sub-pixel value in the remaining color channels can be reduced, that is, the grayscale deviation value before compression and after decompression and restoration is reduced, thereby improving the performance of the display product.

[0135] In addition, since the fill pixel values ​​of one or more or each corresponding to the remaining color channels are determined by the sub-pixel value corresponding to the target color channel, the fill pixel values ​​corresponding to each color channel will be the same, and thus the target sub-pixel values ​​corresponding to each color channel will be the same, thereby solving the problems of excessive grayscale unevenness and grayscale color cast.

[0136] In an exemplary embodiment, a fill pixel value corresponding to a target color channel among multiple color channels is determined, and based on the sub-pixel value corresponding to the target color channel, one or more or each corresponding fill pixel value in the remaining color channels is determined, including: obtaining the value of a first target bit in the sub-pixel value corresponding to the target color channel; determining the fill pixel value corresponding to the target color channel, and determining one or more or each corresponding fill pixel value in the remaining color channels based on the value of the first target bit.

[0137] Optionally, obtaining the value of the first target bit in the sub-pixel value corresponding to the target color channel may be obtaining the value of the lowest bit in the sub-pixel value corresponding to the target color channel.

[0138] For example, if the sub-pixel value corresponding to the target color channel is 011111, the value of the first target bit is the value of the lowest bit in 011111, in other words, the end value of 011111, that is, 1.

[0139] The fill pixel value corresponding to the target color channel may be determined by using a preset value as the value of each bit in the fill pixel value corresponding to the target color channel, or by using a compensation matrix to determine the fill pixel value corresponding to the target color channel.

[0140] The value of one or more or each corresponding filling pixel in the remaining color channels is determined based on the value of the first target bit. The value of the second target bit in one or more or each corresponding filling pixel in the remaining color channels can be determined based on the value of the first target bit; and the preset value is used as the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels. Alternatively, a compensation matrix is ​​used to determine the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels.

[0141] In this embodiment, by determining the value of the first target bit in the sub-pixel value corresponding to the target color channel, one or more or each corresponding filling pixel value in the remaining color channels can reduce the distortion of one or more or each corresponding filling pixel value in the remaining color channels.

[0142] In an exemplary embodiment, Figure 7 As shown, another image data conversion method is provided, determining a fill pixel value corresponding to a target color channel, and determining one or more or each corresponding fill pixel value in the remaining color channels based on the value of a first target bit, including:

[0143] Step 701: Use the value of the first target bit as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels.

[0144] Step 702, determining the fill pixel value corresponding to the target color channel, and determining the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels.

[0145] The second target bit is the highest bit in one or more or each corresponding filling pixel value in the remaining color channels. For example, when the image data is in RGB565 format, the second target bit can be the third bit, that is, the bit numbered 2, and the remaining bits can be the second bit and the first bit, that is, the bit numbered 1 and the bit numbered 0; when the image data is in RGB454 format, the second target bit can be the fourth bit, that is, the bit numbered 3, and the remaining bits can be the third bit, the second bit and the first bit, that is, the bit numbered 2, the bit numbered 1 and the bit numbered 0.

[0146] The value of the first target bit is used as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels. For example, for grayscale 127, in each pixel value in the image data received by the terminal, the sub-pixel value corresponding to the G channel is 011111, and the value of the first target bit is 1. Therefore, the value of the second target bit in the filling pixel value corresponding to the R channel is 1, and the value of the second target bit in the filling pixel value corresponding to the B channel is 1. For example, for grayscale 120, in each pixel value in the image data received by the terminal, the sub-pixel value corresponding to the G channel is 011110, and the value of the first target bit is 0. Therefore, the value of the second target bit in the filling pixel value corresponding to the R channel is 0, and the value of the second target bit in the filling pixel value corresponding to the B channel is 0.

[0147] Optionally, determining the fill pixel value corresponding to the target color channel, and determining the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels, includes the following implementations:

[0148] In a possible implementation, a preset value is used as the value of each bit in the filling pixel value corresponding to the target color channel, and the value of each remaining bit in the filling pixel value corresponding to one or more or each of the remaining color channels. The preset value is 0 or 1.

[0149] In another possible implementation, the compensation matrix is ​​used to determine the value of each bit in the filling pixel value corresponding to the target color channel and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels.

[0150] Step 703: Use the value of the second target bit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels as one or more or each corresponding filling pixel value in the remaining color channels.

[0151] Optionally, the value of the second target bit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are concatenated to obtain one or more or each corresponding filling pixel value in the remaining color channels.

[0152] In this embodiment, by using the value of the first target bit in the sub-pixel value corresponding to the target color channel as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels, the distortion on the second target bit in one or more or each corresponding filling pixel value in the remaining color channels can be reduced, thereby reducing the distortion of one or more or each corresponding filling pixel value in the remaining color channels.

[0153] In an exemplary embodiment, determining a fill pixel value corresponding to a target color channel and determining values ​​of remaining bits in one or more or each corresponding fill pixel value in remaining color channels includes:

[0154] The preset value is used as the initial value of each bit in the filling pixel value corresponding to the target color channel, and the preset value is used as the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels. The initial value of each bit in the filling pixel value corresponding to the target color channel and the initial value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels are compensated to obtain the value of each bit in the filling pixel value corresponding to the target color channel and the value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels.

[0155] Optionally, the pixel values ​​of a preset number of pixels are taken as an array unit. For each array unit, based on the i-th element in the compensation matrix, the values ​​of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are determined, where i is an integer greater than or equal to 1.

[0156] The compensation matrix includes at least two filling values, and at least two filling values ​​in the compensation matrix are different.

[0157] Optionally, the average value of all the filling values ​​in the compensation matrix is ​​equal to the average value of the maximum value and the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel. Compared with the method in which all the filling values ​​in the compensation matrix are equal to the maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, or all the filling values ​​in the compensation matrix are equal to the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, this embodiment can reduce the grayscale deviation value before compression and after decompression and restoration, and reduce the distortion of one or more or each corresponding target sub-pixel value in the remaining color channels. For example, at least two filling values ​​in the compensation matrix include 2 and 1, or at least two filling values ​​in the compensation matrix include 3 and 0, and the average value is 1.5.

[0158] Optionally, at least two filling values ​​in the compensation matrix are greater than or equal to the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel (for example, the number of bits of the filling pixel value of the G channel as the target color channel is 2, and the corresponding maximum value is 0), and less than or equal to the maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel (for example, the number of bits of the filling pixel value of the G channel as the target color channel is 2, and the corresponding maximum value is 3).

[0159] Optionally, at least one filling value in the compensation matrix is ​​greater than the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and is less than the maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel. In this embodiment, the intermediate value is used as the filling value, which can reduce the grayscale deviation value before compression and after decompression and restoration, and reduce the distortion of one or more or each corresponding target sub-pixel value in the remaining color channels. For example, at least one filling value in the compensation matrix includes 2 or 1, which is between 3 and 0.

[0160] Optionally, at least two filling values ​​in the compensation matrix are smaller than the maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and larger than the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel. In this embodiment, the intermediate value is used as the filling value, which can reduce the grayscale deviation value before compression and after decompression and restoration, and reduce the distortion of one or more or each corresponding target sub-pixel value in the remaining color channels. For example, the at least two filling values ​​in the compensation matrix include 2 and 1, which are between 3 and 0.

[0161] Optionally, at least one filling value in the compensation matrix is ​​greater than the average of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and at least one filling value in the compensation matrix is ​​less than the average of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel value corresponding to the target color channel. For example, at least two filling values ​​in the compensation matrix include 2 and 1, and the average value is 1.5.

[0162] Optionally, the average value of all fill values ​​in the compensation matrix is ​​a middle value determined according to the deviation range.

[0163] There are many ways to determine the deviation range.

[0164] In one implementation method for determining a deviation range, the deviation range is obtained by taking a preset value as the value of each bit in the fill pixel value corresponding to the target color channel and the value of each remaining bit in one or more or each corresponding fill pixel value in the remaining color channels, and the difference between the target sub-pixel value corresponding to each color channel and the sub-pixel value corresponding to each color channel before the pixel value is compressed.

[0165] The pixel values ​​before compression refer to the pixel values ​​in the image data before compression, that is, the pixel values ​​in the initial image data mentioned above. For example, the pixel values ​​before compression are 127 / 127 / 127.

[0166] In other words, this implementation method is to obtain the target sub-pixel value corresponding to each color channel according to the first implementation method in the above step 602, and then subtract the sub-pixel value corresponding to each color channel before the pixel value is compressed from it to obtain a deviation range.

[0167] For example, for the pixel value 15 / 31 / 15 in the image data in RGB565 format, according to the first implementation in the above step 602, the target sub-pixel value corresponding to each color channel is 124, and the difference between 124 / 124 / 124 and 127 / 127 / 127 is 3, so the deviation range is 0 to 3, and the deviation range is 0 to 3, and its value is 0, 1, 2, 3, and the middle value is 1.5. Of course, for other pixel values, other deviation ranges can be calculated. For example, when according to the first implementation in the above step 602, the difference between the target sub-pixel value corresponding to each color channel and the sub-pixel value corresponding to each color channel before the pixel value is compressed is 2, then the deviation range is 0 to 2, and the deviation range is 0 to 2, and its value is 0, 1, 2, and the middle value is 1.

[0168] This implementation method can achieve different deviation ranges for different pixel values. Since the compensation matrix is ​​determined according to the deviation range, different compensation matrices can be selected for different pixel values.

[0169] In another implementation method for determining the deviation range, the deviation range is for multiple different pixel values, and the steps of using preset values ​​as the values ​​of each bit in the filling pixel value corresponding to the target color channel, and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are executed to obtain target sub-pixel values ​​corresponding to each color channel of multiple different pixel values, and subtracting the target sub-pixel values ​​corresponding to each color channel of each pixel value from the sub-pixel values ​​corresponding to each color channel before the pixel values ​​are compressed to obtain difference values ​​corresponding to multiple different pixel values, which are obtained based on the maximum value of the multiple difference values.

[0170] Among them, a plurality of different pixel values, such as pixel values ​​15 / 31 / 15 and pixel values ​​15 / 30 / 15, respectively correspond to pixel values ​​before being compressed of 127 / 127 / 127 and 120 / 120 / 120.

[0171] In other words, this implementation method is to obtain the target sub-pixel value corresponding to each color channel according to the second or third implementation method in the above step 602, and then subtract the sub-pixel value corresponding to each color channel before the pixel value is compressed from it to obtain a deviation range.

[0172] For example, for the pixel value 15 / 31 / 15, according to the second or third implementation in the above step 602, the target sub-pixel value corresponding to each color channel is 124, and the difference between 124 / 124 / 124 and 127 / 127 / 127 before compression is 3. For the pixel value 15 / 30 / 15, according to the second or third implementation in the above step 602, the target sub-pixel value corresponding to each color channel is 120, and the difference between 120 / 120 / 120 and 120 / 120 / 120 before compression is 0. Therefore, the deviation range is 0 to 3, and the deviation range is 0 to 3, and its values ​​are 0, 1, 2, 3, and the middle value is 1.5.

[0173] This implementation method uses a plurality of different pixel values ​​to obtain a deviation range. Since the compensation matrix is ​​determined according to the deviation range, the same compensation matrix can be selected for different pixel values.

[0174] In the array unit, the number of pixels is the same as the number of elements in the compensation matrix. The number of bits of each element in the compensation matrix is ​​the same as the number of bits of the filling pixel value of the target color channel in the pixel value, and is the same as the number of remaining bits in one or more or each corresponding filling pixel value in the remaining color channels in the pixel value except the second target bit.

[0175] And / or, in the pixel array corresponding to the target image, the average value of the filling pixel values ​​corresponding to the target color channels of all pixels is equal to the average value of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels.

[0176] And / or, in the pixel point array corresponding to the target image, one of the filling pixel values ​​corresponding to the target color channels of two adjacent pixels along the row direction X is greater than the average value, and the other is less than the average value; one of the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels of the two adjacent pixels along the row direction X is greater than the average value, and the other is less than the average value; the average value is equal to the average value of the maximum and minimum values ​​corresponding to the bit number of the filling pixel value corresponding to the target color channel.

[0177] For example, adjacent filling values ​​along the row direction X in the compensation matrix are different, and / or adjacent filling values ​​along the column direction Y in the compensation matrix are different, and the row direction and the column direction intersect, for example, vertically, such as Fig.10 As shown. It is equivalent to reducing grayscale deviation based on the spatial dithering method. For example, at least two filling values ​​in the compensation matrix are arranged alternately along the row direction X. For example, at least two filling values ​​in the compensation matrix are arranged alternately along the column direction Y. For example, at least two filling values ​​in the compensation matrix are arranged alternately and cyclically along the row direction X. For example, at least two filling values ​​in the compensation matrix are arranged alternately and cyclically along the column direction Y.

[0178] And / or, adjacent filling values ​​along the first diagonal direction U in the compensation matrix are the same, and / or, adjacent filling values ​​along the second diagonal direction V in the compensation matrix are the same, the first diagonal direction intersects with the row direction, the first diagonal direction intersects with the column direction, the second diagonal direction intersects with the row direction, the second diagonal direction intersects with the column direction, and the first diagonal direction U intersects with the second diagonal direction V, for example, vertically.

[0179] Correspondingly, based on the characteristics of the above compensation matrix, the pixel array corresponding to the target image has the following characteristics.

[0180] For example, in the pixel array corresponding to the target image, the target color channels of at least two pixels have different filling pixel values, and one or more or each of the remaining color channels of at least two pixels have different filling pixel values. For example, the G channels of at least two pixels have different filling pixel values. For example, the R channels of at least two pixels have different filling pixel values. For example, the B channels of at least two pixels have different filling pixel values.

[0181] Optionally, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixels are greater than or equal to the minimum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels, and are less than or equal to the maximum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels.

[0182] Optionally, in the pixel point array corresponding to the target image, the filling pixel value corresponding to the target color channel of at least one pixel point is greater than the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and is less than the maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel.

[0183] Optionally, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixels are smaller than the maximum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels, and are larger than the minimum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels.

[0184] Optionally, in the pixel point array corresponding to the target image, the filling pixel value corresponding to the target color channel of at least one pixel point is greater than the average of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and the filling pixel value corresponding to the target color channel of at least one pixel point is less than the average of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel value corresponding to the target color channel.

[0185] Optionally, in the pixel array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of all pixels are equal to the average of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels.

[0186] Optionally, in the pixel array corresponding to the target image, the target color channels of two adjacent pixels along the row direction X have different filling pixel values. The values ​​of the remaining bits in one or more or each corresponding filling pixel values ​​in the remaining color channels of the two adjacent pixels along the row direction X are different, that is, in the two adjacent pixels along the row direction, the values ​​of the remaining bits in one or more or each corresponding filling pixel values ​​in the remaining color channels of one pixel are different from the values ​​of the remaining bits in one or more or each corresponding filling pixel values ​​in the remaining color channels of the other pixel. For example, in the pixel array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels corresponding to each row of pixels include at least two types, and the at least two filling pixel values ​​are arranged alternately along the row direction X. For example, in the pixel array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels corresponding to each row of pixels include at least two types, and the at least two filling pixel values ​​are arranged alternately along the row direction X.

[0187] And / or, in the pixel array corresponding to the target image, the average value of the filling pixel values ​​corresponding to the target color channels of all the pixels is the middle value determined according to the deviation range.

[0188] And / or, in the pixel array corresponding to the target image, the target color channels of two adjacent pixels along the column direction Y have different filling pixel values. The values ​​of the remaining bits in one or more or each corresponding filling pixel values ​​in the remaining color channels of two adjacent pixels along the column direction Y are different, that is, in the two adjacent pixels along the column direction, the values ​​of the remaining bits in one or more or each corresponding filling pixel values ​​in the remaining color channels of one pixel are different from the values ​​of the remaining bits in one or more or each corresponding filling pixel values ​​in the remaining color channels of the other pixel. For example, in the pixel array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels corresponding to each column of pixels include at least two types, and the at least two filling pixel values ​​are arranged alternately along the column direction Y. For example, in the pixel array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels corresponding to each column of pixels include at least two types, and the at least two filling pixel values ​​are arranged alternately along the column direction Y.

[0189] And / or, for the same pixel point, the filling pixel value corresponding to the target color channel is the same as the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels.

[0190] And / or, among the four pixels located in two adjacent rows and two columns, the target color channels of two pixels located in different rows and columns have the same filling pixel values, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels are the same; and the target color channels of another two pixels located in different rows and columns have the same filling pixel values, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels are the same.

[0191] For example, when the image data is in RGB565 format, the number of pixels in the array unit is 4, the deviation range is 0 to 3, and the median value is 1.5, the binary form of the compensation matrix can be:

[0192]

[0193] The decimal form of the compensation matrix is:

[0194]

[0195] Specifically, for each array unit, based on the i-th element in the compensation matrix, the initial value of each bit in the filling pixel value corresponding to the target color channel is replaced, and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are replaced.

[0196] For example, for 127 grayscales, after the terminal uses the value of the first target bit as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels, uses 0 as the initial value of each bit in the filling pixel value corresponding to the target color channel, and uses 0 as the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels, the binary form of R / G / B is 01111100 / 01111100 / 01111100, and the decimal form is 124 / 124 / 124. Fig.10 The fill value is in decimal.

[0197] Taking the first compensation matrix as an example, after the terminal performs the above compensation processing, in the array unit, the first pixel value, the binary form of R / G / B is 01111101 / 01111101 / 01111101, which is 125 / 125 / 125 in decimal; the second pixel value, the binary form of R / G / B is 01111110 / 01111110 / 01111110, which is 125 / 125 / 125 in decimal. The binary form of the third pixel value, R / G / B is 01111110 / 01111110 / 01111110, which is 126 / 126 / 126 in decimal. The binary form of the fourth pixel value, R / G / B is 01111101 / 01111101 / 01111101, which is 125 / 125 / 125 in decimal. In other words, after the compensation process, at least some of the pixel values ​​in the array unit are Therefore, the pixel value in the array unit can be equivalent to 125.5, and the deviation from the grayscale of 127 is -1.5, as shown in Table 3. Based on this, the array of multiple pixel points in the decompressed target image is as follows Figure 8 As shown, for example, an array of target sub-pixel values ​​corresponding to one of the color channels in the pixel array, such as an array of target sub-pixel values ​​corresponding to the target color channel in the pixel array, may also be an array of target sub-pixel values ​​corresponding to the remaining color channels. The array of target sub-pixel values ​​corresponding to the target color channel in the pixel array is the same as the array of target sub-pixel values ​​corresponding to one or more or each of the remaining color channels. Figure 8 The target sub-pixel value in decimal.

[0198] For example, for 120 grayscales, after the terminal uses the value of the first target bit as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels, uses 0 as the initial value of each bit in the filling pixel value corresponding to the target color channel, and uses 0 as the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels, the binary form of R / G / B is 01111000 / 01111000 / 01111000, and the decimal form is 120 / 120 / 120.

[0199] Taking the first compensation matrix as an example, after the terminal performs the above compensation processing, in the array unit, the first pixel value, the binary form of R / G / B is 01111001 / 01111001 / 01111001, which is 121 / 121 / 121 in decimal; the second pixel value, the binary form of R / G / B is 01111010 / 01111010 / 01111010, 1 The binary form of the third pixel value, R / G / B is 01111010 / 01111010 / 01111010, which is 122 / 122 / 122 in decimal; the binary form of the fourth pixel value, R / G / B is 01111001 / 01111001 / 01111001, which is 121 / 121 / 121 in decimal. In other words, after the compensation process, at least some of the pixel values ​​in the array unit are Therefore, the pixel value in the array unit can be equivalent to 121.5, and the deviation from the grayscale of 120 is 1.5, as shown in Table 4. Based on this, the array of multiple pixel points in the decompressed target image is as follows Fig. 9 As shown, for example, an array of target sub-pixel values ​​corresponding to one color channel in the pixel array, for example, an array of target sub-pixel values ​​corresponding to the target color channel in the pixel array, may also be an array of target sub-pixel values ​​corresponding to the remaining color channels. Fig. 9 The target sub-pixel value in decimal.

[0200] Table 3

[0201]

[0202] Table 4

[0203]

[0204]

[0205] It should be noted that when RGB565 in Table 3 and Table 4 is restored to RGB888, the preset value is 0, but 1 can also be used. In short, no matter whether 1 or 0 is used, it will eventually be compensated by the compensation matrix, that is, it will be replaced by the value in the compensation matrix. Therefore, the preset value will not affect the final target sub-pixel value.

[0206] In this embodiment, the filling pixel value of each color channel corresponding to each pixel value in the array unit is determined by a compensation matrix, so that the purpose of further reducing the grayscale deviation is achieved by means of spatial dithering.

[0207] In an exemplary embodiment, determining a fill pixel value corresponding to a target color channel and determining values ​​of remaining bits in one or more or each corresponding fill pixel value in remaining color channels includes:

[0208] The pixel values ​​of a preset number of pixels are taken as an array unit. For each array unit, based on the i-th element in the compensation matrix, the values ​​of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are determined.

[0209] The implementation of this embodiment does not need to use the preset value as the initial value of each color channel first, and the rest is the same as the above-mentioned embodiment of "determining the fill pixel value corresponding to the target color channel, and determining the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels". Therefore, the implementation of this embodiment can refer to the above, and will not be repeated here.

[0210] In an exemplary embodiment, based on the sub-pixel values ​​corresponding to each color channel and the filling pixel values ​​corresponding to each color channel, the target sub-pixel values ​​corresponding to each color channel are obtained, including: for each color channel, the value of each bit in the sub-pixel value corresponding to the color channel is concatenated with the value of each bit in the filling pixel value corresponding to the color channel to obtain the target sub-pixel value corresponding to the color channel.

[0211] Optionally, the value of each bit in the sub-pixel value corresponding to the color channel and the value of each bit in the filling pixel value corresponding to the color channel are concatenated, and in the concatenation process, for each color channel, each bit in the sub-pixel value is higher than each bit in the filling pixel value. That is, for each color channel, the lowest bit in each bit in the sub-pixel value is higher than the highest bit in each bit in the filling pixel value.

[0212] In addition, it should be noted that, for each color channel, the number of bits of the filling pixel value is greater than or equal to M, where M is 1, 2, or 3. For example, for the image data in RGB565 format, the number of bits of the filling pixel value corresponding to the target color channel is 2, and the number of bits of the filling pixel value corresponding to one or more or each of the remaining color channels is 3.

[0213] In this embodiment, the method of obtaining the target sub-pixel value by splicing the sub-pixel value and the filling pixel value is simple and easy to implement.

[0214] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0215] Based on the same inventive concept, the embodiment of the present application also provides an image data conversion method. The method comprises:

[0216] Acquire image data, the image data including pixel values ​​of each pixel in the target image, the pixel values ​​including sub-pixel values ​​corresponding to multiple color channels respectively;

[0217] For each pixel value, a filling pixel value corresponding to a target color channel among multiple color channels is determined, and one or more or each corresponding filling pixel value in the remaining color channels is determined, and a target sub-pixel value corresponding to each color channel is obtained based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel; the number of bits of the filling pixel value corresponding to the target color channel is different from the number of bits of the filling pixel value corresponding to one or more or each corresponding filling pixel value in the remaining color channels, and / or, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixels are different, and the filling pixel values ​​corresponding to one or more or each corresponding filling pixel value in the remaining color channels of at least two pixels are different.

[0218] The functions of the features that are the same or similar to those in the above embodiments are the same or similar, and are not described in detail here. The present embodiment can be combined with some or all of the features in the above embodiments, and are not described in detail here. The target sub-pixel values ​​corresponding to the color channels of the plurality of pixel points are used as the image data after the image data is decompressed.

[0219] Based on the same inventive concept, the embodiment of the present application also provides an image data conversion device for implementing the above-mentioned image data conversion method. The implementation solution provided by the device to solve the problem is similar to the implementation solution recorded in the above-mentioned method, so the specific limitations in one or more image data conversion device embodiments provided below can refer to the limitations of the image data conversion method above, and will not be repeated here.

[0220] In an exemplary embodiment, Fig.11 As shown, an image data conversion device is provided, which can be used to perform the above-mentioned image data conversion method. The image data conversion device 800 includes: an acquisition module 801, a first determination module 802 and a second determination module 803, wherein:

[0221] The acquisition module 801 is used to acquire image data, where the image data includes the pixel value of each pixel point in the target image, and the pixel value includes sub-pixel values ​​corresponding to multiple color channels.

[0222] The first determination module 802 is used to determine, for each pixel value, a fill pixel value corresponding to a target color channel among multiple color channels, and based on the sub-pixel value corresponding to the target color channel, determine one or more or each corresponding fill pixel value in the remaining color channels, and obtain the target sub-pixel value corresponding to each color channel based on the sub-pixel value corresponding to each color channel and the fill pixel value corresponding to each color channel.

[0223] The second determining module 803 is used to use the target sub-pixel value corresponding to each color channel of the plurality of pixel points as the image data after decompressing the image data.

[0224] In one embodiment, the number of bits of the sub-pixel value corresponding to the target color channel is greater than the number of bits of the sub-pixel value corresponding to one or more or each of the remaining color channels.

[0225] Optionally, the number of bits of the filling pixel value corresponding to the target color channel is smaller than the number of bits of the filling pixel value corresponding to one or more or each of the remaining color channels.

[0226] Optionally, the sum of the number of bits of the sub-pixel value and the filling pixel value corresponding to the target color channel is equal to the sum of the number of bits of the sub-pixel value and the filling pixel value corresponding to one or more or each of the remaining color channels.

[0227] Optionally, the number of bits of the sub-pixel value corresponding to the target color channel is N greater than the number of bits of one or more or each corresponding sub-pixel value in the remaining color channels, where N is an integer greater than or equal to 1.

[0228] In one embodiment, the first determination module 802 is specifically used to obtain the value of the first target bit in the sub-pixel value corresponding to the target color channel; determine the filling pixel value corresponding to the target color channel, and determine one or more or each corresponding filling pixel value in the remaining color channels based on the value of the first target bit.

[0229] Optionally, the first target bit is the lowest bit in the sub-pixel value corresponding to the target color channel.

[0230] In one embodiment, the first determination module 802 is specifically used to use the value of the first target bit as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels; determine the filling pixel value corresponding to the target color channel, and determine the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels; use the value of the second target bit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels as one or more or each corresponding filling pixel value in the remaining color channels.

[0231] Optionally, the second target bit is the highest bit in one or more or each corresponding filling pixel value in the remaining color channels.

[0232] In one embodiment, the first determination module 802 is specifically configured to use a preset value as the value of each bit in the filling pixel value corresponding to the target color channel, and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels.

[0233] In one embodiment, the first determination module 802 is specifically used to use the preset value as the initial value of each bit in the filling pixel value corresponding to the target color channel, and use the preset value as the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels; the initial value of each bit in the filling pixel value corresponding to the target color channel and the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are compensated to obtain the value of each bit in the filling pixel value corresponding to the target color channel and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels.

[0234] In one embodiment, the first determination module 802 is specifically used to take the pixel values ​​of a preset number of pixel points as an array unit, and for each array unit, based on the i-th element in the compensation matrix, determine the values ​​of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels.

[0235] Optionally, the compensation matrix comprises at least two filling values.

[0236] Optionally, at least two filling values ​​in the compensation matrix are greater than or equal to a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and less than or equal to a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel.

[0237] Optionally, at least one filling value in the compensation matrix is ​​greater than a minimum value corresponding to a number of bits of a filling pixel value corresponding to a target color channel, and is less than a maximum value corresponding to a number of bits of a filling pixel value corresponding to a target color channel.

[0238] Optionally, at least two filling values ​​in the compensation matrix are greater than a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; and are less than a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel.

[0239] Optionally, at least one filling value in the compensation matrix is ​​greater than the average of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and at least one filling value in the compensation matrix is ​​less than the average of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel value corresponding to the target color channel.

[0240] Optionally, the average value of all filling values ​​in the compensation matrix is ​​equal to the average value of the maximum value and the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel.

[0241] Optionally, the average value of all fill values ​​in the compensation matrix is ​​a middle value determined according to the deviation range.

[0242] Optionally, the deviation range is obtained by taking the preset value as the value of each bit in the fill pixel value corresponding to the target color channel and the value of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels, and the difference between the target sub-pixel value corresponding to each color channel and the sub-pixel value corresponding to each color channel before the pixel value is compressed.

[0243] Optionally, the deviation range is for multiple different pixel values, and the steps of using preset values ​​as the values ​​of each bit in the filling pixel value corresponding to the target color channel, and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are executed to obtain target sub-pixel values ​​corresponding to each color channel of multiple different pixel values, and subtracting the target sub-pixel values ​​corresponding to each color channel of each pixel value from the sub-pixel values ​​corresponding to each color channel before the pixel values ​​are compressed to obtain difference values ​​corresponding to multiple different pixel values, which are obtained based on the maximum value of the multiple difference values.

[0244] Adjacent filling values ​​along the row direction in the compensation matrix are different, and / or adjacent filling values ​​along the column direction in the compensation matrix are different, and the row direction and the column direction intersect;

[0245] And / or, adjacent filling values ​​along the first diagonal direction in the compensation matrix are the same, and / or, adjacent filling values ​​along the second diagonal direction in the compensation matrix are the same, the first diagonal direction intersects with the row direction, the first diagonal direction intersects with the column direction, the second diagonal direction intersects with the row direction, the second diagonal direction intersects with the column direction, and the first diagonal direction intersects with the second diagonal direction.

[0246] In one embodiment, the first determination module 802 is specifically used to take the pixel values ​​of a preset number of pixels as an array unit, and for each array unit, determine the value of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels based on the i-th element in the compensation matrix;

[0247] And / or, in the pixel array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of two adjacent pixel points along the row direction are different, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels of the two adjacent pixel points along the row direction are different; the row direction and the column direction intersect;

[0248] And / or, in the pixel point array corresponding to the target image, one of the filling pixel values ​​corresponding to the target color channel of two pixel points adjacent along the row direction is greater than the average value, and the other is less than the average value; one of the values ​​of the remaining bits of the filling pixel values ​​corresponding to one or more or each of the remaining color channels of the two pixel points adjacent along the row direction is greater than the average value, and the other is less than the average value; the average value is equal to the average value of the maximum value and the minimum value corresponding to the bit number of the filling pixel value corresponding to the target color channel;

[0249] And / or, in the pixel array corresponding to the target image, the average value of the filling pixel values ​​corresponding to the target color channels of all the pixels is the middle value determined according to the deviation range;

[0250] And / or, in the pixel array corresponding to the target image, the target color channels of two adjacent pixel points along the column direction have different filling pixel values ​​corresponding to them, and the values ​​of the remaining bits in one or more or each of the filling pixel values ​​corresponding to the remaining color channels of the two adjacent pixel points along the column direction are different;

[0251] And / or, for the same pixel, the filling pixel value corresponding to the target color channel is the same as the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels;

[0252] And / or, among the four pixels located in two adjacent rows and two columns, the target color channels of two pixels located in different rows and columns have the same filling pixel values, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels are the same; and the target color channels of another two pixels located in different rows and columns have the same filling pixel values, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels are the same.

[0253] Optionally, the deviation range is obtained by taking the preset value as the value of each bit in the fill pixel value corresponding to the target color channel and the value of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels, and the difference between the target sub-pixel value corresponding to each color channel and the sub-pixel value corresponding to each color channel before the pixel value is compressed.

[0254] Optionally, the deviation range is for multiple different pixel values, and the steps of using preset values ​​as the values ​​of each bit in the filling pixel value corresponding to the target color channel, and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels are executed to obtain target sub-pixel values ​​corresponding to each color channel of multiple different pixel values, and subtracting the target sub-pixel values ​​corresponding to each color channel of each pixel value from the sub-pixel values ​​corresponding to each color channel before the pixel values ​​are compressed to obtain difference values ​​corresponding to multiple different pixel values, which are obtained based on the maximum value of the multiple difference values.

[0255] In one embodiment, the second determination module 803 is specifically used to concatenate the value of each bit in the sub-pixel value corresponding to the color channel with the value of each bit in the filling pixel value corresponding to the color channel for each color channel to obtain the target sub-pixel value corresponding to the color channel.

[0256] This embodiment can be combined with some or all of the features of the above embodiments, which will not be described in detail here.

[0257] Optionally, for each color channel, the value of each bit in the sub-pixel value corresponding to the color channel and the value of each bit in the filling pixel value corresponding to the color channel are concatenated to obtain the target sub-pixel value corresponding to the color channel.

[0258] Optionally, in the pixel array corresponding to the target image, the target color channels of at least two pixels have different filling pixel values, and one or more or each of the remaining color channels of at least two pixels have different filling pixel values.

[0259] Optionally, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixels are greater than or equal to the minimum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels, and are less than or equal to the maximum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels.

[0260] Optionally, in the pixel point array corresponding to the target image, the filling pixel value corresponding to the target color channel of at least one pixel point is greater than the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and is less than the maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel.

[0261] Optionally, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixels are greater than the minimum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels; and are less than the maximum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels.

[0262] Optionally, in the pixel array corresponding to the target image, a filling pixel value corresponding to a target color channel of at least one pixel is greater than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and a filling pixel value corresponding to the target color channel of at least one pixel is less than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel;

[0263] And / or, in the pixel array corresponding to the target image, the average value of the filling pixel values ​​corresponding to the target color channels of all pixels is equal to the average value of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels.

[0264] Optionally, for each color channel, each bit in the sub-pixel value is higher than each bit in the padding pixel value.

[0265] Optionally, for each color channel, the lowest bit among the bits in the sub-pixel value is higher than the highest bit among the bits in the padding pixel value.

[0266] Optionally, for each color channel, the number of bits of the padded pixel value is greater than or equal to M, where M is 1, 2, or 3. M is an integer greater than or equal to 1.

[0267] Each module in the above-mentioned image data conversion device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each module.

[0268] This embodiment can be combined with some or all of the features of the above embodiments, which will not be described in detail here.

[0269] In an exemplary embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as shown in FIG. Fig.12 As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be implemented through WIFI, a mobile cellular network, near field communication (Near Field Communication, NFC) or other technologies. When the computer program is executed by the processor, an XXX method is implemented. The display unit of the computer device is used to form a visually visible picture, which can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device shell, or an external keyboard, touchpad or mouse.

[0270] Those skilled in the art will understand that Fig.12 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0271] In an exemplary embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the steps described in any of the above method embodiments are implemented.

[0272] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps described in any of the above method embodiments are implemented.

[0273] In one embodiment, a computer program product is provided, including a computer program, which implements the steps described in any of the above method embodiments when executed by a processor.

[0274] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, an artificial intelligence (AI) processor, etc., but are not limited to this.

[0275] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0276] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A method for converting image data, characterized in that: The method comprises: Acquire image data, wherein the image data includes pixel values ​​of each pixel in the target image, and the pixel values ​​include sub-pixel values ​​corresponding to multiple color channels respectively; For each of the pixel values, determine a filling pixel value corresponding to a target color channel among the multiple color channels, and based on the sub-pixel value corresponding to the target color channel, determine one or more or each corresponding filling pixel value in the remaining color channels, and obtain a target sub-pixel value corresponding to each color channel based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel; The target sub-pixel values ​​corresponding to the color channels of the plurality of pixel points are used as image data after the image data is decompressed.

2. The method according to claim 1, characterized in that: The number of bits of the sub-pixel value corresponding to the target color channel is greater than the number of bits of the sub-pixel value corresponding to one or more or each of the remaining color channels; Optionally, the number of bits of the filling pixel value corresponding to the target color channel is smaller than the number of bits of the filling pixel value corresponding to one or more or each of the remaining color channels; Optionally, the sum of the number of bits of the sub-pixel value and the padding pixel value corresponding to the target color channel is equal to the sum of the number of bits of the sub-pixel value and the padding pixel value corresponding to one or more or each of the remaining color channels; Optionally, the number of bits of the sub-pixel value corresponding to the target color channel is N greater than the number of bits of one or more or each corresponding sub-pixel value in the remaining color channels, where N is an integer greater than or equal to 1; And / or, determining a fill pixel value corresponding to a target color channel among the multiple color channels, and determining one or more or each corresponding fill pixel value in the remaining color channels based on the sub-pixel value corresponding to the target color channel, comprises: Obtain the value of the first target bit in the sub-pixel value corresponding to the target color channel; Determine a fill pixel value corresponding to the target color channel, and determine one or more or each corresponding fill pixel value in the remaining color channels based on the value of the first target bit; Optionally, the first target bit is the lowest bit in the sub-pixel value corresponding to the target color channel.

3. The method according to claim 2, characterized in that The step of determining the fill pixel value corresponding to the target color channel, and determining one or more or each corresponding fill pixel value in the remaining color channels based on the value of the first target bit, includes: Using the value of the first target bit as the value of the second target bit in one or more or each corresponding filling pixel value in the remaining color channels; Determine the fill pixel value corresponding to the target color channel, and determine the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels; Using the value of the second target bit and the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels as one or more or each corresponding filling pixel value in the remaining color channels; Optionally, the second target bit is the highest bit in one or more or each corresponding filling pixel value in the remaining color channels.

4. The method according to claim 3, characterized in that: The step of determining the fill pixel value corresponding to the target color channel and determining the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels includes: The preset value is used as the value of each bit in the filling pixel value corresponding to the target color channel, and the value of the remaining bits in the filling pixel value corresponding to one or more or each of the remaining color channels.

5. The method according to claim 3, characterized in that: The step of determining the fill pixel value corresponding to the target color channel and determining the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels includes: Using the preset value as the initial value of each bit in the filling pixel value corresponding to the target color channel, and using the preset value as the initial value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels; Compensate the initial value of each bit in the filling pixel value corresponding to the target color channel and the initial value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels to obtain the value of each bit in the filling pixel value corresponding to the target color channel and the value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels; Optionally, the initial value of each bit in the filling pixel value corresponding to the target color channel and the initial value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels are compensated to obtain the value of each bit in the filling pixel value corresponding to the target color channel and the value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels, including: Taking the pixel values ​​of the preset number of pixel points as an array unit, for each array unit, based on the i-th element in the compensation matrix, determine the value of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the value of each remaining bit in one or more or each corresponding filling pixel value in the remaining color channels, where i is an integer greater than or equal to 1; Optionally, the compensation matrix includes at least two filling values; Optionally, at least two filling values ​​in the compensation matrix are greater than or equal to a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and less than or equal to a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; Optionally, at least one filling value in the compensation matrix is ​​greater than a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and is less than a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; Optionally, at least two filling values ​​in the compensation matrix are greater than a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; and less than a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; Optionally, at least one filling value in the compensation matrix is ​​greater than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and at least one filling value in the compensation matrix is ​​less than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; Optionally, the average value of all filling values ​​in the compensation matrix is ​​equal to the average value of the maximum value and the minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; Optionally, adjacent filling values ​​along a row direction in the compensation matrix are different, and / or adjacent filling values ​​along a column direction in the compensation matrix are different, and the row direction and the column direction intersect; And / or, adjacent filling values ​​along a first diagonal direction in the compensation matrix are the same, and / or, adjacent filling values ​​along a second diagonal direction in the compensation matrix are the same, the first diagonal direction intersects with the row direction, the first diagonal direction intersects with the column direction, the second diagonal direction intersects with the row direction, the second diagonal direction intersects with the column direction, and the first diagonal direction intersects with the second diagonal direction.

6. The method according to claim 3, characterized in that The step of determining the fill pixel value corresponding to the target color channel and determining the values ​​of the remaining bits in one or more or each corresponding fill pixel value in the remaining color channels includes: Taking the pixel values ​​of a preset number of pixel points as an array unit, for each array unit, based on the i-th element in the compensation matrix, determine the value of each bit in the filling pixel value corresponding to the target color channel in the i-th pixel value in the array unit and the value of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels; And / or, in the pixel point array corresponding to the target image, the target color channels of two adjacent pixel points along the row direction have different filling pixel values, and the values ​​of the remaining bits in one or more or each corresponding filling pixel values ​​in the remaining color channels of the two adjacent pixel points along the row direction are different; And / or, in the pixel point array corresponding to the target image, one of the filling pixel values ​​corresponding to the target color channels of two pixel points adjacent along the row direction is greater than the average value, and the other is less than the average value; one of the values ​​of the remaining bits of the filling pixel values ​​corresponding to one or more or each of the remaining color channels of the two pixel points adjacent along the row direction is greater than the average value, and the other is less than the average value; the average value is equal to the average value of the maximum and minimum values ​​corresponding to the bit number of the filling pixel values ​​corresponding to the target color channel; And / or, in the pixel array corresponding to the target image, the target color channels of two adjacent pixel points along the column direction have different filling pixel values ​​corresponding to them, and the values ​​of the remaining bits in one or more or each of the filling pixel values ​​corresponding to the remaining color channels of the two adjacent pixel points along the column direction are different; the row direction and the column direction intersect; And / or, for the same pixel point, the filling pixel value corresponding to the target color channel is the same as the values ​​of the remaining bits in one or more or each corresponding filling pixel value in the remaining color channels; And / or, among the four pixels located in two adjacent rows and two columns, the target color channels of two pixels located in different rows and columns have the same filling pixel values, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels are the same; and the target color channels of another two pixels located in different rows and columns have the same filling pixel values, and the values ​​of the remaining bits in the filling pixel values ​​corresponding to one or more or each of the remaining color channels are the same.

7. The method according to claim 1, characterized in that The step of obtaining a target sub-pixel value corresponding to each color channel based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel comprises: For each color channel, concatenate the value of each bit in the sub-pixel value corresponding to the color channel with the value of each bit in the filling pixel value corresponding to the color channel to obtain the target sub-pixel value corresponding to the color channel; Optionally, in the pixel array corresponding to the target image, the target color channels of at least two pixel points have different filling pixel values, and one or more or each of the remaining color channels of at least two pixel points have different filling pixel values; Optionally, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixel points are greater than or equal to the minimum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels, and are less than or equal to the maximum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels; Optionally, in the pixel array corresponding to the target image, a filling pixel value corresponding to a target color channel of at least one pixel is greater than a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and is less than a maximum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; Optionally, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixel points are greater than the minimum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels; and are less than the maximum value corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels; Optionally, in the pixel point array corresponding to the target image, a filling pixel value corresponding to a target color channel of at least one pixel point is greater than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel, and a filling pixel value corresponding to a target color channel of at least one pixel point is less than an average value of a maximum value and a minimum value corresponding to the number of bits of the filling pixel value corresponding to the target color channel; And / or, in the pixel array corresponding to the target image, the average value of the filling pixel values ​​corresponding to the target color channels of all pixels is equal to the average value of the maximum and minimum values ​​corresponding to the number of bits of the filling pixel values ​​corresponding to the target color channels; Optionally, for each color channel, each bit in the sub-pixel value is higher than each bit in the padding pixel value; Optionally, for each color channel, the lowest bit in each bit in the sub-pixel value is higher than the highest bit in each bit in the filling pixel value; Optionally, for each color channel, the number of bits of the filling pixel value is greater than or equal to M, where M is 1 or 2 or 3.

8. An image data conversion method, characterized in that: The method comprises: Acquire image data, wherein the image data includes pixel values ​​of each pixel in the target image, and the pixel values ​​include sub-pixel values ​​corresponding to multiple color channels respectively; For each of the pixel values, a filling pixel value corresponding to a target color channel among the multiple color channels is determined, and one or more or each corresponding filling pixel value in the remaining color channels is determined, and a target sub-pixel value corresponding to each color channel is obtained based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel; the number of bits of the filling pixel value corresponding to the target color channel is different from the number of bits of the filling pixel value corresponding to one or more or each corresponding filling pixel value in the remaining color channels, and / or, in the pixel point array corresponding to the target image, the filling pixel values ​​corresponding to the target color channels of at least two pixels are different, and the filling pixel values ​​corresponding to one or more or each corresponding filling pixel value in the remaining color channels of at least two pixels are different.

9. An image data conversion device, characterized in that: The device comprises: An acquisition module, used to acquire image data, wherein the image data includes a pixel value of each pixel point in a target image, and the pixel value includes sub-pixel values ​​corresponding to a plurality of color channels respectively; A first determination module is used to determine, for each of the pixel values, a filling pixel value corresponding to a target color channel among the multiple color channels, and determine one or more or each corresponding filling pixel value in the remaining color channels based on the sub-pixel value corresponding to the target color channel, and obtain a target sub-pixel value corresponding to each color channel based on the sub-pixel value corresponding to each color channel and the filling pixel value corresponding to each color channel; The second determining module is used to use the target sub-pixel value corresponding to each color channel of the plurality of pixel points as the image data after decompressing the image data.

10. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 8 are implemented.