Screen display image simulation generation method, compression algorithm detection method and device

Through the simulation generation method, the corresponding relationship between the pre-generated screen brightness value and the gray scale value is used to calculate the brightness value of each pixel and generate a simulated screen display image, which solves the time-consuming problem of verifying the Demura compensation method in the existing technology and achieves Fast and efficient verification process.

CN117915065BActive Publication Date: 2025-01-21GLENFLY TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211232935.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-10-10
Publication Date
2025-01-21
Estimated Expiration
2042-10-10

AI Technical Summary

Technical Problem

The prior art requires hardware debugging when verifying the quality of Demura compensation method, which consumes a lot of time.

Method used

Provides a screen display image simulation generation method. By obtaining the corresponding relationship between the brightness value and the gray scale value of the pre-generated screen, calculates the brightness value of each pixel, and generates a simulated screen display image according to the preset gamma parameters, reducing the number of Dependence on hardware.

Benefits of technology

Through the simulation generation method, the effect of the Demura compensation method can be quickly verified, significantly reducing time consumption and improving efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117915065B_ABST
    Figure CN117915065B_ABST
Patent Text Reader

Abstract

The present application relates to a method for simulating and generating a screen display image, a compression algorithm detection method, a device and an apparatus. The method comprises: obtaining a first correspondence between a brightness value and a grayscale value of a pre-generated screen; obtaining a grayscale value to be displayed, and calculating a first brightness value of each pixel according to the first correspondence and the grayscale value to be displayed; calculating a second correspondence between a brightness value and a grayscale value according to the first brightness value of each pixel and a preset gamma parameter; obtaining a target display grayscale value of each pixel according to the first brightness value of each pixel and the second correspondence; generating a simulated screen display image according to the target display grayscale value of each pixel. The use of this method can reduce time consumption.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of screen display technology, and in particular to a screen display image simulation generation method, a compression algorithm detection method, an apparatus, a computer device, a storage medium and a computer program product. Background Art

[0002] With the development of OLED screen technology, due to various differences in the production process and production materials, the light-emitting elements in the display terminal will have brightness differences or color differences, which is called mura. The Demura compensation method is mainly to use an optical camera to shoot the screen after lighting the display terminal to obtain the actual brightness data, so as to calculate the compensation parameters of each pixel, and burn the compensation parameters into the display terminal. When displaying, the grayscale value needs to be added with the compensation parameters.

[0003] In traditional technology, in order to verify the quality of the Demura compensation method, the following steps are required: adjust the hardware, use the compressed and decompressed compensation value to compensate the pure color image to be displayed, and obtain the BMP bitmap to be displayed. Display the obtained BMP bitmap on an OLED screen with a MURA effect through a dot screen device, and observe with the human eye whether the pure color picture displayed on the screen has any defects.

[0004] However, the current method of verifying the quality of the demura compensation method requires verification through hardware, which requires operations such as debugging the hardware, and thus takes a lot of time. Summary of the invention

[0005] Based on this, it is necessary to provide a screen display image simulation generation method, compression algorithm detection method, device, computer equipment, computer readable storage medium and computer program product that can reduce time consumption in response to the above technical problems.

[0006] In a first aspect, the present application provides a method for simulating and generating a screen display image, the method comprising:

[0007] Obtaining a first correspondence between a brightness value and a grayscale value of a screen generated in advance;

[0008] Acquire the grayscale value to be displayed, and calculate the first brightness value of each pixel according to the first corresponding relationship and the grayscale value to be displayed;

[0009] Calculating a second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and a preset gamma parameter;

[0010] Obtaining a target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship;

[0011] A simulated screen display image is generated according to the target display grayscale value of each pixel.

[0012] In one embodiment, calculating the second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and a preset gamma parameter includes:

[0013] Initialize the scaling factor in the second corresponding relationship between the brightness value and the grayscale value to obtain the initialization scaling factor, and obtain the grayscale value to be processed of each pixel according to the initialization scaling factor, the first brightness value of each pixel, the preset gamma parameter and the second corresponding relationship;

[0014] Calculate the target grayscale value according to the grayscale value to be processed of each pixel;

[0015] An intermediate scaling factor is calculated according to the target grayscale value and the grayscale value to be displayed;

[0016] The scaling factor in the second corresponding relationship is updated according to the intermediate scaling factor and the grayscale value to be displayed, so as to obtain an updated second corresponding relationship between the brightness value and the grayscale value.

[0017] In one embodiment, updating the scaling factor in the second corresponding relationship according to the intermediate scaling factor and the grayscale value to be displayed includes:

[0018] When the grayscale value to be displayed is less than the piecewise constant, updating the scaling factor in the second corresponding relationship according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant;

[0019] When the to-be-displayed grayscale value is greater than or equal to the piecewise constant, the intermediate scaling factor is used as the scaling factor in the updated second corresponding relationship.

[0020] In one embodiment, the step of obtaining a pre-generated first correspondence between a brightness value and a grayscale value of a screen includes:

[0021] Collecting the second brightness value of each pixel of the screen at each first grayscale;

[0022] Curve fitting is performed according to each of the first grayscale values ​​and the second brightness value to obtain a first corresponding relationship between the brightness value and the grayscale value.

[0023] In one embodiment, the collecting the second brightness value of each pixel of the screen at each first grayscale includes:

[0024] Collecting the second brightness value of each pixel in different channels at each first grayscale of the screen;

[0025] The performing curve fitting according to each of the first grayscale and the second brightness value to obtain a first corresponding relationship between the brightness value and the grayscale value includes:

[0026] Curve fitting is performed according to each of the first grayscales and the second brightness values ​​to obtain a first corresponding relationship between the brightness value and the grayscale value corresponding to each of the channels.

[0027] In one embodiment, the step of calculating the first brightness value of each pixel according to the first corresponding relationship and the grayscale value to be displayed includes:

[0028] Calculating and obtaining first brightness values ​​of the pixels in the channels according to the first corresponding relationship;

[0029] Obtaining a target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship includes:

[0030] Obtaining a target display grayscale value of each pixel in each channel according to the first brightness value of each pixel in each channel and the second corresponding relationship;

