Virtual pixel rendering method based on dynamic weight distribution
Through the RGB triangle arrangement structure and the dynamic weight allocation method of CIELAB color space conversion, the problem of color casting of sharp edges under RGB six-light arrangement is solved, achieving more accurate color matching and detail retention, and improving the perceived resolution and display effect of the monitor.
Patent Information
- Application Number
- CN202510757780.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-09
- Publication Date
- 2025-07-08
- Estimated Expiration
- 2045-06-09
AI Technical Summary
The existing pixel multiplexing algorithm for RGB six-light arrangement leads to the problem of color cast and insufficient brightness on the sharp edge display, especially when displaying single-line wide white lines and multi-line wide white lines, the edge sub-pixel grayscale value is insufficient, resulting in color distortion.
Using a virtual pixel rendering method with dynamic weight allocation, through the RGB triangle arrangement structure, combined with CIELAB color space conversion and color difference calculation, each pixel is dynamically assigned a weight and a weight sum is performed to obtain the final output grayscale value.
It effectively solves the problem of color casting on sharp edges, improves the accuracy and stability of image processing results, enhances the display effect, reduces the complexity of the algorithm and improves the computing speed.
Smart Images

Figure CN120279130A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of electronic displays, and particularly relates to a rendering method with dynamic weight allocation. Background Art
[0002] The pixel multiplexing technology is an important technology in the perceived resolution improvement technology of LED displays. Each light point of a sub-pixel is shared by several surrounding virtual pixel points. By a method similar to smoothing the original video image data and then downsampling, an image beyond the physical resolution of the display can be displayed on the LED display, so as to reduce the pixel pitch, increase the perceived resolution, and enhance the display effect.
[0003] For the RGB six-light arrangement, due to the scattered arrangement of sub-pixels and the unweighted average multiplexing algorithm, in the process of pixel multiplexing, since sharp edges contain rich high-frequency information, and the unweighted average multiplexing algorithm is a smoothing filter, it will filter out the rich high-frequency information contained in the edge part, resulting in insufficient brightness when displaying a single-line-width white line and a single-line-width black line. Similarly, when displaying multi-line-width white lines, the gray level of the edge sub-pixels is insufficient due to multiplexing, resulting in color distortion of sharp edges. The most serious case is a single-pixel pure black (white background) or pure white (black background) vertical line, where the color will be directly inaccurate, and purple, yellow, and cyan will alternately appear in multi-line-width white lines.
[0004] Taking the display of a single-pixel-width white line as an example, when displaying, three rows of sub-pixels (red, green, blue) are required to mix colors to display a white line; in the case of real-pixel display, the gray level values of the red, green, and blue sub-pixels are all 255, as Figure 1 shown, and thus a white line with a gray level value of 255 can be obtained. However, in the six-fold virtual display, since each sub-pixel is shared by six pixels, when displaying a single-pixel-width white line, the gray level value of each sub-pixel is calculated as follows: , , , since the gray level value of each sub-pixel becomes 1 / 3 of the original, as Figure 2 shown, it will ultimately result in insufficient display brightness.
[0005] When displaying multi-line-width white lines, taking the display of a 4-line-width white line as an example, in the case of real-pixel display, 12 rows of sub-pixels (4 rows each of red, green, and blue sub-pixels) are required to achieve an ideal display effect, as Figure 3 shown. However, in the case of six-fold virtual display, only 6 rows of sub-pixels (2 rows each of red, green, and blue) are required, as Figure 4 shown. Taking the calculation of the upper 3 rows of sub-pixels as an example, the calculation result is: , , Obviously, the gray value of the edge sub-pixels is much lower than that of the central sub-pixels. The line that should be white at the edge becomes a purple line, resulting in color distortion of sharp edges and thus color cast. Summary of the Invention
[0006] To solve the problem of color cast in the display of sharp edges in existing multiplexing algorithms, the present invention proposes a virtual pixel rendering method with dynamic weight assignment.
[0007] The technical solution of the present invention is as follows: A virtual pixel rendering method with dynamic weight assignment, which is implemented by an RGB triangular arrangement structure; The RGB triangular arrangement structure is specifically as follows: The sub-pixels in the same row are of the same primary color, and the sub-pixels in the same column are arranged in a cycle of three primary colors. Each sub-pixel and the two adjacent sub-pixels of different primary colors in the previous column form a triangular structure, and each sub-pixel and the two adjacent sub-pixels of different primary colors in the next column form a triangular structure; each triangular structure corresponds to a pixel, and each sub-pixel is multiplexed by six pixels; The virtual pixel rendering method is specifically as follows: S1. Copy the first row of pixels of the original RGB image upward by one row, copy the last row of pixels downward by one row, and copy the last column of pixels to the right by one row; S2. When rendering the gray value of any sub-pixel, read the gray values of the corresponding sub-pixel channels of the surrounding six pixels, and at the same time convert them to the CIELAB space; S3. Select the central pixel according to the color difference of the read pixels, and dynamically assign weights to each pixel according to the color difference between the surrounding pixels and the central pixel; S4. Weight and sum the gray values of the six pixels to obtain the final output sub-pixel gray value.
[0008] Preferably, in the RGB triangular arrangement structure, the adjacent two sub-pixels in the same row are spaced 2L apart, the adjacent two sub-pixels in the same column are spaced 2L apart, and the row spacing between adjacent rows and the column spacing between adjacent columns are both L.
[0009] Preferably, L = 0.375 mm.
[0010] Preferably, step S2 specifically includes the following sub-steps: S21. Set the gray values of the remaining two sub-pixel channels in the same pixel to 0; S22. Normalize the RGB values to between 0 and 1, and then perform inverse gamma correction on each channel respectively to obtain linear RGB values: , Among them, C represents the normalized RGB value; S23. Convert the linear RGB value to the XYZ value using the conversion matrix of the sRGB standard, and calculate using the following matrix: , where, , , respectively represent the linear values of the R, G, and B sub-pixel channels; S24. Convert the XYZ value to the CIELAB color space with the standard light source D65 as the reference white point, and the conversion formula is as follows: ; where, if , ; otherwise ; , , .
[0011] Preferably, step S3 is specifically as follows: Given that the coordinates of two specific pixels in the CIELAB color space are and respectively, calculate the color difference ΔE between them: ; When ΔE < 2.3, calculate the average value of the Lab* components of these two specific pixels in the CIELAB space as the central pixel value; calculate the color differences between the remaining four pixels and the central pixel value respectively. If exactly two pixels have a color difference exceeding 10, then take the average value of the gray values of these two high-color-difference pixels as the finally output gray value; otherwise, calculate the weights of the surrounding pixels according to the average value of the color differences between the remaining four pixels and the central pixel value ; the weight of the central pixel ; When ΔE ≥ 2.3, calculate the total color differences between these two specific pixels and the remaining four pixels respectively, and select the pixel with the smaller total color difference as the central pixel; calculate the color differences between the central pixel and the remaining five pixels respectively. If exactly two pixels have a color difference exceeding 10, then take the average value of the gray values of these two high-color-difference pixels as the finally output gray value; otherwise, calculate the weights of the surrounding pixels according to the average value of the color differences between the remaining five pixels and the central pixel ; the weight of the central pixel .
[0012] The present invention also provides a data transmission system, which includes a host computer, an HDMI decoding chip, an HDMI encoding chip, a data processing module, and a sending card. The host computer is used to send the HDMI video signal to be displayed to the HDMI decoding chip; the HDMI decoding chip is used to decode the HDMI video signal and send the decoded data to the data processing module; the data processing module includes a virtual pixel rendering unit, which is used to perform rendering calculations on each frame of data by applying the virtual pixel rendering method with dynamic weight allocation as described above; the virtual pixel rendering unit internally includes a FIFO memory and a data register, which are used to dynamically store and read out the data after each frame of data arrives, form a data matrix, then calculate the sub-pixel display data according to the data in the data register by the virtual pixel rendering method, and send the sub-pixel display data to the HDMI encoding chip to be re-encoded into an HDMI video signal and output to the sending card.
[0013] Preferably, the data after decoding includes a horizontal synchronization signal, a vertical synchronization signal, an enable signal, and RGB grayscale data. Preferably, the data processing module is an FPGA processor.
[0014] The present invention also provides a control system, which includes a receiving card, a driving IC, and the above data transmission system. The receiving card is used to receive the effective video signal after binning by the sending card in the data transmission system, perform electro-optical conversion and brightness and chromaticity correction, and then transmit it to the driving IC to drive the display screen to display.
[0015] An electronic device includes the above control system.
[0016] Compared with the prior art, the specific beneficial effects of the present invention are as follows: The rendering method provided by the present invention preprocesses the image, avoids the problem of missing boundary pixels by expanding the image edge, reduces the conditional judgment branches, reduces the algorithm complexity by more than 20%, and effectively improves the operation speed; and introduces the CIELAB color space conversion, which more accurately reflects human visual perception. In the process of dynamic weight allocation, not only the color consistency is considered, but also the changes within the local area are taken into account, improving the accuracy and stability of the image processing results. Quantify the color difference within the CIELAB color space, dynamically allocate weights to the color differences between the surrounding pixels and the central pixel, effectively balance the influence of different pixels on the final output, and suppress the blurring effect of the smoothing filter on the edge.
[0017] The method provided by the present invention is particularly suitable for image processing tasks that require high-precision color matching and detail retention, providing a solid foundation for subsequent analysis. Description of the Drawings
[0018] Figure 1 Schematic diagram of sub - pixel gray - scale values when displaying a white line with a single - pixel width under the real - pixel display described in the background art; Figure 2 Schematic diagram of sub - pixel gray - scale values when displaying a white line with a single - pixel width under the six - fold virtual display described in the background art; Figure 3 Schematic diagram of sub - pixel gray - scale values when displaying a white line with a multi - line width under the real - pixel display described in the background art; Figure 4 Schematic diagram of sub - pixel gray - scale values when displaying a white line with a multi - line width under the six - fold virtual display described in the background art; Figure 5 Schematic diagram of the specific arrangement structure of sub - pixels described in Embodiment 1; Figure 6 Flow schematic block diagram of the rendering method described in the present invention; Figure 7 Schematic diagram for comparing before and after expanding an image described in Embodiment 1; Figure 8 Example diagram when taking the rendering of a red sub - pixel as an example in Embodiment 2. Detailed implementation manners
[0019] To make the technical solutions of the present invention clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings of the specification of the present invention. It should be noted that the following embodiments are only for better understanding the technical solutions of the present invention and should not be construed as a limitation of the present invention.
[0020] Embodiment 1. This embodiment provides a virtual - pixel rendering method with dynamic weight assignment, which effectively solves the problems caused by the traditional unweighted average rendering algorithm. The virtual - pixel rendering method is implemented based on the RGB triangular arrangement structure; The specific RGB triangular arrangement structure is as follows: Sub - pixels in the same row are of the same primary color, sub - pixels in the same column are arranged in a cycle of three primary colors, each sub - pixel and two adjacent sub - pixels of different primary colors in the previous column form a triangular structure, and each sub - pixel and two adjacent sub - pixels of different primary colors in the next column form a triangular structure; each of the above - mentioned triangular structures corresponds to a pixel, and each sub - pixel is multiplexed by six pixels; the specific arrangement structure of the above - mentioned sub - pixels is as Figure 5 shown, and by sharing a single sub - pixel among 6 surrounding pixels, the purpose of increasing the perceived resolution is achieved.
[0021] The specific virtual - pixel rendering method is as follows: S1. Copy the first row of pixels of the original RGB image upward by one row, the last row of pixels downward by one row, and the last column of pixels to the right by one row; S2. When rendering the gray value of any sub-pixel, read the gray values of the corresponding sub-pixel channels of the surrounding six pixels and convert them to the CIELAB space at the same time; S3. Select the central pixel according to the color difference of the read pixels, and dynamically assign weights to each pixel according to the color difference between the surrounding pixels and the central pixel; S4. Weight-sum the gray values of the six pixels to obtain the final output sub-pixel gray value.
[0022] Figure 6 The algorithm block diagram proposed in this paper is shown below. It mainly consists of two major parts: image preprocessing and dynamic weight assignment. First, for the layout structure targeted by this method, the resolution of a single box body in real pixel display is 960*360, while in virtual display, it can reach 1920*1080. However, for the sub-pixels at the edge of the box body, when being rendered, there are no corresponding six-pixel data in the original image. Therefore, in this embodiment, the image is expanded. For an input image of 1920*1080, it needs to be expanded to 1921*1082. As Figure 7 shown in the schematic diagram, the pixels marked in blue are the expanded parts. The expansion makes subsequent calculations more concise and improves the operation speed. In order to make the processing more in line with the visual effects of the human eye, in this embodiment, the gray values of the corresponding sub-pixel channels are converted to the CIELAB space. Secondly, the central pixel is selected according to the color difference of the read pixels, and weights are dynamically assigned to each pixel according to the difference between the surrounding pixels and the central pixel. Finally, the rendering sub-module assigns these values to each sub-pixel, and finally outputs the rendered image in the form of RGB.
[0023] Embodiment 2. Based on Embodiment 1, in the rendering method of this embodiment, step S2 specifically includes the following sub-steps: S21. Set the gray values of the remaining two sub-pixel channels within the same pixel to 0; Since the rendering methods of red, green, and blue are the same, here we only take the red sub-pixel as an example. As Figure 8 shown, when rendering the red sub-pixel, it is necessary to read the gray values of the red channels of six pixels a1, a2, b1, b2, c1, c2, denoted as R1, R2, R3, R4, R5, R6. Before converting to the CIELAB space, it is necessary to expand the gray values of the six sub-pixels, that is, set the gray values of their blue and green channels to 0. Denote as (0, R1, 0), (0, R2, 0), (0, R3, 0), (0, R4, 0), (0, R5, 0), (0, R6, 0).
[0024] S22. Normalize the RGB values to between 0 and 1, and then perform inverse gamma correction on each channel separately to obtain linear RGB values: , where C represents the normalized RGB values; S23. Use the conversion matrix of the sRGB standard to convert the linear RGB values to XYZ values, and calculate using the following matrix: , where , , represent the linear values of the R, G, and B sub-pixel channels respectively; S24. Convert the RGB color space to the CIELAB color space to more accurately reflect human visual perception. When converting the color space, select D65 as the reference white point and convert the XYZ values to the CIELAB color space. The conversion formula is as follows: ; where if , ; otherwise ; , , .
[0025] Example 3. Based on Example 2, in this example, step S3 is specifically defined as follows: After the color space conversion, use a directional color difference calculator to calculate the color difference ΔE between two pixels.
[0026] Given that the coordinates of two specific pixels (referred to as b1 and b2) in the CIELAB color space are and , and these two pixels represent the color characteristics in the local area, calculate the color difference ΔE between them: ; Determine how to select the reference point based on the color difference between b1 and b2: When ΔE < 2.3, calculate the average value of the Lab* components of these two specific pixels in the CIELAB space as the central pixel value, that is: , , ; Calculate the color differences between the remaining four pixels and the central pixel value respectively. If exactly two pixels have a color difference exceeding 10, take the average of the gray values of these two pixels with high color differences as the finally output gray value; otherwise, calculate the weights of the surrounding pixels according to the average of the color differences between the remaining four pixels and the central pixel value , where ; the weight of the central pixel ; When ΔE≥2.3, calculate the total color differences between these two specific pixels and the remaining four pixels (i.e., a1, a2, c1, c2) respectively, and select the pixel with the smaller total color difference as the central pixel. That is, if the total color difference between b1 and the surrounding four pixels is smaller than the total color difference between b2 and the surrounding four pixels, then select b1 as the reference point; otherwise, select b2 as the reference point. This process ensures that even in the case of large color differences, a more suitable color reference point can be found as the center, thus reducing the error caused by color mutations. Calculate the color differences between the central pixel and the remaining five pixels respectively. If exactly two pixels have a color difference exceeding 10, take the average of the gray values of these two pixels with high color differences as the finally output gray value; otherwise, according to the average of the color differences between the remaining five pixels and the central pixel Calculate the weights of the surrounding pixels , where . Here, it is assumed that b1 is selected as the central pixel and b2 is the surrounding pixel; the weight of the central pixel .
[0027] Finally, based on the weights calculated above, combine the gray values of all six pixels and use the weighted average method to calculate the finally output gray value. Specifically, sum the gray values of all pixels after weighting to obtain the finally output sub-pixel gray value, as shown in the following formula: .
[0028] Example 4. This embodiment provides a data transmission system that applies one of the rendering methods in any of the above embodiments. The data transmission system includes a host computer, an HDMI decoding chip, an HDMI encoding chip, a data processing module, and a sending card. The host computer is used to send the HDMI video signal to be displayed to the HDMI decoding chip. The HDMI decoding chip is used to decode the HDMI video signal and send the decoded data to the data processing module. The data processing module includes a virtual pixel rendering unit, which is used to perform rendering calculations on each frame of data by applying the virtual pixel rendering method with dynamic weight allocation described in any one of Embodiments 1 to 3. The virtual pixel rendering unit internally includes a FIFO memory and a data register, which are used to dynamically store and read the data after each frame of data arrives, form a data matrix, then calculate the sub-pixel display data based on the data in the data register according to the virtual pixel rendering method, and send the sub-pixel display data to the HDMI encoding chip to be re-encoded into an HDMI video signal and output to the sending card.
[0029] The data transmission system of the pixel multiplication display screen provided in this embodiment applies the method described in Embodiment 1. It not only considers the color consistency but also takes into account the changes within the local area, improving the accuracy and stability of the image processing results. This strategy is particularly suitable for image processing tasks that require high-precision color matching and detail retention, providing a solid foundation for subsequent analysis. By dynamically adjusting the weights, it effectively balances the influence of different pixels on the final output, making the processing results more in line with the actual requirements. It also realizes virtual processing of data on the transmission path from the host computer to the sending card, saving the transmission bandwidth between the sending card and the receiving card, the load capacity of the sending card, and the data processing capacity of the receiving card, reducing the requirements for the sending card and the receiving card of the system, thus significantly reducing the cost. It also reduces the number of wires between the sending card and the receiving card in the corresponding display control device, making the internal wiring of the device box regular, reducing the short-circuit risk and making the device easy to repair.
[0030] Embodiment 5. Based on Embodiment 4, the data transmission system provided in this embodiment has the decoded data including a line synchronization signal, a field synchronization signal, an enable signal, and RGB grayscale data. Embodiment 6. Based on Embodiment 4, the data processing module of the data transmission system provided in this embodiment is an FPGA processor.
[0031] Embodiment 7. This embodiment provides a control system, including a receiving card, a driving IC, and the data transmission system described in the above embodiment. The receiving card is configured to receive the valid video signals after binning by the transmitting card in the data transmission system, perform electro-optical conversion and brightness and chrominance correction, and then transmit them to the driving IC to drive the display screen for display.
[0032] Embodiment 8. This embodiment provides an electronic device, which includes the display screen control system described in Embodiment 7.
Claims
1. A virtual pixel rendering method with dynamic weight allocation, characterized in that The RGB triangle arrangement structure of the virtual pixel rendering method is implemented; The specific RGB triangle arrangement structure is as follows: The sub-pixels in the same row are of the same primary color, and the sub-pixels in the same column are arranged in a cycle of three primary colors. Each sub-pixel and the two adjacent sub-pixels of different primary colors in the previous column form a triangle structure, and each sub-pixel and the two adjacent sub-pixels of different primary colors in the next column form a triangle structure; each of the said triangle structures corresponds to one pixel, and each sub-pixel is multiplexed by six pixels; The specific virtual pixel rendering method is as follows: S1. Copy the first row of pixels of the original RGB image upwards by one row, copy the last row of pixels downwards by one row, and copy the last column of pixels to the right by one row; S2. When rendering the gray value of any sub-pixel, read the gray values of the corresponding sub-pixel channels of the surrounding six pixels, and at the same time convert them to the CIELAB space; S3. Select the central pixel according to the color difference of the read pixels, and dynamically assign weights to each pixel according to the color difference between the surrounding pixels and the central pixel; S4. Weight and sum the gray values of the six pixels to obtain the final output sub-pixel gray value.
2. The virtual pixel rendering method with dynamic weight allocation according to claim 1, wherein In the said RGB triangle arrangement structure, the interval between two adjacent sub-pixels in the same row is 2L, the interval between two adjacent sub-pixels in the same column is 2L, the row spacing between adjacent rows and the column spacing between adjacent columns are both L.
3. The virtual pixel rendering method with dynamic weight allocation according to claim 2, wherein, L = 0.375mm.
4. The virtual pixel rendering method with dynamic weight allocation according to any one of claims 1 to 3, characterized in that Step S2 specifically includes the following sub-steps: S21. Set the gray values of the other two sub-pixel channels within the same pixel to 0; S22. Normalize the RGB values to between 0 and 1, and then perform inverse gamma correction on each channel separately to obtain linear RGB values: , where C represents the normalized RGB value; S23. Use the conversion matrix of the sRGB standard to convert the linear RGB values to XYZ values, and calculate using the following matrix: , Among them, , , respectively represent the linear values of the R, G, and B sub-pixel channels; S24. According to the standard light source D65 as the reference white point, convert the XYZ values to the CIELAB color space, and the conversion formula is as follows: ; Among them, if , ; otherwise ; , , .
5. The virtual pixel rendering method with dynamic weight assignment according to claim 4, wherein Step S3 is specifically as follows: Given that the coordinates of two specific pixels in the CIELAB color space are respectively and , calculate the color difference ΔE between them: ; When ΔE < 2.3, calculate the average value of the Lab* components of these two specific pixels in the CIELAB space as the central pixel value; Calculate the color differences between the remaining four pixels and the central pixel value respectively. If exactly two pixels have a color difference exceeding 10, then take the average value of the gray values of these two pixels with high color differences as the finally output gray value; Otherwise, according to the average value of the color differences between the remaining four pixels and the central pixel value calculate the weights of the surrounding pixels ; the weight of the central pixel ; When ΔE ≥ 2.3, calculate the total color differences between these two specific pixels and the remaining four pixels respectively, and select the pixel with the smaller total color difference as the central pixel; calculate the color differences between the central pixel and the remaining five pixels respectively. If exactly two pixels have a color difference exceeding 10, then take the average value of the gray values of these two pixels with high color differences as the finally output gray value; Otherwise, calculate the average color difference between the remaining five pixels and the central pixel to calculate the weights of the surrounding pixels ; the weight of the central pixel .
6. A data transmission system, characterized in that, The data transmission system includes a host computer, an HDMI decoding chip, an HDMI encoding chip, a data processing module, and a sending card. The host computer is configured to send the HDMI video signal to be displayed to the HDMI decoding chip. The HDMI decoding chip is configured to decode the HDMI video signal and send the decoded data to the data processing module. The data processing module includes a virtual pixel rendering unit, which is configured to perform rendering calculations on each frame of data by using the virtual pixel rendering method of dynamic weight allocation as described in any one of claims 1 to 5. The virtual pixel rendering unit internally includes a FIFO memory and a data register, which are configured to dynamically store and read out the data after each frame of data arrives, form a data matrix, then calculate the sub-pixel display data based on the data in the data register according to the virtual pixel rendering method, and send the sub-pixel display data to the HDMI encoding chip to be re-encoded into an HDMI video signal and output to the sending card.
7. The data transmission system according to claim 6, characterized in that The data after decoding includes a horizontal synchronization signal, a vertical synchronization signal, an enable signal, and RGB grayscale data.
8. The data transmission system according to claim 6, characterized in that, The data processing module is an FPGA processor.
9. A control system, characterized in that, It includes a receiving card, a driving IC, and the data transmission system as described in any one of claims 6 to 8. The receiving card is configured to receive the valid video signal after binning by the sending card in the data transmission system, perform electro-optical conversion and brightness and chroma correction, and then send it to the driving IC to drive the display screen to display.
10. An electronic device, characterized in that, The electronic device includes the control system as described in claim 9.
Citation Information
Patent Citations
Sub-pixel rendering method for RGB-Delta arrangement
CN114203089A
Sub-pixel rendering method and system of RGBG type display panel
CN116095398A
Sub-pixel rendering method and system of RGB-Delta type display panel
CN116095399A
Pixel multiplexing method, data transmission system and display screen control system and method
CN116486738A
Sub-pixel rendering method and device, equipment and storage medium
CN118366401A