A display picture processing method, device, equipment and storage medium
By dividing the target frame into multiple smallest display units in a fine-grained manner and processing it based on the display coefficient of each smallest display unit, the problem that the display cannot highlight the local features and details of the image in the prior art is solved, thus improving the display effect.
Patent Information
- Application Number
- CN202111358109.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-16
- Publication Date
- 2026-01-23
- Estimated Expiration
- 2041-11-16
AI Technical Summary
In the prior art, the display of electronic devices cannot highlight local features and details when displaying images, resulting in poor display effects.
By dividing the target frame into multiple smallest display units in a fine-grained manner, and determining the display coefficient based on the initial grayscale average value of each smallest display unit and the global grayscale adjustment coefficient, the image is processed to highlight display details.
It improves the display detail of the image and enhances the display effect of the monitor.
Smart Images

Figure CN116137019B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of display screen processing, and more particularly to a display screen processing method, apparatus, device, and storage medium. Background Technology
[0002] Currently, most electronic devices (such as televisions, computers, oscilloscopes, etc.) only process the entire display image at a time. The conventional approach is to select one of a limited number of pre-set gamma curves based on user settings. This gamma curve can be, for example,... Figure 1 The gamma curve shown is any one of the gamma 2.0, gamma 2.2, and gamma 2.4 curves. Different curves represent different display effects of the monitor. Electronic devices display all display screens based on the selected gamma curve, but this processing method cannot highlight the local features and details of the screen, resulting in poor display effects. Summary of the Invention
[0003] This application provides a display screen processing method, apparatus, device, and storage medium, which can adjust and optimize the screen content of a target frame, thereby highlighting the display details and improving the display effect.
[0004] In a first aspect, embodiments of this application provide a display screen processing method, the method comprising:
[0005] The process involves determining the grayscale value of each pixel in the target frame, the average grayscale value of the target frame, and the initial average grayscale value of each smallest display unit in the target frame. Based on the determined grayscale value of each pixel, a global grayscale adjustment coefficient and the image type of the target frame are determined. Based on the image type, the initial average grayscale value of each smallest display unit, and the average grayscale value of the target frame, a display coefficient for each smallest display unit is determined. Finally, based on the display coefficients of each smallest display unit, the initial average grayscale value of each smallest display unit, and the global grayscale adjustment coefficient, the target frame is processed to obtain the processed target frame image. This method allows for fine-grained division of the target frame into multiple smallest display units. The display coefficient for each smallest display unit is determined based on the overall image type of the target frame. Then, the target frame containing multiple smallest display units is processed according to the global grayscale adjustment coefficient and the display coefficient, thereby adjusting and optimizing the image content of the target frame, highlighting display details, and improving the display effect.
[0006] Optionally, the implementation method for determining the average grayscale value of the target frame and the initial average grayscale value of each smallest display unit in the target frame in the above embodiments may include: determining the grayscale value of each pixel in the target frame; determining the average grayscale value of the target frame based on the grayscale value of each pixel and the number of pixels in the target frame; and determining the initial average grayscale value of each smallest display unit based on the grayscale value of each pixel contained in each smallest display unit in the target frame and the number of pixels contained in each smallest display unit in the target frame. In this process, since the grayscale value of each pixel in the target frame and the number of pixels in the target frame are obtained, as well as the grayscale value of each pixel in each smallest display unit in the target frame and the number of pixels in each smallest display unit, the sum of the grayscale values of all pixels in the target frame and each smallest display unit can be determined, based on the grayscale value of each pixel. Then, based on this sum and the number of pixels in each smallest display unit, the average grayscale value of the target frame and the initial average grayscale value of each smallest display unit can be determined. In other words, this process can be understood as calculating the average grayscale value of the target frame and the initial average grayscale value of each smallest display unit in the target frame according to the average value calculation formula, which has the advantages of simple calculation and small amount of computation.
[0007] Optionally, the implementation method of determining the global grayscale adjustment coefficient and the image type of the target frame based on the determined grayscale value of each pixel in the above embodiments may include: determining the number of grayscale values of pixels in the target frame based on the determined grayscale value of each pixel; determining the total number of pixels c in the target frame based on the number of grayscale values of pixels in the target frame; determining the number a of pixels a in the target frame with a grayscale value greater than a grayscale threshold based on the grayscale value of each pixel; calculating the ratio of a to c based on the determined c and a; determining the global grayscale adjustment coefficient based on the ratio; and determining the image type of the target frame based on the ratio; wherein c and a are integers. The above implementation method determines the image type of the target frame and the global grayscale adjustment coefficient based on the proportion of pixels with a grayscale value greater than a grayscale threshold in the total number of pixels in the target frame.
[0008] Optionally, the implementation method of determining the global grayscale adjustment coefficient based on the ratio in the above embodiments may include: determining the global grayscale adjustment coefficient based on the ratio and a preset value m; wherein the preset value m is greater than 0.
[0009] Optionally, the implementation method for determining the image type of the target frame based on the ratio in the above embodiments may include: determining the image type of the target frame as a bright image when the ratio is greater than the image ratio threshold n; and determining the image type of the target frame as a dark image when the ratio is less than or equal to the image ratio threshold n; wherein the value of n ranges from [0, 1]. That is, the image type of the target frame is determined based on the proportion of the number of pixels with grayscale values greater than the grayscale threshold in the total number of pixels in the target frame.
[0010] Optionally, in the above embodiments, the method for determining the display coefficient of each minimum display unit based on the screen type, the initial average grayscale value of each minimum display unit, and the average grayscale value of the target frame may include: when the screen type is a bright screen, determining the difference between the initial average grayscale value and the average grayscale value, and determining the display coefficient of the corresponding minimum display unit based on the difference and the average grayscale value; when the screen type is a dark screen, determining the difference between the average grayscale value and the initial average grayscale value, and determining the display coefficient of the corresponding minimum display unit based on the difference and the average grayscale value. That is, different methods are used to determine the display coefficient of each minimum display unit for different screen types.
[0011] Optionally, in the above embodiments, the target frame image is processed based on the display coefficient of each minimum display unit, the initial average grayscale value of each minimum display unit, and the global grayscale adjustment coefficient to obtain the processed target frame image. This includes: correcting the display coefficient of each minimum display unit in the target frame image according to the global grayscale adjustment coefficient to obtain the corrected display coefficient; multiplying the corrected display coefficient by the grayscale value of each pixel in the corresponding minimum display unit to obtain the updated grayscale value of each pixel in the corresponding minimum display unit; and determining the frame image composed of the pixels with updated grayscale values in each minimum display unit as the processed target frame image. In this process, based on the corrected optimized display coefficient of each minimum display unit, the grayscale value of each pixel in the corresponding minimum display unit is updated, and the frame image composed of the pixels after processing and updating the grayscale values is the processed target frame image.
[0012] Secondly, embodiments of this application also provide a display screen processing apparatus, the apparatus comprising:
[0013] The first determining module is used to determine the grayscale value of each pixel in the target frame, the average grayscale value of the target frame, and the initial average grayscale value of each smallest display unit in the target frame.
[0014] The second determining module is used to determine the global grayscale adjustment coefficient and the image type of the target frame based on the determined grayscale value of each pixel.
[0015] The third determining module is used to determine the display coefficient of each minimum display unit based on the image type, the initial average grayscale value of each minimum display unit, and the average grayscale value of the target frame image.
[0016] The processing module is used to process the target frame image based on the display coefficient of each minimum display unit, the initial grayscale average value of each minimum display unit, and the global grayscale adjustment coefficient, so as to obtain the processed target frame image.
[0017] Thirdly, this application also provides a display device, which includes a memory and a processor. When the memory stores computer instructions, and the display device executes the computer instructions, the display device performs a display screen processing method as provided in the above embodiments.
[0018] Fourthly, embodiments of this application also provide a computer-readable storage medium storing computer instructions thereon, which, when executed by a display device, cause the display device to perform a display screen processing method as provided in the above embodiments.
[0019] This application provides a display image processing method, apparatus, device, and storage medium, comprising: determining the grayscale value of each pixel in a target frame image, the average grayscale value of the target frame image, and the initial average grayscale value of each smallest display unit in the target frame image; determining a global grayscale adjustment coefficient and the image type of the target frame image based on the determined grayscale value of each pixel; determining a display coefficient for each smallest display unit based on the image type, the initial average grayscale value of each smallest display unit, and the average grayscale value of the target frame image; and processing the target frame image based on the display coefficient of each smallest display unit, the initial average grayscale value of each smallest display unit, and the global grayscale adjustment coefficient to obtain a processed target frame image. Through the above method, the target frame image can be finely divided into multiple smallest display units, and the display coefficient of each smallest display unit can be determined based on the type of the entire target frame image. Then, the target frame image containing multiple smallest display units can be processed according to the global grayscale adjustment coefficient and the display coefficient, thereby adjusting and optimizing the image content of the target frame image, highlighting the display details, and improving the display effect. Attached Figure Description
[0020] Figure 1 This is a schematic diagram of the gamma curve inside a display in the prior art;
[0021] Figure 2 This is a flowchart of a display screen processing method provided in an embodiment of this application;
[0022] Figure 3This is a schematic diagram of the curves of the initial grayscale average value, the grayscale average value, and the display coefficient under a bright screen provided in the embodiments of this application;
[0023] Figure 4 This is a schematic diagram of the curves of the initial grayscale average value, the grayscale average value, and the display coefficient under a dark scene provided in the embodiments of this application;
[0024] Figure 5 This is a schematic diagram of the display screen processing device structure in the embodiments of this application;
[0025] Figure 6 This is a schematic diagram of the structure of the display device in the embodiments of this application. Detailed Implementation
[0026] The present application will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the application and not intended to limit it. Furthermore, it should be noted that, for ease of description, the accompanying drawings show only the parts relevant to the present application, not the entire structure.
[0027] Furthermore, in the embodiments of this application, terms such as "optionally" or "exemplarily" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "optionally" or "exemplarily" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design solutions. Specifically, the use of terms such as "optionally" or "exemplarily" is intended to present the relevant concepts in a specific manner.
[0028] Figure 2 This flowchart illustrates a display image processing method provided in an embodiment of this application. This method can be applied to displays of various display devices such as televisions, computers, and oscilloscopes. It processes each frame displayed on the display device to highlight image details and improve display quality. This method can be executed by a device integrated into the display device, which can be implemented in software and / or hardware, such as… Figure 2 As shown, the method may include, but is not limited to, the following steps:
[0029] S201. Determine the grayscale value of each pixel in the target frame, the average grayscale value of the target frame, and the initial average grayscale value of each smallest display unit in the target frame.
[0030] The target frame in this step can be understood as a frame to be processed. In this embodiment, each frame can be processed separately. Since a frame contains multiple pixels, and each pixel corresponds to a grayscale value, it presents a corresponding brightness and darkness effect at the coordinate position or area of the pixel, thus forming a complete frame. Therefore, the grayscale value of each pixel in the target frame can be determined based on the pixels contained in the target frame. Furthermore, the average grayscale value of the target frame and the initial average grayscale value of each smallest display unit in the target frame can also be determined.
[0031] The average grayscale value of the target frame can be understood as the average grayscale value of all pixels in the target frame. For example, its determination can include: determining the grayscale value of each pixel in the target frame, and determining the average grayscale value of the target frame based on the grayscale value of each pixel and the number of pixels in the target frame. It can be understood that since the grayscale value of each pixel in the target frame is determined, the sum of the grayscale values of all pixels in the target frame can also be obtained, and the average grayscale value of the target frame can be determined based on this sum and the number of pixels in the target frame. That is, this process can be understood as calculating the average grayscale value of the target frame according to the average value calculation formula.
[0032] The initial average grayscale value of each smallest display unit in the target frame can be understood as the average grayscale value of all pixels contained in each smallest display unit among the several smallest display units contained in the target frame. For example, given the above-mentioned acquisition of the grayscale value of each pixel in the target frame, the initial average grayscale value of each smallest display unit can be determined based on the grayscale value of each pixel contained in each smallest display unit and the number of pixels contained in each smallest display unit in the target frame. Similarly, its implementation principle can be the same as the above-mentioned method for determining the average grayscale value of the target frame. That is, given the acquisition of the grayscale value of each pixel contained in each smallest display unit, the sum of the grayscale values of the pixels contained in each smallest display unit can be obtained, and then, based on this sum and the number of pixels contained in each smallest display unit, the initial average grayscale value of each smallest display unit can be determined. S202: Based on the determined grayscale value of each pixel, determine the global grayscale adjustment coefficient and the frame type of the target frame.
[0033] For example, since each pixel in the target frame corresponds to a grayscale value, the number of grayscale values of a pixel is equal to the number of pixels in the target frame. Therefore, by determining the grayscale value of each pixel in the target frame, the number of grayscale values of pixels in the target frame can be determined. Then, based on the number of grayscale values of pixels in the target frame, the total number of pixels in the target frame can be determined, and this total number is denoted as c. Correspondingly, based on the set grayscale threshold and the determined grayscale value of each pixel, the number of pixels in the target frame whose grayscale value is greater than the grayscale threshold can be determined, and this number is denoted as a. It is understood that the above numbers a and c are both integers, and a is less than or equal to c. Furthermore, the above grayscale threshold can be set by those skilled in the art according to the actual needs of the scenario, and its acquisition method and value range are not limited in this embodiment.
[0034] Based on the determined numbers 'a' and 'c', the ratio between 'a' and 'c' is calculated, and then the global grayscale adjustment coefficient and the image type of the target frame are determined according to this ratio. The global grayscale adjustment coefficient is used to adjust the display coefficient of each smallest display unit contained in the target frame from the perspective of the entire target frame.
[0035] Alternatively, the number of pixels in the target frame whose grayscale value is less than or equal to the grayscale threshold can be determined and denoted as b, where b is an integer. Since b satisfies the condition a + b = c, the number of pixels in the target frame whose grayscale value is greater than the grayscale threshold can be determined based on the determined number of pixels b. Then, the global grayscale adjustment coefficient and the image type of the target frame can be determined based on the ratio between a and c.
[0036] S203. Determine the display coefficient of each minimum display unit based on the image type, the initial average grayscale value of each minimum display unit, and the average grayscale value of the target frame image.
[0037] As mentioned above, since the target frame image contains different types of images, different methods can be used to determine the display coefficient of each smallest display unit for different image types, thereby ensuring that the display coefficient of each smallest display unit in the target frame image is related to the image type of the target frame image.
[0038] For example, if the target frame is a bright image, the difference between the initial grayscale value of each smallest display unit and the average grayscale value of the target frame can be determined. The display coefficient of the corresponding smallest display unit is then determined based on this difference and the average grayscale value of the target frame. Conversely, if the target frame is a dark image, the difference between the average grayscale value of the target frame and the initial average grayscale value is determined. The display coefficient of the corresponding smallest display unit is then determined based on this difference and the average grayscale value of the target frame.
[0039] S204. Based on the display coefficient of each minimum display unit, the initial grayscale average value of each minimum display unit, and the global grayscale adjustment coefficient, process the target frame image to obtain the processed target frame image.
[0040] For example, from the perspective of the target frame, the display coefficient of each smallest display unit contained in the target frame can be corrected based on a global adjustment coefficient. For instance, the global adjustment coefficient can be multiplied by the display coefficient of each smallest display unit to obtain the corrected display coefficient of each smallest display unit. Then, the obtained corrected display coefficient is multiplied by the grayscale value of each pixel in the corresponding smallest display unit to obtain the updated grayscale value of each pixel in the corresponding smallest display unit. In this way, a frame composed of pixels with updated grayscale values in each smallest display unit is the processed target frame.
[0041] This application provides a display image processing method, including: determining the grayscale value of each pixel in a target frame image, the average grayscale value of the target frame image, and the initial average grayscale value of each smallest display unit in the target frame image; determining a global grayscale adjustment coefficient and the image type of the target frame image based on the determined grayscale value of each pixel; determining a display coefficient for each smallest display unit based on the image type, the initial average grayscale value of each smallest display unit, and the average grayscale value of the target frame image; and processing the target frame image based on the display coefficient of each smallest display unit, the initial average grayscale value of each smallest display unit, and the global grayscale adjustment coefficient to obtain a processed target frame image. This method allows for fine-grained division of the target frame image into multiple smallest display units, and the determination of the display coefficient for each smallest display unit based on the overall type of the target frame image. Furthermore, the target frame image containing multiple smallest display units is processed based on the global grayscale adjustment coefficient and the display coefficient, thereby adjusting and optimizing the image content of the target frame image, highlighting display details, and improving the display effect.
[0042] In one example, the implementation of determining the global grayscale adjustment coefficient in step S202 above based on the ratio of the number of pixels a with grayscale values greater than the grayscale threshold in the target frame to the total number of pixels c in the target frame may include: determining the global grayscale adjustment coefficient based on the ratio and a preset value m, wherein the preset value m is greater than 0.
[0043] For example, in this embodiment of the application, the method for determining the global grayscale adjustment coefficient based on the preset value m and the ratio of a and c can be expressed by the following formula:
[0044]
[0045] It should be noted that the constant m can be an integer (e.g., 1) or a decimal. The specific value of m, whether it is an integer or a decimal, can be determined based on the actual application scenario. This application does not limit this.
[0046] For example, the process of determining the image type of the target frame in step S202 based on the ratio of the number a of pixels with grayscale values greater than the grayscale threshold to the total number of pixels c in the target frame can be implemented in ways including but not limited to the following:
[0047] For example, if the ratio is greater than the screen ratio threshold n, the target frame is determined to be a bright screen. If the ratio is less than or equal to the screen ratio threshold n, the target frame is determined to be a dark screen. The value of n ranges from [0, 1], meaning the minimum value of n is 0 and the maximum value is 1.
[0048] It should be noted that the transition between bright and dark scenes is smooth. The larger the a / c value, the brighter the scene; the smaller the a / c value, the darker the scene. In the brightest case, the a / c value is 1, and in the darkest case, the a / c value is 0.
[0049] Accordingly, it can be determined that the aforementioned global grayscale adjustment coefficient is also related to the brightness of the target frame. The a / c value can be understood as representing the brightness of the image. The k value and the a / c value generally show an inverse trend. When the image is at its brightest, a / c is 1, and the global coefficient k is 0.5; when the image is at its darkest, a / c is 0, and the global coefficient k is 1. Furthermore, this inverse trend between the global coefficient k and the a / c value is also related to the grayscale threshold. By adjusting the grayscale threshold, the value of a can be adjusted, thereby adjusting the curve of the global coefficient.
[0050] In one example, the implementation of determining the display coefficient of each smallest display unit in step S203 above may specifically include:
[0051] Assuming the average grayscale value of the target frame is y, the initial average grayscale value of each smallest display unit is x, and the display coefficient of the smallest display unit is z. In the case of a bright image, the difference between the initial average grayscale value and the mean of the average grayscale values is determined, which is xy. Based on this difference and the average grayscale value y, the display coefficient z of the corresponding smallest display unit is determined. Therefore, the display coefficient z can be:
[0052]
[0053] Based on formula (2), it can be seen that for a bright image, as the initial grayscale average value of the smallest display unit gradually changes from being greater than the grayscale average value of the target frame to being less than the grayscale average value of the target frame, the display coefficient of the smallest display unit gradually increases, and its trend is shown in the figure. Figure 3 As shown.
[0054] When the image type is a dark image, the difference between the average grayscale value and the initial average grayscale value is determined, which is yx. The display coefficient z of the corresponding smallest display unit is determined based on this difference and the average grayscale value y, as shown in the following formula:
[0055]
[0056] Based on formula (3), it can be seen that for dark scenes, as the initial grayscale average value of the smallest display unit gradually changes from being greater than the grayscale average value of the target frame to being less than the grayscale average value of the target frame, the display coefficient of the smallest display unit gradually decreases, and its trend is shown in the figure. Figure 4 As shown.
[0057] In this embodiment, it is assumed that the target frame contains X smallest display units, where X is an integer greater than 0. Furthermore, the value of X can be set according to actual needs. It is understood that the larger the value of X, the finer the granularity of the target frame division, and the better the display effect of the resulting display frame after processing each smallest display unit.
[0058] For example, the implementation of determining the X minimum display units contained in the target frame in this step can include the following different scenarios. One scenario is that if the user resets the value of X in the display device, the display device can determine that the target frame contains X identical minimum display units based on the acquired X value. Optionally, the user can set parameters such as the number of rows, columns, and the number X of minimum display units contained in the target frame. The display device then determines the size of each of the X minimum display units in the target frame and their layout based on the user's settings. Another scenario is that if the user does not change the previously set parameters, the display device directly obtains the previously determined X minimum display units, for example, the size of each of the X minimum display units and their layout.
[0059] Figure 5 This application provides a display screen processing apparatus that can be integrated into various display devices with a display screen, for processing each frame of the display screen. Figure 5 As shown, the device includes: a first module 501, a second determining module 502, a third determining module 503, and a processing module 504;
[0060] The first determining module is used to determine the grayscale value of each pixel in the target frame, the average grayscale value of the target frame, and the initial average grayscale value of each smallest display unit in the target frame.
[0061] The second determining module is used to determine the global grayscale adjustment coefficient and the image type of the target frame based on the determined grayscale value of each pixel.
[0062] The third determining module is used to determine the display coefficient of each minimum display unit based on the image type, the initial average grayscale value of each minimum display unit, and the average grayscale value of the target frame image.
[0063] The processing module is used to process the target frame image based on the display coefficient of each minimum display unit, the initial grayscale average value of each minimum display unit, and the global grayscale adjustment coefficient, so as to obtain the processed target frame image.
[0064] In one example, the first determining module is specifically used to determine the grayscale value of each pixel in the target frame; determine the average grayscale value of the target frame based on the grayscale value of each pixel and the number of pixels in the target frame; and determine the initial average grayscale value of each minimum display unit based on the grayscale value of each pixel contained in each minimum display unit in the target frame and the number of pixels contained in each minimum display unit in the target frame.
[0065] Optionally, the second determining module can be specifically used to determine the number of grayscale values of pixels in the target frame based on the determined grayscale value of each pixel; determine the total number of pixels c in the target frame based on the number of grayscale values of pixels in the target frame; determine the number a of pixels a in the target frame with grayscale values greater than the grayscale threshold based on the grayscale value of each pixel; calculate the ratio of a to c based on the determined c and a; determine the global grayscale adjustment coefficient based on the ratio; and determine the image type of the target frame based on the ratio; wherein c and a are integers.
[0066] For example, the second determining module described above can be used to determine the global grayscale adjustment coefficient based on the ratio and the preset value m; wherein the preset value m is greater than 0.
[0067] Optionally, the second determining module can determine the global grayscale adjustment coefficient according to the above formula (1).
[0068] The second determining module described above can also be used to determine the image type of the target frame as a bright image when the determination ratio is greater than the image ratio threshold n; and to determine the image type of the target frame as a dark image when the determination ratio is less than or equal to the image ratio threshold n; wherein the value of n is in the range of [0, 1].
[0069] In one example, the third determining module is used to determine the difference between the initial grayscale average value and the grayscale average value when the screen type is a bright screen, and to determine the display coefficient of the corresponding smallest display unit based on the difference and the grayscale average value; and to determine the difference between the grayscale average value and the initial grayscale average value when the screen type is a dark screen, and to determine the display coefficient of the corresponding smallest display unit based on the difference and the grayscale average value.
[0070] In one example, the above processing module is used to correct the display coefficient of each smallest display unit in the target frame according to the global grayscale adjustment coefficient to obtain the corrected display coefficient; multiply the corrected display coefficient by the grayscale value of each pixel in the corresponding smallest display unit to obtain the updated grayscale value of each pixel in the corresponding smallest display unit; and determine the frame composed of the pixels with updated grayscale values in each smallest display unit as the processed target frame.
[0071] The display screen processing device provided in this application embodiment can execute this application. Figure 2 The display processing method provided in this embodiment has corresponding functional units and beneficial effects for performing the method.
[0072] Figure 6 This is a schematic diagram of the structure of a display device provided in an embodiment of this application, such as... Figure 6As shown, the display device includes a processor 601, a memory 602, an input device 603, and an output device 604; the number of processors 601 in the display device can be one or more. Figure 6 Taking a processor 601 as an example; the processor 601, memory 602, input device 603, and output device 604 in the display device can be connected via a bus or other means. Figure 6 Taking the example of a connection between China and Israel via a bus.
[0073] The memory 602, as a computer-readable storage medium, can be used to store software programs, computer-executable programs, and modules, as described in the embodiments of this application. Figure 2 The program instructions / modules corresponding to the display screen processing method in the display screen processing device (e.g., the acquisition module 501, the determination module 502, and the processing module 503 in the display screen processing device). The processor 601 executes various functions of the display device and data processing by running the software programs, instructions, and modules stored in the memory 602, thereby realizing the above-mentioned display screen processing method.
[0074] The memory 602 may primarily include a program storage area and a data storage area. The program storage area may store the operating system and at least one application program required for a given function; the data storage area may store data created based on the use of the cloud server, etc. Furthermore, the memory 602 may include high-speed random access memory and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other non-volatile solid-state storage device. In some instances, the memory 602 may further include memory remotely located relative to the processor 601, which can be connected to a display device / terminal / server via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0075] Input device 603 can be used to receive input digital or character information, and to generate key signal inputs related to user settings and function control of the display device. Output device 604 may include devices such as a display screen.
[0076] This application embodiment also provides a storage medium containing computer-executable instructions, which, when executed by a processor, are used to perform a display screen processing method, the method comprising:
[0077] Determine the grayscale value of each pixel in the target frame, the average grayscale value of the target frame, and the initial average grayscale value of each smallest display unit in the target frame;
[0078] Based on the determined grayscale value of each pixel, the global grayscale adjustment coefficient and the image type of the target frame are determined.
[0079] The display coefficient of each minimum display unit is determined based on the image type, the initial average grayscale value of each minimum display unit, and the average grayscale value of the target frame image.
[0080] The target frame image is processed based on the display coefficient of each smallest display unit, the initial average grayscale value of each smallest display unit, and the global grayscale adjustment coefficient to obtain the processed target frame image.
[0081] Of course, the computer-executable instructions provided in the embodiments of this application are not limited to the operation of the method described above, but can also execute the display screen processing method provided in any embodiment of this application.
[0082] Based on the above description of the implementation methods, those skilled in the art can clearly understand that this application can be implemented using software and necessary general-purpose hardware, and of course, it can also be implemented using hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as a computer floppy disk, read-only memory (ROM), random access memory (RAM), flash memory, hard disk, or optical disk, etc., including several instructions to cause a display device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0083] It is worth noting that in the above-described embodiments of the display screen processing device, the various modules are divided according to functional logic, but are not limited to the above division, as long as the corresponding functions can be achieved; in addition, the specific names of each functional module are only for easy differentiation and are not used to limit the scope of protection of this application.
[0084] Note that the above are merely preferred embodiments and the technical principles employed in this application. Those skilled in the art will understand that this application is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions can be made without departing from the scope of protection of this application. Therefore, although this application has been described in detail through the above embodiments, this application is not limited to the above embodiments, and may include many other equivalent embodiments without departing from the concept of this application, the scope of which is determined by the scope of the appended claims.
Claims
1. A method for processing display images, characterized in that, include: Determine the grayscale value of each pixel in the target frame, the average grayscale value of the target frame, and the initial average grayscale value of each smallest display unit in the target frame; Based on the determined grayscale value of each pixel, the global grayscale adjustment coefficient and the image type of the target frame are determined. The display coefficient of each minimum display unit is determined based on the image type, the initial average grayscale value of each minimum display unit, and the average grayscale value of the target frame image. The target frame image is processed based on the display coefficient of each minimum display unit, the initial grayscale average value of each minimum display unit, and the global grayscale adjustment coefficient to obtain the processed target frame image.
2. The method according to claim 1, characterized in that, Determining the average grayscale value of the target frame and the initial average grayscale value of each smallest display unit in the target frame includes: Determine the grayscale value of each pixel in the target frame; The average grayscale value of the target frame is determined based on the grayscale value of each pixel and the number of pixels in the target frame. The initial average grayscale value of each minimum display unit is determined based on the grayscale value of each pixel contained in each minimum display unit in the target frame and the number of pixels contained in each minimum display unit in the target frame.
3. The method according to claim 1 or 2, characterized in that, The step of determining the global grayscale adjustment coefficient and the image type of the target frame based on the determined grayscale value of each pixel includes: Based on the determined grayscale value of each pixel, the number of grayscale values of the pixels in the target frame is determined; The total number of pixels c in the target frame is determined based on the number of grayscale values of the pixels in the target frame. Based on the grayscale value of each pixel, determine the number a of pixels in the target frame whose grayscale value is greater than the grayscale threshold; Calculate the ratio of a to c based on the determined c and a; The global grayscale adjustment coefficient is determined based on the ratio, and the image type of the target frame is determined based on the ratio. Where c and a are integers.
4. The method according to claim 3, characterized in that, The step of determining the global grayscale adjustment coefficient based on the ratio includes: The global grayscale adjustment coefficient is determined based on the ratio and the preset value m; The preset value m has a range of values greater than 0.
5. The method according to claim 3, characterized in that, Determining the image type of the target frame based on the ratio includes: If the ratio is greater than the screen ratio threshold n, the screen type of the target frame is determined to be a bright screen. If the ratio is less than or equal to the screen ratio threshold n, the screen type of the target frame is determined to be a dark screen. The value of n ranges from [0, 1].
6. The method according to any one of claims 1-2 or 4-5, characterized in that, The step of determining the display coefficient of each minimum display unit based on the image type, the initial average grayscale value of each minimum display unit, and the average grayscale value of the target frame image includes: When the image type is a bright image, the difference between the initial average grayscale value and the average grayscale value is determined, and the display coefficient of the corresponding smallest display unit is determined based on the difference and the average grayscale value. When the image type is a dark image, the difference between the average grayscale value and the initial average grayscale value is determined, and the display coefficient of the corresponding smallest display unit is determined based on the difference and the average grayscale value.
7. The method according to claim 1, characterized in that, The step of processing the target frame image based on the display coefficient of each minimum display unit, the initial grayscale average value of each minimum display unit, and the global grayscale adjustment coefficient to obtain the processed target frame image includes: The display coefficient of each smallest display unit in the target frame is corrected according to the global grayscale adjustment coefficient to obtain the corrected display coefficient; Multiply the corrected display coefficient by the grayscale value of each pixel in the corresponding minimum display unit to obtain the updated grayscale value of each pixel in the corresponding minimum display unit. The frame image composed of pixels whose grayscale values have been updated in each smallest display unit is determined as the processed target frame image.
8. A display screen processing device, characterized in that, include: The first determining module is used to determine the grayscale value of each pixel in the target frame, the average grayscale value of the target frame, and the initial average grayscale value of each smallest display unit in the target frame. The second determining module is used to determine the global grayscale adjustment coefficient and the image type of the target frame based on the determined grayscale value of each pixel. The third determining module is used to determine the display coefficient of each minimum display unit based on the image type, the initial average grayscale value of each minimum display unit, and the average grayscale value of the target frame image. The processing module is used to process the target frame image based on the display coefficient of each minimum display unit, the initial grayscale average value of each minimum display unit, and the global grayscale adjustment coefficient, so as to obtain the processed target frame image.
9. A display device, comprising a memory and a processor, characterized in that, The memory stores computer instructions, and when the display device executes the computer instructions, it causes the display device to perform the display screen processing method as described in any one of claims 1-7.
10. A computer-readable storage medium storing computer instructions thereon, characterized in that, When the computer instructions are executed on the display device, the display device performs the display screen processing method as described in any one of claims 1-7.
Citation Information
Patent Citations
An adaptive text image binarization method based on pixel neighborhood features
CN102289668A
Backlight brightness control method, backlight brightness control device and display terminal
CN105047145A