[0031] Generating a simulated screen display image according to the target display grayscale value of each pixel includes:

[0032] The target display grayscale value of one of the channels is used as the current display grayscale value, the current display grayscale value is used to update the target display grayscale values ​​of the other channels, and a simulated screen display image corresponding to each channel is generated according to the updated target display grayscale value of each pixel.

[0033] In a second aspect, the present application further provides a compression algorithm detection method, the compression algorithm detection method comprising:

[0034] According to the above-mentioned screen display image simulation generation method, respectively simulate the first screen display image before using the compression algorithm and the second screen display image after using the compression algorithm;

[0035] The compression algorithm is detected based on the first screen display image and the second screen display image.

[0036] In a third aspect, the present application further provides a screen display image simulation device, the device comprising:

[0037] A first correspondence relationship acquisition module, used to acquire a pre-generated first correspondence relationship between a brightness value and a grayscale value of a screen;

[0038] a first brightness value calculation module, used for acquiring a grayscale value to be displayed, and calculating a first brightness value of each pixel according to the first corresponding relationship and the grayscale value to be displayed;

[0039] A second corresponding relationship acquisition module, used for calculating a second corresponding relationship between the brightness value and the grayscale value according to the first brightness value of each pixel and a preset gamma parameter;

[0040] a target display grayscale value calculation module, configured to obtain a target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship;

[0041] The simulation module is used to generate a simulated screen display image according to the target display grayscale value of each pixel.

[0042] In a fourth aspect, the present application further provides a compression algorithm detection method, the compression algorithm detection method comprising:

[0043] A display image generation module, used to simulate the first screen display image before using the compression algorithm and the second screen display image after using the compression algorithm according to the above-mentioned screen display image simulation device;

[0044] A detection module is used to detect the compression algorithm based on the first screen display image and the second screen display image.

[0045] 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 above embodiments when executing the computer program.

[0046] 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 above embodiments are implemented.

[0047] In a seventh aspect, the present application also provides a computer program product, including a computer program, which, when executed by a processor, implements the steps of the method described in any one of the above embodiments.

[0048] The above-mentioned screen display image simulation generation method, compression algorithm detection method, device, computer equipment, storage medium and computer program product obtain a first correspondence between the brightness value and the grayscale value of a pre-generated screen, and calculate the first brightness value of each pixel based on the first correspondence between the brightness value and the grayscale value and the grayscale value to be displayed, so as to calculate the second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and the preset gamma parameter, and then calculate the target display grayscale value that can be obtained according to the second correspondence and the first brightness value to simulate the screen display image. In this way, the screen display image is obtained by simulation, and no hardware debugging and other processes are required, and only software processing is required, which reduces time consumption. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 A schematic diagram of a flow chart of a method for simulating and generating a screen display image in one embodiment;

[0050] Figure 2 is a schematic flow chart of a step of generating a second corresponding relationship in one embodiment;

[0051] Figure 3 A schematic diagram of a flow chart of a compression algorithm detection method in one embodiment;

[0052] Figure 4 This is a simulation diagram of a display image of an OLED screen in an embodiment when DEMURA is not performed;

[0053] Figure 5 This is a simulation diagram of a display image when an OLED screen performs DEMURA in one embodiment;

[0054] Figure 6 is a structural block diagram of an XXX device in an embodiment;

[0055] Figure 7 is a structural block diagram of an XXX device in an embodiment;

[0056] Figure 8 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0057] 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.

[0058] In one embodiment, Figure 1As shown, a method for simulating and generating a screen display image is provided. This embodiment takes the method applied to a terminal as an example. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:

[0059] S102: Acquire a pre-generated first correspondence between brightness values ​​and grayscale values ​​of the screen.

[0060] Specifically, the first correspondence between the brightness value and the grayscale value can be obtained by collecting the actual data of the screen and performing curve fitting, for example, collecting the brightness value of the screen at a specific grayscale, and performing curve fitting based on the brightness value and the grayscale value to obtain a fitted gamma curve, and the fitted gamma curve can characterize the first correspondence between the brightness value and the grayscale value. The fitted gamma curve is generated in advance based on the measurement data of the screen, and the fitted gamma curve can be a smooth curve or a segmented curve, which is not specifically limited here. Since the screen and the R&D personnel can be located in different geographical locations, the screen can be measured in advance to obtain a fitted gamma curve, and the fitted gamma curve can be associated with the unique identifier of the corresponding screen and stored, so that when used, the pre-generated fitted gamma curve can be directly obtained according to the unique identifier of the screen to be detected.

[0061] In practical applications, the brightness values ​​of the screen at several first grayscale values ​​can be measured, so that a fitted gamma curve can be fitted based on several pairs of first grayscale values ​​and brightness values. In an optional embodiment, several first grayscale values ​​can be determined in different grayscale intervals, and the brightness values ​​at the first grayscale values ​​can be collected, and then the fitted gamma curves corresponding to different intervals can be fitted in different grayscale intervals, and finally connected to obtain the gamma curve of the complete grayscale interval, wherein the grayscale interval can be [0,64), [64,128) and [128,255]. In other embodiments, the grayscale interval can be other segments, which are not specifically limited here.

[0062] S104: Obtain the grayscale value to be displayed, and calculate the first brightness value of each pixel according to the first corresponding relationship between the brightness value and the grayscale value and the grayscale value to be displayed.

[0063] Specifically, the grayscale value to be displayed refers to the grayscale value to be displayed corresponding to the simulated screen display image, wherein the grayscale value to be displayed may be one or more, and the number of grayscale values ​​to be displayed is not limited here, and the operation of each grayscale value to be displayed is as described in the embodiment, and only needs to be repeated or processed in parallel. The first brightness value is calculated based on the first corresponding relationship between the brightness value and the grayscale value and the grayscale value to be displayed, and there may be a deviation between the brightness value under the grayscale value to be displayed that is actually measured, and the existence of the deviation is caused by the first corresponding relationship between the brightness value and the grayscale value, but the first brightness value can basically characterize the brightness of each pixel.

[0064] In practical applications, the first corresponding relationship between the brightness value and the grayscale value can be expressed by the following formula:

[0065] L=S·G gamma_0

[0066] Wherein, S and gamma_0 are parameters obtained by fitting, G is the grayscale value to be displayed, and L is the first brightness value.

[0067] S106: Calculate a second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and a preset gamma parameter.

[0068] Specifically, the preset gamma parameter is a parameter in the preset second corresponding relationship, for example, gamma_1=2.2. In other embodiments, the gamma parameter may also select other values, but generally 2.2 is used, which is not specifically limited here.

[0069] The second corresponding relationship is a second corresponding relationship between brightness value and grayscale value, which can be specifically expressed by the following formula:

[0070]

[0071] Among them, S' and gamma_1 are parameters, wherein the gamma_1 parameter is pre-assigned to 2.2, so S' can be obtained to obtain the above-mentioned second corresponding relationship. For this reason, in this embodiment, the scaling factor S' is calculated according to the first brightness value of each pixel and the preset gamma parameter. The calculation method can be to initialize the scaling factor S' first, so as to calculate the grayscale value to be processed without considering the influence of the scaling factor S', so that the target grayscale value is calculated according to the grayscale value to be processed, and then the intermediate scaling factor is calculated according to the target grayscale value and the grayscale value to be displayed, for example, the calculation is performed according to the ratio of the two, and then the scaling factor S' is calculated according to the intermediate scaling factor. The scaling factor S' can be regarded as a magnification factor of the grayscale value. When the grayscale value to be displayed is lower than the piecewise constant, the magnification factor can be calculated according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant. When the grayscale value to be displayed is higher than or equal to the piecewise constant, the intermediate grayscale value can be directly used, so as to avoid the simulated screen display image from being too bright or too dark.

[0072] S108: Obtaining a target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship.

[0073] S110: Generate a simulated screen display image according to the target display grayscale value of each pixel.

[0074] The target display grayscale value corresponds to the first brightness value under the second corresponding relationship. The first brightness value is theoretically, that is, the brightness value corresponding to the grayscale to be displayed, so the target display grayscale value is obtained by reverse calculation based on the first brightness value, that is, the grayscale value corresponding to the simulated screen display image.

[0075] After the target display grayscale value is calculated, the corresponding BMP bitmap is generated, which is the simulated screen display image.

[0076] The above-mentioned screen display image simulation generation method obtains a first correspondence between the brightness value and the grayscale value of a pre-generated screen, and calculates the first brightness value of each pixel according to the first correspondence between the brightness value and the grayscale value and the grayscale value to be displayed, thereby calculating the second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and a preset gamma parameter, and then according to the second correspondence and the first brightness value, that is, the target display grayscale value can be obtained to simulate the screen display image. In this way, the screen display image is obtained by simulation, and no hardware debugging or other processes are required, and only software processing is required, which reduces time consumption.

[0077] In one of the embodiments, the above-mentioned step S106, that is, calculating the second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and the preset gamma parameter, includes: initializing the scaling factor in the second correspondence between the brightness value and the grayscale value to obtain the initialization scaling factor, and obtaining the grayscale value to be processed of each pixel according to the initialization scaling factor, the first brightness value of each pixel, the preset gamma parameter and the second correspondence; calculating the target grayscale value according to the grayscale value to be processed of each pixel; calculating the intermediate scaling factor according to the target grayscale value and the grayscale value to be displayed; updating the scaling factor in the second correspondence according to the intermediate scaling factor and the grayscale value to be displayed, to obtain the updated second correspondence between the brightness value and the grayscale value.

[0078] In one of the embodiments, the scaling factor in the second corresponding relationship is updated according to the intermediate scaling factor and the grayscale value to be displayed, including: when the grayscale value to be displayed is less than the piecewise constant, the scaling factor in the second corresponding relationship is updated according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant; when the grayscale value to be displayed is greater than or equal to the piecewise constant, the intermediate scaling factor is used as the scaling factor in the updated second corresponding relationship.

[0079] Specifically, this embodiment mainly introduces the process of generating the second corresponding relationship, wherein the main purpose of generating the second corresponding relationship is to calculate the corresponding target display grayscale value according to the first brightness value.

[0080] For the convenience of the following description, the new terms introduced are first explained. The initialization scaling factor is to reduce the influence of the scaling factor, so the initialization scaling factor is generally 1. In other embodiments, other values ​​may also be used. The grayscale value to be processed is the grayscale value of each pixel corresponding to the first brightness value when there is no influence of the scaling factor. The target grayscale value is the data statistical value of the grayscale value to be processed of each pixel in the entire image when the first brightness value is fixed, such as the average value. In other embodiments, other mathematical statistical values ​​may also be used to characterize it, which is not specifically limited here. The intermediate scaling factor is used to measure the relationship between the grayscale value to be displayed and the target grayscale value, for example, it can be characterized by a proportional relationship. In other embodiments, it can also be characterized by other mathematical relationships such as difference, which is not specifically limited here. The multiple constant is a multiple used to amplify the grayscale value. When the grayscale value to be displayed is lower than the piecewise constant, the amplification factor is calculated by the intermediate scaling factor, the grayscale value to be displayed and the multiple constant. In one embodiment, the multiple constant is selected as 128. In other embodiments, other values ​​may also be used. The piecewise constant is used to segment the grayscale value, that is, to segment the interval 0-255, wherein the piecewise constant can optionally be 128. In other embodiments, other piecewise constants can also be used, but it should be noted that the piecewise constant and the multiple constant have no relationship. In addition, in one of the optional embodiments, the piecewise constant can include multiple, so that multiple segmented intervals are obtained, and the multiple constant of each segmented interval can be the same or different, which is not specifically limited here.

[0081] In practical applications, combined with Figure 2 As shown, first, the scaling factor in the second corresponding relationship is initialized, that is, the initialization scaling factor S′=1 is set, which can reduce the influence of the scaling factor, and the first brightness value of each pixel is substituted into the second corresponding relationship to obtain the grayscale value to be processed of each pixel, and the mathematical statistics of the grayscale values ​​to be processed of all pixels are calculated as the target grayscale value, for example, the average value of the grayscale values ​​to be processed of all pixels is calculated to obtain the target grayscale value. The intermediate scaling factor S″ is calculated based on the target grayscale value and the grayscale value to be displayed, where the intermediate scaling factor S″ Where K n is the grayscale value to be displayed. Finally, the scaling factor in the second corresponding relationship is updated according to the intermediate scaling factor and the grayscale value to be displayed, so as to obtain the updated second corresponding relationship between the brightness value and the grayscale value.

[0082] In one embodiment, updating the scaling factor in the second corresponding relationship according to the intermediate scaling factor and the grayscale value to be displayed to obtain the updated second corresponding relationship between the brightness value and the grayscale value may include: first determining the relationship between the grayscale value to be displayed and the piecewise constant, when the grayscale value to be displayed is less than the piecewise constant, obtaining the multiple constant, and updating the scaling factor in the second corresponding relationship according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant; when the grayscale value to be displayed is greater than or equal to the piecewise constant, using the intermediate scaling factor as the scaling factor in the updated second corresponding relationship.

[0083] For ease of understanding, the second corresponding relationship can be expressed by the following formula:

[0084]

[0085] Among them, C is a multiple constant, which is generally 128, and d is a piecewise constant, which is generally 128. However, it should be noted that there is no relationship between the piecewise constant and the multiple constant.

[0086] In the above embodiment, by setting a suitable scaling factor, it is possible to avoid the simulated screen display image being too bright or too dark.

[0087] In one of the embodiments, obtaining a pre-generated first correspondence between brightness values ​​and grayscale values ​​of a screen includes: collecting a second brightness value of each pixel of the screen at each first grayscale; performing curve fitting according to each first grayscale and second brightness value to obtain a first correspondence between brightness values ​​and grayscale values.

[0088] The first correspondence is obtained by collecting the actual data of the screen, for example, by using a CCD camera to collect the second brightness value of each pixel of the screen at a specific first grayscale. The second brightness value can be regarded as the actual brightness value of each pixel at a specific first grayscale. The number of the first grayscale is at least 3, and then the gamma curve of each pixel is obtained by curve fitting, that is, the first correspondence between the grayscale value and the brightness value:

[0089] L=S·G gamma_0

[0090] Where L represents the brightness value, G represents the grayscale value, and S and gamma_0 are the fitted parameters.

[0091] One point that needs to be explained is that in actual applications, the brightness values ​​of the screen at several first grayscale values ​​can be measured, so that a fitted gamma curve can be fitted based on several pairs of first grayscale values ​​and brightness values. In an optional embodiment, several first grayscale values ​​can be determined in different grayscale intervals, and the brightness values ​​at the first grayscale values ​​can be collected, and then the fitted gamma curves corresponding to different intervals can be fitted in different grayscale intervals, and finally connected to obtain the gamma curve of the complete grayscale interval, wherein the grayscale interval can be [0,64), [64,128) and [128,255]. In other embodiments, the grayscale interval can be other segments, which are not specifically limited here.

[0092] In one of the optional embodiments, the second brightness value of each pixel of the screen at each first gray scale is collected, including: collecting the second brightness value of each pixel of the screen at each first gray scale in different channels; performing curve fitting according to each first gray scale and the second brightness value to obtain a first corresponding relationship between the brightness value and the gray scale value, including: performing curve fitting according to each first gray scale and the second brightness value to obtain a first corresponding relationship between the brightness value corresponding to each channel and the gray scale value.

[0093] Since each pixel includes three channels of RGB, in order to ensure the accuracy of processing, the three channels are processed separately when determining the first corresponding relationship, that is, the second brightness value of each pixel in different channels under each first grayscale of the screen is collected separately, and then the first grayscale and the second brightness value are curve fitted separately to obtain the first corresponding relationship corresponding to each channel. In this way, three corresponding relationships can be obtained, corresponding to the three channels respectively.

[0094] In one of the embodiments, the first brightness values ​​of each pixel are calculated according to the first corresponding relationship and the grayscale value to be displayed, including: calculating the first brightness values ​​of each pixel in each channel according to the first corresponding relationship; obtaining the target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship, including: obtaining the target display grayscale value of each pixel in each channel according to the first brightness value of each pixel in each channel and the second corresponding relationship; generating a simulated screen display image according to the target display grayscale value of each pixel, including: using the target display grayscale value of one of the channels as the current display grayscale value, updating the target display grayscale values ​​of other channels with the current display grayscale value, and generating a simulated screen display image corresponding to each channel according to the updated target display grayscale value of each pixel.

[0095] In this embodiment, since the pixel includes three channels, the three channels are calculated separately, that is, the first brightness value of each pixel in each channel is calculated according to the first corresponding relationship, and the target display grayscale value of each pixel in each channel is obtained according to the first brightness value of each pixel in each channel and the second corresponding relationship.

[0096] In order to ensure the relative accuracy of the screen display image, each channel is calculated separately. For example, the target display grayscale value of one of the channels is used as the current display grayscale value, the current display grayscale value is used to update the target display grayscale value of other channels, and the simulated screen display image corresponding to each channel is generated according to the updated target display grayscale value of each pixel.

[0097] For ease of understanding, the target display grayscale of the R channel is 135, so the target display grayscale of the other two channels, namely the B channel and the G channel, is also set to 135. In this way, the simulated screen display image obtained is a pure color image, which is convenient for viewing. Then, the B channel is used as the current channel in turn, and the target display grayscale value of the B channel is obtained as the current display grayscale value. The operation of the R channel is performed to obtain the simulated screen display image corresponding to the B channel. Similarly, the operation of the G channel is the same as that of the R channel, which will not be repeated here. In this way, multiple simulated screen display images can be obtained for one screen, which is convenient for users to view and improves accuracy.

[0098] In one embodiment, Figure 3 As shown, a compression algorithm detection method is provided. This embodiment takes the method applied to a terminal as an example for illustration. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:

[0099] S302: According to the screen display image simulation generation method in any one of the above embodiments, respectively simulate a first screen display image before using the compression algorithm and a second screen display image after using the compression algorithm.

[0100] S304: Detecting a compression algorithm based on the first screen display image and the second screen display image.

[0101] Specifically, the method for generating the first screen display image and the second screen display image can be referred to above and will not be repeated here. It should be noted that the first screen display image and the second screen display image can be generated by parallel processing. In addition, in one of the embodiments, the first screen display image and the second screen display image need to be images of the same channel to facilitate subsequent detection and comparison. Optionally, the first screen display image and the second screen display image of the three channels can be generated respectively, and then the first screen display image and the second screen display image of the corresponding channel are compared to detect the compression algorithm.

[0102] It should be noted that the screen may be an OLED screen or other types of screens. The compression algorithm may be a DEMURA algorithm or any other algorithm, which is not specifically limited here.

[0103] For easier understanding, see Figure 4 and Figure 5 ,in Figure 4 This is a simulation diagram of the display image of the OLED screen in an embodiment when DEMURA is not performed. Figure 5 This is a simulation diagram of a display image when an OLED screen performs DEMURA in one embodiment, wherein Figure 4 It can be seen that the screen without DEMURA compensation will have uneven brightness MURA effect when displaying images. Figure 5 It can be seen that after DEMURA compensation, the screen no longer has the MURA phenomenon of uneven brightness when displaying images, which reflects that the method of simulating OLED screen display images proposed in the present invention can reflect the actual display effect of the OLED screen to a certain extent.

[0104] In the above embodiment, when verifying the quality of the compression algorithm, there is no need for a research and development trip. The first screen display image and the second screen display image can be simulated by the method in this embodiment, and then the quality of the compression algorithm can be determined by the first screen display image and the second screen display image. This can reduce the research and development time of the compression algorithm.

[0105] It should be understood that, although the steps in the flowcharts involved in the above 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 is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above embodiments may 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 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.

[0106] Based on the same inventive concept, the embodiments of the present application also provide a screen display image simulation generation device and a compression algorithm detection device for implementing the screen display image simulation generation method and the compression algorithm detection method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more embodiments of the screen display image simulation generation device and the compression algorithm detection device provided below can refer to the limitations of the screen display image simulation generation method and the compression algorithm detection method above, and will not be repeated here.

[0107] In one embodiment, Figure 6 As shown, a screen display image simulation generation device is provided, comprising: a first corresponding relationship acquisition module 601, a first brightness value calculation module 602, a second corresponding relationship acquisition module 603, a target display grayscale value calculation module 604 and a simulation module 605, wherein:

[0108] A first correspondence relationship acquisition module 601 is used to acquire a pre-generated first correspondence relationship between a brightness value and a grayscale value of a screen;

[0109] A first brightness value calculation module 602, used to obtain a grayscale value to be displayed, and calculate a first brightness value of each pixel according to a first corresponding relationship between the brightness value and the grayscale value and the grayscale value to be displayed;

[0110] A second correspondence relationship acquisition module 603, used to calculate a second correspondence relationship between a brightness value and a grayscale value according to a first brightness value of each pixel and a preset gamma parameter;

[0111] A target display grayscale value calculation module 604 is used to obtain a target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship;

[0112] The simulation module 605 is used to generate a simulated screen display image according to the target display grayscale value of each pixel.

[0113] In one embodiment, the second correspondence relationship acquisition module 603 includes:

[0114] a grayscale value calculation unit to be processed, configured to initialize a scaling factor in a second correspondence between brightness value and grayscale value to obtain an initialization scaling factor, and obtain a grayscale value to be processed for each pixel according to the initialization scaling factor, the first brightness value of each pixel, a preset gamma parameter and the second correspondence;

[0115] A target grayscale value calculation unit, used for calculating a target grayscale value according to the grayscale value to be processed of each pixel;

[0116] An intermediate scaling factor calculation unit, used for calculating an intermediate scaling factor according to a target grayscale value and a grayscale value to be displayed;

[0117] The second correspondence determination unit is used to update the scaling factor in the second correspondence according to the intermediate scaling factor and the grayscale value to be displayed, so as to obtain an updated second correspondence between the brightness value and the grayscale value.

[0118] In one of the embodiments, the second correspondence determination unit is also used to update the scaling factor in the second correspondence according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant when the grayscale value to be displayed is less than the piecewise constant; when the grayscale value to be displayed is greater than or equal to the piecewise constant, the intermediate scaling factor is used as the scaling factor in the updated second correspondence.

[0119] In one embodiment, the first correspondence relationship acquisition module 601 includes:

[0120] A collection unit, used for collecting a second brightness value of each pixel of the screen at each first grayscale;

[0121] The fitting unit is used to perform curve fitting according to each first grayscale and second brightness value to obtain a first corresponding relationship between the brightness value and the grayscale value.

[0122] In one embodiment, the acquisition unit is further used to acquire the second brightness value of each pixel in different channels at each first grayscale of the screen;

[0123] The fitting unit is further used to perform curve fitting according to each first grayscale and second brightness value to obtain a first corresponding relationship between the brightness value and the grayscale value corresponding to each channel.

[0124] In one embodiment, the first brightness value calculation module 602 is further used to calculate the first brightness value of each pixel in each channel according to the first corresponding relationship between the brightness value and the grayscale value;

[0125] The target display grayscale value calculation module 604 is further used to obtain the target display grayscale value of each pixel in each channel according to the first brightness value of each pixel in each channel and the second corresponding relationship;

[0126] The above-mentioned simulation module 605 is also used to use the target display grayscale value of one of the channels as the current display grayscale value, update the target display grayscale values ​​of other channels with the current display grayscale value, and generate a simulated screen display image corresponding to each channel according to the updated target display grayscale value of each pixel.

[0127] In one embodiment, Figure 7 As shown, a compression algorithm detection device is provided, including: a display image generation module 701 and a detection module 702, wherein:

[0128] A display image generating module 701, used for simulating a first screen display image before using a compression algorithm and a second screen display image after using a compression algorithm according to the screen display image simulation device of any of the above embodiments;

[0129] The detection module 702 is used to detect the compression algorithm based on the first screen display image and the second screen display image.

[0130] Each module in the above-mentioned screen display image simulation generation device and compression algorithm detection device can be implemented in whole or in part by software, hardware and their combination. Each of the above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory in the computer device in the form of software, so that the processor can call and execute the corresponding operations of each of the above modules.

[0131] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 8 As shown. The computer device includes a processor, a memory, a communication interface, a display screen and an input device connected through a system bus. 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 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 achieved through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a screen display image simulation generation method and a compression algorithm detection method are implemented. The display screen of the computer device 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 covered on the display screen, or a key, trackball or touchpad set on the computer device housing, or an external keyboard, touchpad or mouse, etc.

[0132] Those skilled in the art will understand that Figure 8 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.

[0133] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the following steps when executing the computer program: obtaining a first correspondence between brightness values ​​and grayscale values ​​of a pre-generated screen; obtaining a grayscale value to be displayed, and calculating a first brightness value of each pixel based on the first correspondence between the brightness value and the grayscale value and the grayscale value to be displayed; calculating a second correspondence between the brightness value and the grayscale value based on the first brightness value of each pixel and a preset gamma parameter; obtaining a target display grayscale value of each pixel based on the first brightness value of each pixel and the second correspondence; and generating a simulated screen display image based on the target display grayscale value of each pixel.

[0134] In one embodiment, the processor executes a computer program to calculate a second correspondence between brightness values ​​and grayscale values ​​based on a first brightness value of each pixel and a preset gamma parameter, including: initializing a scaling factor in the second correspondence between brightness values ​​and grayscale values ​​to obtain an initialization scaling factor, and obtaining a grayscale value to be processed for each pixel based on the initialization scaling factor, the first brightness value of each pixel, the preset gamma parameter, and the second correspondence; calculating a target grayscale value based on the grayscale value to be processed for each pixel; calculating an intermediate scaling factor based on the target grayscale value and the grayscale value to be displayed; and updating the scaling factor in the second correspondence based on the intermediate scaling factor and the grayscale value to be displayed to obtain an updated second correspondence between brightness values ​​and grayscale values.

[0135] In one embodiment, the updating of the scaling factor in the second corresponding relationship according to the intermediate scaling factor and the grayscale value to be displayed implemented when the processor executes the computer program includes: when the grayscale value to be displayed is less than the piecewise constant, updating the scaling factor in the second corresponding relationship according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant; when the grayscale value to be displayed is greater than or equal to the piecewise constant, using the intermediate scaling factor as the scaling factor in the updated second corresponding relationship.

[0136] In one embodiment, the first correspondence between the brightness value and the grayscale value of the pre-generated screen is obtained when the processor executes a computer program, including: collecting the second brightness value of each pixel of the screen at each first grayscale; performing curve fitting according to each first grayscale and the second brightness value to obtain the first correspondence between the brightness value and the grayscale value.

[0137] In one embodiment, the capture of the second brightness value of each pixel on the screen at each first gray scale implemented when the processor executes the computer program includes: the capture of the second brightness value of each pixel on the screen at each first gray scale in different channels; the acquisition of the first corresponding relationship between the brightness value and the gray scale value is performed according to the first gray scale and the second brightness value when the processor executes the computer program, including: the acquisition of the first corresponding relationship between the brightness value and the gray scale value is performed according to the first gray scale and the second brightness value.

[0138] In one embodiment, the processor implements the method of calculating the first brightness value of each pixel according to the first correspondence between the brightness value and the grayscale value and the grayscale value to be displayed when executing a computer program, including: calculating the first brightness value of each pixel in each channel according to the first correspondence between the brightness value and the grayscale value; the processor implements the method of obtaining the target display grayscale value of each pixel according to the first brightness value of each pixel and the second correspondence when executing the computer program, including: obtaining the target display grayscale value of each pixel in each channel according to the first brightness value of each pixel in each channel and the second correspondence; the processor implements the method of generating a simulated screen display image according to the target display grayscale value of each pixel when executing the computer program, including: taking the target display grayscale value of one of the channels as the current display grayscale value, updating the target display grayscale values ​​of other channels with the current display grayscale value, and generating a simulated screen display image corresponding to each channel according to the updated target display grayscale value of each pixel.

[0139] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the following steps when executing the computer program: according to the screen display image simulation generation method in any one of the above embodiments, a first screen display image before using a compression algorithm and a second screen display image after using the compression algorithm are simulated respectively; based on the first screen display image and the second screen display image, the compression algorithm is detected.

[0140] 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 following steps are implemented: obtaining a first correspondence between brightness values ​​and grayscale values ​​of a pre-generated screen; obtaining a grayscale value to be displayed, and calculating a first brightness value of each pixel based on the first correspondence between the brightness value and the grayscale value and the grayscale value to be displayed; calculating a second correspondence between the brightness value and the grayscale value based on the first brightness value of each pixel and a preset gamma parameter; obtaining a target display grayscale value of each pixel based on the first brightness value of each pixel and the second correspondence; and generating a simulated screen display image based on the target display grayscale value of each pixel.

[0141] In one embodiment, the computer program implemented when executed by the processor calculates the second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and the preset gamma parameter, including: initializing the scaling factor in the second correspondence between the brightness value and the grayscale value to obtain the initialization scaling factor, and obtaining the grayscale value to be processed of each pixel according to the initialization scaling factor, the first brightness value of each pixel, the preset gamma parameter and the second correspondence; calculating the target grayscale value according to the grayscale value to be processed of each pixel; calculating the intermediate scaling factor according to the target grayscale value and the grayscale value to be displayed; updating the scaling factor in the second correspondence according to the intermediate scaling factor and the grayscale value to be displayed, to obtain the updated second correspondence between the brightness value and the grayscale value.

[0142] In one embodiment, the computer program implemented by the processor when executed by the processor updates the scaling factor in the second corresponding relationship according to the intermediate scaling factor and the grayscale value to be displayed, including: when the grayscale value to be displayed is less than the piecewise constant, updating the scaling factor in the second corresponding relationship according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant; when the grayscale value to be displayed is greater than or equal to the piecewise constant, using the intermediate scaling factor as the scaling factor in the updated second corresponding relationship.

[0143] In one embodiment, the computer program implemented when executed by a processor to obtain a pre-generated first correspondence between brightness values ​​and grayscale values ​​of a screen includes: collecting the second brightness value of each pixel on the screen at each first grayscale; performing curve fitting according to each first grayscale and second brightness value to obtain the first correspondence between brightness values ​​and grayscale values.

[0144] In one embodiment, the computer program implemented when being executed by a processor collects the second brightness value of each pixel on the screen at each first gray scale, including: collecting the second brightness value of each pixel on the screen at each first gray scale in different channels; the computer program implemented when being executed by a processor performs curve fitting according to each first gray scale and the second brightness value to obtain a first correspondence between the brightness value and the gray scale value, including: performs curve fitting according to each first gray scale and the second brightness value to obtain a first correspondence between the brightness value corresponding to each channel and the gray scale value.

[0145] In one embodiment, the computer program implemented when being executed by a processor calculates the first brightness value of each pixel according to the first correspondence between the brightness value and the grayscale value and the grayscale value to be displayed, including: calculating the first brightness value of each pixel in each channel according to the first correspondence between the brightness value and the grayscale value; the computer program implemented when being executed by the processor obtains the target display grayscale value of each pixel according to the first brightness value of each pixel and the second correspondence, including: obtaining the target display grayscale value of each pixel in each channel according to the first brightness value of each pixel in each channel and the second correspondence; the computer program implemented when being executed by the processor generates a simulated screen display image according to the target display grayscale value of each pixel, including: using the target display grayscale value of one of the channels as the current display grayscale value, updating the target display grayscale value of each other channel with the current display grayscale value, and generating a simulated screen display image corresponding to each channel according to the updated target display grayscale value of each pixel.

[0146] 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 following steps are implemented: according to the screen display image simulation generation method in any one of the above embodiments, a first screen display image before using a compression algorithm and a second screen display image after using the compression algorithm are simulated respectively; based on the first screen display image and the second screen display image, the compression algorithm is detected.

[0147] In one embodiment, a computer program product is provided, including a computer program, which implements the following steps when executed by a processor: obtaining a first correspondence between brightness values ​​and grayscale values ​​of a pre-generated screen; obtaining a grayscale value to be displayed, and calculating a first brightness value of each pixel based on the first correspondence between the brightness value and the grayscale value and the grayscale value to be displayed; calculating a second correspondence between the brightness value and the grayscale value based on the first brightness value of each pixel and a preset gamma parameter; obtaining a target display grayscale value of each pixel based on the first brightness value of each pixel and the second correspondence; and generating a simulated screen display image based on the target display grayscale value of each pixel.

[0148] In one embodiment, the computer program implemented when executed by the processor calculates the second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and the preset gamma parameter, including: initializing the scaling factor in the second correspondence between the brightness value and the grayscale value to obtain the initialization scaling factor, and obtaining the grayscale value to be processed of each pixel according to the initialization scaling factor, the first brightness value of each pixel, the preset gamma parameter and the second correspondence; calculating the target grayscale value according to the grayscale value to be processed of each pixel; calculating the intermediate scaling factor according to the target grayscale value and the grayscale value to be displayed; updating the scaling factor in the second correspondence according to the intermediate scaling factor and the grayscale value to be displayed, to obtain the updated second correspondence between the brightness value and the grayscale value.

[0149] In one embodiment, the computer program implemented by the processor when executed by the processor updates the scaling factor in the second corresponding relationship according to the intermediate scaling factor and the grayscale value to be displayed, including: when the grayscale value to be displayed is less than the piecewise constant, updating the scaling factor in the second corresponding relationship according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant; when the grayscale value to be displayed is greater than or equal to the piecewise constant, using the intermediate scaling factor as the scaling factor in the updated second corresponding relationship.

[0150] In one embodiment, the computer program implemented when executed by a processor to obtain a pre-generated first correspondence between brightness values ​​and grayscale values ​​of a screen includes: collecting the second brightness value of each pixel on the screen at each first grayscale; performing curve fitting according to each first grayscale and second brightness value to obtain the first correspondence between brightness values ​​and grayscale values.

[0151] In one embodiment, the computer program implemented when being executed by a processor collects the second brightness value of each pixel on the screen at each first gray scale, including: collecting the second brightness value of each pixel on the screen at each first gray scale in different channels; the computer program implemented when being executed by a processor performs curve fitting according to each first gray scale and the second brightness value to obtain a first correspondence between the brightness value and the gray scale value, including: performs curve fitting according to each first gray scale and the second brightness value to obtain a first correspondence between the brightness value corresponding to each channel and the gray scale value.

[0152] In one embodiment, the computer program implemented when being executed by a processor calculates the first brightness value of each pixel according to the first correspondence between the brightness value and the grayscale value and the grayscale value to be displayed, including: calculating the first brightness value of each pixel in each channel according to the first correspondence between the brightness value and the grayscale value; the computer program implemented when being executed by the processor obtains the target display grayscale value of each pixel according to the first brightness value of each pixel and the second correspondence, including: obtaining the target display grayscale value of each pixel in each channel according to the first brightness value of each pixel in each channel and the second correspondence; the computer program implemented when being executed by the processor generates a simulated screen display image according to the target display grayscale value of each pixel, including: using the target display grayscale value of one of the channels as the current display grayscale value, updating the target display grayscale value of each other channel with the current display grayscale value, and generating a simulated screen display image corresponding to each channel according to the updated target display grayscale value of each pixel.

[0153] 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 following steps are implemented: according to the screen display image simulation generation method in any one of the above embodiments, a first screen display image before using a compression algorithm and a second screen display image after using the compression algorithm are simulated respectively; based on the first screen display image and the second screen display image, the compression algorithm is detected.

[0154] In one embodiment, a computer program product is provided, including a computer program, which, when executed by a processor, implements the following steps: simulating a first screen display image before using a compression algorithm and a second screen display image after using the compression algorithm according to the screen display image simulation generation method in any one of the above embodiments; and detecting the compression algorithm based on the first screen display image and the second screen display image.

[0155] Those skilled 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 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), magnetoresistive 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, etc., but are not limited to this.

[0156] 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 specification.

[0157] 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 simulating and generating a screen display image, characterized in that: The method comprises: Obtaining a first correspondence between a brightness value and a grayscale value of a screen generated in advance; Acquire the grayscale value to be displayed, and calculate the first brightness value of each pixel according to the first corresponding relationship and the grayscale value to be displayed; Calculating a second correspondence between the brightness value and the grayscale value according to the first brightness value of each pixel and a preset gamma parameter; Obtaining a target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship; generating a simulated screen display image according to a target display grayscale value of each of the pixels; The calculating, according to the first brightness value of each pixel and the preset gamma parameter, a second corresponding relationship between the brightness value and the grayscale value comprises: Initialize the scaling factor in the second corresponding relationship between the brightness value and the grayscale value to obtain the initialization scaling factor, and obtain the grayscale value to be processed of each pixel according to the initialization scaling factor, the first brightness value of each pixel, the preset gamma parameter and the second corresponding relationship; Calculate the target grayscale value according to the grayscale value to be processed of each pixel; An intermediate scaling factor is calculated according to the target grayscale value and the grayscale value to be displayed; The scaling factor in the second corresponding relationship is updated according to the intermediate scaling factor and the grayscale value to be displayed, so as to obtain an updated second corresponding relationship between the brightness value and the grayscale value.

2. The method according to claim 1, characterized in that The updating of the scaling factor in the second corresponding relationship according to the intermediate scaling factor and the grayscale value to be displayed includes: When the grayscale value to be displayed is less than the piecewise constant, updating the scaling factor in the second corresponding relationship according to the intermediate scaling factor, the grayscale value to be displayed and the multiple constant; When the to-be-displayed grayscale value is greater than or equal to the piecewise constant, the intermediate scaling factor is used as the scaling factor in the updated second corresponding relationship.

3. The method according to claim 1, characterized in that The obtaining of a pre-generated first correspondence between a brightness value and a grayscale value of a screen includes: Collecting the second brightness value of each pixel of the screen at each first grayscale; Curve fitting is performed according to each of the first grayscales and the second brightness value of each pixel to obtain a first corresponding relationship between the brightness value and the grayscale value.

4. The method according to claim 3, characterized in that The collecting the second brightness value of each pixel of the screen at each first grayscale includes: Collecting the second brightness value of each pixel in different channels at each first grayscale of the screen; The performing curve fitting according to each of the first grayscales and the second brightness value of each pixel to obtain a first corresponding relationship between the brightness value and the grayscale value includes: Curve fitting is performed according to each of the first grayscales and the second brightness value of each pixel in different channels to obtain a first corresponding relationship between the brightness value and the grayscale value corresponding to each of the channels.

5. The method according to claim 1, characterized in that The calculating the first brightness value of each pixel according to the first corresponding relationship and the grayscale value to be displayed includes: Calculating and obtaining first brightness values ​​of the pixels in each channel according to the first corresponding relationship; Obtaining a target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship includes: Obtaining a target display grayscale value of each pixel in each channel according to the first brightness value of each pixel in each channel and the second corresponding relationship; Generating a simulated screen display image according to the target display grayscale value of each pixel includes: The target display grayscale value of one of the channels is used as the current display grayscale value, the current display grayscale value is used to update the target display grayscale values ​​of the other channels, and a simulated screen display image corresponding to each channel is generated according to the updated target display grayscale value of each pixel.

6. A compression algorithm detection method, characterized in that: The compression algorithm detection method comprises: The screen display image simulation generation method according to any one of claims 1 to 5, respectively simulating a first screen display image before using a compression algorithm and a second screen display image after using the compression algorithm; The compression algorithm is detected based on the first screen display image and the second screen display image.

7. A screen display image simulation device, characterized in that: The device comprises: A first correspondence relationship acquisition module, used to acquire a pre-generated first correspondence relationship between a brightness value and a grayscale value of a screen; a first brightness value calculation module, used for acquiring a grayscale value to be displayed, and calculating a first brightness value of each pixel according to the first corresponding relationship and the grayscale value to be displayed; A second corresponding relationship acquisition module, used for calculating a second corresponding relationship between the brightness value and the grayscale value according to the first brightness value of each pixel and a preset gamma parameter; a target display grayscale value calculation module, configured to obtain a target display grayscale value of each pixel according to the first brightness value of each pixel and the second corresponding relationship; A simulation module, used for generating a simulated screen display image according to a target display grayscale value of each pixel; The second corresponding relationship acquisition module includes: a grayscale value calculation unit to be processed, configured to initialize a scaling factor in a second correspondence between brightness value and grayscale value to obtain an initialization scaling factor, and obtain a grayscale value to be processed for each pixel according to the initialization scaling factor, the first brightness value of each pixel, a preset gamma parameter and the second correspondence; A target grayscale value calculation unit, used for calculating a target grayscale value according to the grayscale value to be processed of each pixel; an intermediate scaling factor calculation unit, configured to calculate an intermediate scaling factor according to the target grayscale value and the grayscale value to be displayed; The second correspondence determination unit is used to update the scaling factor in the second correspondence according to the intermediate scaling factor and the grayscale value to be displayed, so as to obtain an updated second correspondence between the brightness value and the grayscale value.

8. A compression algorithm detection device, characterized in that: The compression algorithm detection device comprises: A display image generation module, used for simulating the first screen display image before using the compression algorithm and the second screen display image after using the compression algorithm according to the screen display image simulation device of claim 7; A detection module is used to detect the compression algorithm based on the first screen display image and the second screen display image.

9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 5 or 6 are implemented.

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

11. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 or 6 are implemented.

Citation Information

Patent Citations

  • Quality evaluation method for video lossy compression

    CN101478697A

  • Gray scale compensation method, device and system of display panel

    CN110599961A