CN116993652A - Method, device, equipment, medium and product for determining picture quality of screenshot - Google Patents
Method, device, equipment, medium and product for determining picture quality of screenshot Download PDFInfo
- Publication number
- CN116993652A CN116993652A CN202211097198.0A CN202211097198A CN116993652A CN 116993652 A CN116993652 A CN 116993652A CN 202211097198 A CN202211097198 A CN 202211097198A CN 116993652 A CN116993652 A CN 116993652A
- Authority
- CN
- China
- Prior art keywords
- screenshot
- quality
- video frame
- video
- determining
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 125
- 230000008569 process Effects 0.000 claims abstract description 60
- 230000001960 triggered effect Effects 0.000 claims abstract description 10
- 238000013139 quantization Methods 0.000 claims description 93
- 238000007906 compression Methods 0.000 claims description 51
- 230000006835 compression Effects 0.000 claims description 41
- 230000006870 function Effects 0.000 claims description 13
- 238000004590 computer program Methods 0.000 claims description 10
- 230000004044 response Effects 0.000 claims description 6
- 230000002159 abnormal effect Effects 0.000 claims description 3
- 239000000523 sample Substances 0.000 claims 1
- 238000013441 quality evaluation Methods 0.000 abstract description 27
- 238000012545 processing Methods 0.000 abstract description 8
- 238000010586 diagram Methods 0.000 description 10
- 238000004364 calculation method Methods 0.000 description 7
- 238000012854 evaluation process Methods 0.000 description 6
- 238000011156 evaluation Methods 0.000 description 4
- 239000011159 matrix material Substances 0.000 description 3
- 238000013135 deep learning Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 2
- 230000003287 optical effect Effects 0.000 description 2
- 238000012935 Averaging Methods 0.000 description 1
- 230000005856 abnormality Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 210000004556 brain Anatomy 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000004891 communication Methods 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- 238000010606 normalization Methods 0.000 description 1
- 230000011218 segmentation Effects 0.000 description 1
- 230000002123 temporal effect Effects 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/0002—Inspection of images, e.g. flaw detection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10016—Video; Image sequence
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/30—Subject of image; Context of image processing
- G06T2207/30168—Image quality inspection
Landscapes
- Engineering & Computer Science (AREA)
- Quality & Reliability (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
The application discloses a method, a device, equipment, a medium and a product for determining the quality of a picture of a screenshot, and belongs to the technical field of image processing. The method comprises the following steps: responding to a screenshot instruction, acquiring video frame parameters of a target video frame, wherein the screenshot instruction is triggered by screenshot operation of a video picture, the target video frame is a video frame corresponding to the video picture, and the video frame parameters are parameters affecting the quality of the video frame in the video encoding and decoding process; determining a first influence factor of video frame quality on screenshot quality based on the video frame parameters; determining a second influence factor of the screenshot operation on screenshot quality; and determining the screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor and the second influence factor. According to the method, the influence of the original video frame information and the distortion loss caused by the screenshot operation on the screenshot quality can be fully considered in the screenshot quality evaluation process, and the accuracy of the screenshot quality evaluation is effectively improved.
Description
Technical Field
The present application relates to the field of image processing technologies, and in particular, to a method, an apparatus, a device, a medium, and a product for determining quality of a captured image.
Background
In the video field, when a user views a classical picture, there may be a need to save the classical picture, and a terminal is typically provided with a screenshot function so that the user can use the screenshot function to intercept a specific video picture from a video clip, thereby generating a screenshot to save in the terminal. In the screenshot process, the change and distortion of the picture information may occur, and how to evaluate the picture quality of the screenshot is important for judging the screenshot function.
In the related art, a deep learning mode can be used for evaluating the picture quality of the screenshot; the relation between the screenshot and the picture quality score is established in advance through the picture quality evaluation model, so that the screenshot can be input into the picture quality evaluation model in the application process, and the picture quality score output by the picture quality evaluation model can be obtained, so that the screenshot quality evaluation is completed.
However, the quality evaluation of the screenshot by adopting a deep learning mode does not refer to the original picture information, so that the accuracy of the quality evaluation of the screenshot is lower.
Disclosure of Invention
The application provides a method, a device, equipment, a medium and a product for determining the quality of a screenshot, which can improve the accuracy of determining the quality of the screenshot. The technical scheme is as follows:
According to an aspect of the present application, there is provided a method for determining picture quality of a screenshot, the method comprising:
responding to a screenshot instruction, acquiring video frame parameters of a target video frame, wherein the screenshot instruction is triggered by screenshot operation of a video picture, the target video frame is a video frame corresponding to the video picture, and the video frame parameters are parameters affecting the quality of the video frame in the video encoding and decoding process;
determining a first influence factor of video frame quality on screenshot quality based on the video frame parameters;
determining a second influence factor of the screenshot operation on screenshot quality;
and determining the screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor and the second influence factor.
According to another aspect of the present application, there is provided a method for determining picture quality of a screenshot, the apparatus including:
the acquisition module is used for responding to a screenshot instruction, acquiring video frame parameters of a target video frame, wherein the screenshot instruction is triggered by screenshot operation of a video picture, the target video frame is a video frame corresponding to the video picture, and the video frame parameters are parameters affecting the video frame quality in the video encoding and decoding process;
The determining module is used for determining a first influence factor of video frame quality on screenshot quality based on the video frame parameters;
the determining module is further configured to determine a second influence factor of the screenshot operation on screenshot quality;
and the determining module is further used for determining the screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor and the second influence factor.
According to another aspect of the present application, there is provided a computer apparatus comprising: a processor and a memory storing a computer program that is loaded and executed by the processor to implement the picture quality determination method of a screenshot as described in the above aspect.
According to another aspect of the present application, there is provided a computer-readable storage medium storing a computer program loaded and executed by a processor to implement a picture quality determination method of a screenshot as described above.
According to another aspect of the present application, a computer program product is provided, the computer program product comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the method for determining the picture quality of the screenshot.
The technical scheme provided by the embodiment of the application has the beneficial effects that at least:
the embodiment of the application provides a screenshot quality evaluation method, which comprises the following steps: in the process of capturing video images to generate the target capturing images, the video frame quality of the target video frames and the distortion loss caused by the capturing operation can influence the capturing image quality of the target capturing images, so that the influence factors of the video frame quality and the capturing operation on the capturing image quality are respectively calculated on two dimensions, and the capturing image quality of the target capturing images is determined according to the first influence factor (the influence factor of the video frame quality dimension on the capturing image quality) and the second influence factor (the influence factor of the capturing operation on the capturing image quality). In the screenshot quality evaluation process, the influence of the original video frame information and the distortion loss caused by screenshot operation on the screenshot quality can be fully considered, and the accuracy of the screenshot quality evaluation is effectively improved; and the screenshot quality evaluation process can be performed in real time in the screenshot operation process, and the comparison calculation of the original video frame and the screenshot is not required after the screenshot operation is completed, so that additional information calculation work can be avoided, and the screenshot quality evaluation efficiency is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for the description of the embodiments will be briefly described below, and it is apparent that the drawings in the following description are only some embodiments of the present application, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 illustrates a flowchart of a method for determining picture quality of a screenshot provided by an exemplary embodiment of the application;
FIG. 2 illustrates a flowchart of a method for determining picture quality of a screenshot provided by another exemplary embodiment of the application;
FIG. 3 illustrates a schematic diagram of an evaluation process of screenshot quality shown in an exemplary embodiment of the application;
FIG. 4 illustrates a flowchart of a method for determining picture quality of a screenshot provided by another exemplary embodiment of the application;
FIG. 5 illustrates a schematic diagram of an evaluation process of screenshot quality shown in another exemplary embodiment of the application;
FIG. 6 illustrates a flowchart of a method for determining picture quality of a screenshot provided by another exemplary embodiment of the application;
FIG. 7 shows a schematic diagram of an evaluation process of screenshot quality shown in another exemplary embodiment of the application;
FIG. 8 is a block diagram of a picture quality determination apparatus for a screenshot provided in accordance with an exemplary embodiment of the application;
fig. 9 is a schematic diagram of a computer device, according to an example embodiment.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present application more apparent, the embodiments of the present application will be described in further detail with reference to the accompanying drawings.
Referring to fig. 1, a flowchart of a method for determining picture quality of a screenshot according to an exemplary embodiment of the present application is illustrated, where the method is applied to a computer device, and the method includes:
step 101, in response to a screenshot instruction, obtaining a video frame parameter of a target video frame, wherein the screenshot instruction is triggered by a screenshot operation of a video picture, the target video frame is a video frame corresponding to the video picture, and the video frame parameter is a parameter affecting the quality of the video frame in the video encoding and decoding process.
In the video field, a user can use a screenshot function to screenshot a certain video picture in a video to obtain a screenshot picture; the screenshot process is essentially a process of picture compression of video frames. In a possible implementation manner, when the computer device receives the screenshot operation of the video frame and generates the screenshot instruction, the background of the computer device can determine the target video frame corresponding to the video frame according to the video frame indicated by the screenshot instruction, so as to compress the target video frame and generate the target screenshot.
Since the target screenshot is generated according to the target video frame, if the video frame quality of the target video frame is higher, obviously, the picture quality of the target screenshot is higher, and if the video frame quality of the target video frame is lower, the picture quality of the target screenshot is also reduced; when the picture quality of the target screenshot is evaluated, relevant parameters of video frame quality corresponding to the target video frame can be introduced. In this embodiment, when the computer device receives the screenshot instruction and determines the target video frame corresponding to the video frame, the video frame parameter affecting the video frame quality in the video encoding and decoding process can be obtained, so that the screenshot can be used for evaluating the picture quality subsequently.
Illustratively, the video frame parameters may include: the number of encoding bits (the greater the number of encoding bits, the higher the video frame quality), the video frame resolution (the greater the video resolution, the higher the video frame quality), the average quantization parameter (the smaller the average quantization parameter, the higher the video frame quality), the video encoding type (the higher the video frame quality in the case where the video encoding type is an I-frame). The embodiment of the application does not limit the video frame parameters, and the video frame parameters can be used for the subsequent screenshot quality evaluation as long as the video frame parameters are parameters affecting the video frame quality in the video coding process.
Step 102, determining a first influence factor of video frame quality on screenshot quality based on the video frame parameters.
And the method is different from the prior art that the difference between the original video frame and the picture content of the screenshot is directly compared, or the picture content of the screenshot is directly analyzed, and the quality of the screenshot is evaluated. In the embodiment of the application, considering that the quality of the screenshot generated by the original video frame and the screenshot operation can influence the quality of the screenshot generated in the screenshot generating process, the influence on the quality of the screenshot is correspondingly and respectively analyzed on the two dimensions of the quality of the original video frame and the screenshot operation. In the dimension of video frame quality, the computer equipment can acquire video frame parameters affecting the video frame quality of the target video frame so as to determine a first influence factor of the video frame quality on the screenshot quality according to at least one video frame parameter.
Step 103, determining a second influence factor of the screenshot operation on the quality of the screenshot.
Optionally, in addition to the video frame quality of the target video frame affecting the screenshot quality of the target screenshot, during the screenshot operation, the screenshot operation essentially performs a picture compression on the target video frame, which also reduces a portion of the screenshot quality, so in a possible implementation, it is also necessary to determine a second impact factor on the screenshot quality in the dimension of the screenshot operation.
Step 104, based on the first influence factor and the second influence factor, determining the screenshot quality of the target screenshot obtained by the screenshot operation.
In one possible implementation, the influence of the two dimensions, namely the video frame quality dimension of the original video frame (target video frame) and the screenshot operation dimension, on the screenshot quality is integrated, that is, the screenshot quality of the target screenshot obtained by the screenshot operation is determined according to the product of the first influence factor and the second influence factor. The influence of distortion loss caused by original video information and screenshot operation on screenshot quality can be fully considered, so that accuracy of screenshot quality evaluation is improved.
It should be noted that, the embodiment of the application can be applied to screenshot of video and video clips and screenshot quality evaluation of the screenshot; the method can also be applied to screenshot of live pictures and screenshot quality evaluation of the screenshot; that is, the video picture may be a video picture of a short video or a live video picture of a live broadcast.
In summary, the embodiment of the application provides a method for evaluating screenshot quality: in the process of capturing video images to generate the target capturing images, the video frame quality of the target video frames and the distortion loss caused by the capturing operation can influence the capturing image quality of the target capturing images, so that the influence factors of the video frame quality and the capturing operation on the capturing image quality are respectively calculated on two dimensions, and the capturing image quality of the target capturing images is determined according to the first influence factor (the influence factor of the video frame quality dimension on the capturing image quality) and the second influence factor (the influence factor of the capturing operation on the capturing image quality). In the screenshot quality evaluation process, the influence of the original video frame information and the distortion loss caused by screenshot operation on the screenshot quality can be fully considered, and the accuracy of the screenshot quality evaluation is effectively improved; and the screenshot quality evaluation process can be performed in real time in the screenshot operation process, and the comparison calculation of the original video frame and the screenshot is not required after the screenshot operation is completed, so that additional information calculation work can be avoided, and the screenshot quality evaluation efficiency is improved.
In order to consider the influence of video frame quality on screenshot quality from multiple aspects, in one possible implementation, video frame parameters with multiple different dimensions, such as video coding parameters, number of coding bits, video resolution, average quantization parameters, etc., are introduced, so that the first influence factor can characterize the influence of video frame parameters with different dimensions on screenshot quality, so as to fully evaluate screenshot quality and improve the accuracy of evaluating screenshot quality.
Referring to fig. 2, a flowchart of a method for determining picture quality of a screenshot according to another exemplary embodiment of the present application is illustrated, where the method is applied to a computer device, and the method includes:
in step 201, in response to the screenshot instruction, a screenshot time for triggering the screenshot instruction is determined.
Since the screenshot operation is triggered by the user and is performed on the video frame of the video, when the background generates the target screenshot, the background needs to determine the target video frame for displaying the video frame first; and the background is played in time sequence according to the decoded video frame sequence. Therefore, in one possible implementation, if the target video frame of the video frame indicated by the screenshot operation needs to be acquired, the screenshot time corresponding to the screenshot operation needs to be acquired, that is, the screenshot time triggering the screenshot quality is required, so as to determine the target video frame corresponding to the video frame based on the screenshot time.
Step 202, determining a target video frame corresponding to the video picture based on the screenshot time and the video duration of the source video.
The display time of the video picture corresponds to the playing time of the video frame, and then the target video frame corresponding to the video picture can be determined based on the relation between the screenshot time and the video duration of the source video. For example, if the screenshot time is 01:30, a video frame located at 01:30 seconds in the source video needs to be searched as a target video frame of the video frame.
The source video is the complete video corresponding to the video picture being played.
Step 203, based on the target video frame, obtaining the video frame parameters of the target video frame.
When the computer device performs video playing, a video frame sequence including a plurality of frames of video frames is often decoded according to a video stream, and each video frame parameter is also included in the video stream, so that the video frame parameter of each video frame can be obtained in the video decoding process. Wherein the video frame parameters include at least one of a number of coded bits (bytes) of the target video frame, a video frame resolution (width+height), a video coding parameter (the video coding parameter is determined by a video coding type), and an average quantization parameter.
The coding bit number, the video frame resolution and the video coding parameters can be directly obtained; and the average quantization parameter needs to be calculated according to the actual quantization parameter of each macroblock divided by the target video frame.
In an exemplary example, the process of obtaining the average quantization parameter of the target video frame may include the following steps one and two.
Step one, under the condition that the video frame parameters are average quantization parameters, the total macro block number of macro blocks of the target video frame divided in the video coding process and the actual quantization parameters of each macro block are obtained.
In the process of video coding into a video stream, a video frame is required to be divided into a plurality of macro blocks, and different actual quantization parameters are used for each macro block, if the actual quantization parameters used for the macro block are larger, the quality of a target video frame restored later is lower; in the video decoding process, in order to obtain the average quantization parameter of the target video frame through statistics, the actual quantization parameter of each macro block needs to be obtained first, and the total number of macro blocks of the target video frame divided in the video encoding process is required to average the actual quantization parameters of a plurality of macro blocks so as to obtain the average quantization parameter of the whole target video frame.
And step two, determining the average quantization parameter of the target video frame based on the actual quantization parameter of each macro block and the total macro block number.
In an exemplary example, the calculation formula of the average quantization parameter may be:
wherein QP is in An average quantization parameter representing the entire frame (target video frame), M represents the total number of macroblocks of the current frame (total number of macroblocks of the target video frame),representing the actual quantization parameter for each macroblock. As can be seen from the formula (1), the average quantization parameter of the target video frame can be obtained by averaging the sum of the actual quantization parameters of the respective macro blocks of the target video frame (dividing the sum of the actual quantization parameters of the respective macro blocks of the target video frame by the total number of macro blocks).
Optionally, the video coding parameter is determined by a video coding type (FrameType) of the target video frame, and in the video coding process, three video coding types are mainly included: i frame, B frame and P frame, the I frame is to compress and encode and transmit the whole frame image information, the complete image can be reconstructed according to the I frame during decoding, and other image frames are not required to be referred to; the P frame adopts a motion compensation method to transmit the difference value and the motion vector (prediction error) of the P frame and the previous I frame or P frame, and the prediction value in the I frame and the prediction error are summed up during decoding to reconstruct a complete P frame image, so that the compression rate of the P frame is higher; b frames take into account both the encoded frames preceding the source image sequence and the temporal redundancy information between the encoded frames following the source image sequence to compress the encoded image of the amount of transmission data, and when decoding, the previous I or P frame and the following P frame need to be referred to form a complete image; as can be seen from the encoding and decoding processes of the three encoding types, the image quality of the I frame is higher than that of the B frame and higher than that of the P frame, and correspondingly, when the video encoding parameters are determined based on the video encoding type, the video encoding parameters are determined to be the first parameters in the case that the video encoding type is the I frame, the video encoding parameters are determined to be the second parameters in the case that the video encoding type is the B frame, the video encoding parameters are determined to be the third parameters in the case that the video encoding type is the P frame, and the first parameters are greater than the second parameters and the second parameters are greater than the third parameters.
In one illustrative example, the relationship between the video coding type and the video coding parameters may be as shown in equation (2).
From equation (2), ratio frametype Representing video coding parameters, when the video coding type is I frame, the corresponding video coding parameter is 1, namely the first parameter is 1; when the video coding type is B frame, the corresponding video coding parameter is 0.9, namely the second parameter is 0.9; when the video coding type is P-frame, the corresponding video coding parameter is 0.8, i.e. the third parameter is 0.8.
Step 204, determining a first impact factor of video frame quality on screenshot quality based on at least one of coding bit number, video frame resolution, video coding parameters, and average quantization parameters, the video coding parameters being determined by video coding type of the target video frame.
In one possible implementation manner, when the computer device obtains at least one video frame parameter corresponding to the target video frame, a first influence factor of video frame quality on screenshot quality can be determined according to the at least one video frame parameter; in the case where the video frame parameters include at least one of a number of encoding bits of the target video frame, a video frame resolution, a video encoding parameter, and an average quantization parameter, the first impact factor of the video frame quality on the screenshot quality may be determined based on at least one of the number of encoding bits of the target video frame, the video frame resolution, the video encoding parameter, and the average quantization parameter.
Optionally, the greater the number of encoding bits, the higher the video frame quality of the target video frame, and the higher the quality of the corresponding target screenshot based on the relationship between the target video frame and the target screenshot, and therefore, the greater the number of encoding bits of the target video frame, the greater the value of the first influencing factor, and the smaller the number of encoding bits of the target video frame, and the smaller the value of the first influencing factor.
Optionally, the greater the resolution of the video frame, the higher the video frame quality of the target video frame, and the higher the quality of the corresponding target screenshot based on the relationship between the target video frame and the target screenshot, so that the video frame resolution has a positive correlation with the first influence factor, that is, the greater the resolution of the video frame, the greater the value of the first influence factor, and the lesser the resolution of the video frame.
Optionally, the larger the average quantization parameter is, the lower the video frame quality of the target video frame is, and based on the relationship between the target video frame and the target screenshot, the lower the quality of the corresponding target screenshot is, so that the average quantization parameter and the first influence factor have a negative correlation, that is, the larger the average quantization parameter is, the smaller the value of the first influence factor is, and the smaller the average quantization parameter is, the larger the value of the first influence factor is.
Optionally, the larger the video coding parameter is, the higher the video frame quality of the target video frame is, and based on the relation between the target video frame and the target screenshot, the higher the quality of the corresponding target screenshot is, so that the video coding parameter and the first influence factor are in positive correlation, that is, the larger the video coding parameter is, the larger the value of the first influence factor is, and the smaller the video coding parameter is, the smaller the value of the first influence factor is.
It should be noted that, the more kinds of video coding parameters used for calculating the first influence factor, the more accurate the first influence factor is determined, the more the first influence factor can comprehensively consider the influence of each video frame parameter on the quality of the screenshot. Step 204 may also include step 204A and step 204B, corresponding in one illustrative example.
Step 204A, obtaining a first weight of the number of encoding bits, a second weight of the video frame resolution, a third weight of the video encoding parameter, and a fourth weight of the average quantization parameter.
In order to integrate various video frame parameters, a developer calculates a first influence factor, and a certain weight value is set for each video frame parameter so as to quantify the influence of different video frame parameters on screenshot quality. The number of coding bits corresponds to a first weight, the resolution of the video frame corresponds to a second weight, the video coding parameters correspond to a third weight, and the average quantization parameters correspond to a fourth weight.
Step 204B, determining a first impact factor of video frame quality on screenshot quality based on the first weight and the number of encoding bits, the video frame resolution and the second weight, the video encoding parameter and the third weight, and the average quantization parameter and the fourth weight.
In an exemplary embodiment, the first influence factor may be calculated according to the number of encoding bits, the video frame resolution, the video encoding parameter, and the average quantization parameter as shown in equation (3).
Wherein Quality is ori Representing the first influencing factor, bytes in Representing the number of coded bits, 1/B representing the first weight of the number of coded bits, B being a normalization parameter constant; QP (QP) in Representing the average quantization parameter, width in +Height in Representing the video frame resolution, 1/(w+h) representing the second weight, W, H being a constant, w=1920, h=1080, ratio frametype Representing video coding parameters, the third weight is 1.
As can be seen from equation (3), the first influence factor is obtained by a four-term product, wherein,reflecting the influence of the current frame coding bit number on the picture quality, wherein the quality is better when the bit number is larger; />Reflecting the influence of the quantization parameter of the current frame on the picture quality, wherein the picture quality in the source video is relatively poor when the quantization parameter is larger, < > >Reflecting the effect of image resolution on image quality, ratio frametype Quality shadow for video coding typesAnd (5) sounding parameters.
When calculating the first influence factor of the video frame quality of the target video frame on the screenshot quality, the coding bit number, the video frame resolution, the video coding parameters and the average quantization parameters can be brought into the formula (3), and the product formed by connecting four sub-terms can be obtained and determined as the first influence factor.
Step 205, obtaining the picture compression rate in the screenshot operation process, wherein the picture compression rate is the picture compression rate in the target screenshot process generated by the target video frame.
When the second influence factor of the screenshot operation on the screenshot quality is calculated, as the screenshot operation process is actually a picture JPEG image compression process, the larger the picture compression rate brought by the picture compression process is, the lower the screenshot quality of the generated target screenshot is, otherwise, the smaller the picture compression rate brought by the picture compression process is, and the screenshot quality of the generated target screenshot is relatively higher. Thus, in one possible implementation, the computer device may obtain a picture compression rate during a screenshot operation in which a target screenshot is generated from a target video frame to determine a second impact factor of the screenshot operation on the quality of the screenshot.
In the process of picture compression, the process of quantizing pixel values is involved, and then the picture compression rate in the process of screenshot operation can be determined according to the quantization parameter table. In one illustrative example, step 205 may include step 205A and step 205B.
In step 205A, an actual quantization parameter table corresponding to the target video frame in the screenshot operation is obtained by performing discrete cosine transform on the pixel value in the target video frame.
In the JPEG compression process, after Discrete Cosine Transform (DCT) transformation is carried out on the pixel value of the current macro block, data quantization is carried out on each macro block based on a quantization coefficient matrix; in one possible implementation, the image compression rate during the screenshot operation is determined by acquiring an actual quantization parameter table and a standard quantization parameter table corresponding to the target video frame during the screenshot operation.
The actual quantization parameter table is obtained by performing Discrete Cosine Transform (DCT) on pixel values of current macro blocks in the target video frame, and each macro block is an 8x8 matrix after DCT.
In step 205B, the picture compression rate during the screenshot operation is determined based on the actual quantization parameter table and the standard quantization parameter table, which is the quantization parameter table used during the picture compression.
In an exemplary example, the picture compression rate may be calculated as shown in formula (4).
Where a represents the picture compression rate,the parameters representing the ith row and jth column in the actual quantization parameter table DQTin,DQT table representing standard quantization parameters anchor The parameters of the ith row and the jth column.
Wherein the standard quantization parameter table is also an 8x8 matrix. In one possible implementation manner, each parameter in the actual quantization parameter table and each parameter in the standard quantization parameter table are brought into the formula (4), so that the picture compression rate in the picture compression process can be obtained.
And 206, determining the reciprocal of the picture compression rate as a second influence factor of the screenshot operation on the quality of the screenshot.
Because the picture compression rate and the screenshot quality are in a negative correlation, the smaller the picture compression rate is, the higher the screenshot quality is, the larger the picture compression rate is, and the lower the screenshot quality is, the inverse of the picture compression rate (the larger the picture compression rate is, the smaller the inverse of the picture compression rate is, the smaller the picture compression rate is, and the larger the inverse of the picture compression rate is) can be determined as a second influencing factor of the screenshot operation on the screenshot quality based on the relation between the picture compression rate and the screenshot quality.
Step 207, determining the screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor and the second influence factor.
In one illustrative example, the determination formula for the quality of the screenshot of the target screenshot may be as shown in formula (5).
Quality 1 =Quality ori *1/α (5)
Wherein Quality is 1 Quality of the representation screenshot ori Representing a first influencing factor, 1/alpha represents the inverse of the picture compression rate. In one possible implementation, after the computer device obtains the first impact factor in the video frame quality dimension and the second impact factor in the screenshot operation dimension, the product of the first impact factor and the second impact factor may be determined as the screenshot quality of the target screenshot.
As shown in fig. 3, a schematic diagram of an evaluation process of screenshot quality shown in an exemplary embodiment of the application is shown. In a video frame quality dimension 301, determining a first influence factor 302 of video frame quality on screenshot quality by acquiring video frame parameters including a coding bit number, a video frame resolution, a video coding parameter, an average quantization parameter and the like; meanwhile, in the screenshot operation dimension 303, the second influencing factor 304 of the screenshot operation on the screenshot quality is determined by acquiring the actual quantization parameter table and the standard quantization parameter table of the current macro block in the target video frame; and in turn jointly evaluate screenshot quality 305 based on first impact factor 302 and second impact factor 304.
In this embodiment, an influence parameter having a key influence on video frame quality in the video encoding and decoding process may be obtained: the method comprises the steps of calculating a first influence factor of video frame quality on screenshot quality by encoding bit number, video frame resolution, video encoding parameters and average quantization parameters, so that the first influence factor can fully represent influence of different types of video frame parameters on the first influence factor, and determining accuracy of the first influence factor is improved to further improve evaluation accuracy of subsequent screenshot quality. In addition, considering that the screenshot operation is essentially a picture compression process, the second influence factor of the screenshot operation on the quality of the screenshot can be calculated by acquiring the picture compression rate in the picture compression process, so that the second influence factor can characterize the image distortion loss in the picture compression process, and the evaluation accuracy of the quality of the subsequent screenshot is further improved.
In order to further improve the accuracy of the quality evaluation of the screenshot, in addition to the influence of the original video frame quality on the screenshot quality, the influence of the screenshot operation on the screenshot quality is considered, and in other possible embodiments, an influence factor of the source video quality on the screenshot quality can be introduced when the quality evaluation is performed on the screenshot quality.
Referring to fig. 4, a flowchart of a method for determining picture quality of a screenshot according to another exemplary embodiment of the present application is illustrated, where the method is applied to a computer device, and the method includes:
step 401, in response to a screenshot instruction, obtaining a video frame parameter of a target video frame, where the screenshot instruction is triggered by a screenshot operation of a video picture, the target video frame is a video frame corresponding to the video picture, and the video frame parameter is a parameter affecting video frame quality in a video encoding and decoding process.
Step 402, determining a first influence factor of video frame quality on screenshot quality based on video frame parameters.
Step 403, determining a second influencing factor of the screenshot operation on the quality of the screenshot.
The implementation manners of steps 401 to 403 may refer to the above embodiments, and this embodiment is not described herein.
Step 404, determining a third influencing factor of the source video quality corresponding to the target video frame on the screenshot quality.
In order to further improve the accuracy of the evaluation of the quality of the screenshot, in a possible implementation manner, the computer device may further introduce a third factor of influence of the quality of the source video corresponding to the target video frame on the quality of the screenshot when evaluating the quality of the screenshot, in consideration that the quality of the source video also affects the quality of the screenshot.
It should be noted that, the steps 402, 403 and 404 may be executed simultaneously, may be executed in the order of the steps 402 to 404, or may be executed in other orders, and the execution order of the steps 402 to 404 is not limited in the embodiment of the present application.
In an illustrative example, step 404 may further include step 404A and step 404B.
Step 404A, obtaining a video code rate of the source video corresponding to the target video frame and a video frame resolution of the target video frame.
The source video quality is related to the video bitrate of the video and the video frame resolution, and therefore, in one possible implementation, the computer device may obtain the video bitrate of the source video and the video frame resolution of the target video frame before calculating the third impact factor.
Step 404B, determining a third influencing factor of the source video quality corresponding to the target video frame on the screenshot quality based on the video code rate and the video frame resolution.
In an exemplary example, the third influence factor may be calculated as shown in equation (6).
Wherein bpp in Representing a third influencing factor (pixel depth of the input video), kbps in Representing video code rate, width in *height in Representing the video frame resolution. In calculating the third influencing factor, X ma =8.0,X mi =1.0。
As can be seen from the formula (6), the ratio of the video code rate to the video frame resolution can be normalized, so as to obtain the third influence factor of the source video quality on the screenshot quality by quantization.
Step 405, determining screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor, the second influence factor and the third influence factor.
In one illustrative example, the quality of the screenshot may be calculated as shown in equation (7).
Quality 2 =Quality ori *1/α*bpp in (7)
Wherein Quality is 2 Quality of the representation screenshot ori Representing a first impact factor (impact factor in the video frame quality dimension), 1/α representing a second impact factor (impact factor in the screenshot operation dimension), bpp in Representing a third influencing factor (influencing factor in the source video quality dimension).
As can be seen from the formula (7), when the computer device obtains the first influence factor of the video frame quality dimension on the screenshot quality, the second influence factor of the screenshot operation dimension on the screenshot quality, and the third influence factor of the screenshot quality on the source video quality dimension, the product of the first influence factor, the second influence factor and the third influence factor can be determined as the screenshot quality of the target screenshot obtained by the screenshot operation.
As shown in fig. 5, a schematic diagram of an evaluation process of screenshot quality shown in another exemplary embodiment of the application is shown. In a video frame quality dimension 501, determining a first influence factor 502 of video frame quality on screenshot quality by acquiring video frame parameters including a coding bit number, video frame resolution, video coding parameters, average quantization parameters and the like; meanwhile, in a screenshot operation dimension 503, a second influence factor 504 of the screenshot operation on the screenshot quality is determined by acquiring an actual quantization parameter table and a standard quantization parameter table of a current macro block in the target video frame; in the source video quality dimension 505, a third influence factor 506 of the source video quality on the screenshot quality is determined by acquiring the video code rate and the video frame resolution of the source video, and then the screenshot quality 507 is evaluated jointly according to the first influence factor 502, the second influence factor 504 and the third influence factor 506.
In this embodiment, the dimension parameter of the source video quality is additionally introduced when the quality of the screenshot is evaluated, so that when the influence of the original video information on the quality of the screenshot is considered, comprehensive consideration is performed from two aspects of a single video frame dimension (video frame quality dimension) and an overall video dimension (source video quality dimension), the original video information is fully utilized when the quality of the screenshot is evaluated, and the quality of the screenshot can be evaluated more accurately.
In other possible embodiments, the screenshot resolution also has an effect on the quality of the screenshot, and then an impact factor of the screenshot resolution on the quality of the screenshot can also be introduced when the quality of the screenshot is evaluated.
Referring to fig. 6, a flowchart of a method for determining picture quality of a screenshot according to another exemplary embodiment of the present application is illustrated, where the method is applied to a computer device, and the method includes:
in step 601, a video frame parameter of a target video frame is obtained in response to a screenshot instruction, wherein the screenshot instruction is triggered by a screenshot operation of a video picture, the target video frame is a video frame corresponding to the video picture, and the video frame parameter is a parameter affecting the quality of the video frame in the video encoding and decoding process.
Step 602, determining a first influence factor of video frame quality on screenshot quality based on video frame parameters.
Step 603, determining a second influencing factor of the screenshot operation on the quality of the screenshot.
Step 604, determining a third influencing factor of the source video quality corresponding to the target video frame on the screenshot quality.
The implementation manners of steps 601 to 604 may refer to the above embodiments, and this embodiment is not described herein.
Step 605, based on the screenshot resolution of the target screenshot, a fourth impact factor of the screenshot resolution on the quality of the screenshot is determined.
Considering that the screenshot resolution also affects the quality of the screenshot, for example, the higher the screenshot resolution is, the higher the screenshot quality is, the lower the screenshot resolution is, and the lower the screenshot quality is, in order to further improve the accuracy of evaluating the screenshot quality, in a possible implementation manner, a fourth influencing factor of the screenshot resolution dimension on the screenshot quality may be determined according to the screenshot resolution of the target screenshot.
In an exemplary example, the fourth influence factor may be calculated as shown in equation (8).
Wherein R is resout A fourth influencing factor, width, representing the screenshot resolution dimension out *height out The screenshot resolution is represented, w×h is constant, w=1920, h=1080.
The steps 602, 603, 604, and 605 may be performed simultaneously, may be performed in the order of the steps 602 to 605, or may be performed in other orders, and the order of execution of the steps 602 to 605 is not limited in the embodiment of the present application.
And step 606, determining the product of the first influence factor, the second influence factor, the third influence factor and the fourth influence factor as the screenshot quality of the target screenshot obtained by the screenshot operation.
In an illustrative example, after the fourth influence factor is introduced, the quality of the screenshot may be calculated as shown in equation (9).
Quality 3 =Quality ori *1/α*bpp in *R resout (9)
Wherein, quality is 3 Quality of the representation screenshot ori Representing a first impact factor (impact factor in the video frame quality dimension), 1/α representing a second impact factor (impact factor in the screenshot operation dimension), bpp in Representing a third influence factor (influence factor in the source video quality dimension), R resout Representing a fourth influencing factor in the screenshot resolution dimension.
As can be seen from the formula (9), when the computer device obtains the first influence factor of the video frame quality dimension on the screenshot quality, the second influence factor of the screenshot operation dimension on the screenshot quality, the third influence factor of the screenshot quality on the source video quality dimension, and the fourth influence factor on the screenshot resolution dimension, the product of the first influence factor, the second influence factor, the third influence factor and the fourth influence factor can be determined as the screenshot quality of the target screenshot obtained by the screenshot operation.
As shown in fig. 7, a schematic diagram of an evaluation process of screenshot quality shown in another exemplary embodiment of the application is shown. In the video frame quality dimension 701, determining a first influence factor 702 of video frame quality on screenshot quality by acquiring video frame parameters including a coding bit number, video frame resolution, video coding parameters, average quantization parameters and the like; meanwhile, in the screenshot operation dimension 703, the second influencing factor 704 of the screenshot operation on the screenshot quality is determined by acquiring the actual quantization parameter table and the standard quantization parameter table of the current macro block in the target video frame; in a source video quality dimension 705, determining a third influence factor 706 of the source video quality on the screenshot quality by acquiring a video code rate and a video frame resolution of the source video; in the screenshot resolution dimension 707, determining a fourth impact factor 708 of the screenshot resolution on the quality of the screenshot according to the screenshot resolution; in turn, the quality 709 of the screenshot is evaluated jointly based on the first impact factor 702, the second impact factor 704, the third impact factor 706, and the fourth impact factor 708.
Optionally, in other possible embodiments, if the service personnel measures the quality of the screenshot in the actual application process, different impact weights may be set for different impact factors according to the service requirement. For example, a first influence weight is set for the first influence factor, a second influence weight is set for the second influence factor, a third influence weight is set for the third influence factor, and a fourth influence weight is set for the fourth influence factor, so that the quality of the screenshot is determined according to the product of the first influence factor and the first influence weight, the product of the second influence factor and the second influence weight, the product of the third influence factor and the third influence weight, and the product of the first influence factor and the fourth influence weight.
In this embodiment, the dimension parameter of the screenshot resolution is additionally introduced when the screenshot quality is evaluated, so that when the influence of the screenshot operation on the screenshot quality is considered, the two aspects of the picture compression rate in the screenshot operation process and the screenshot resolution corresponding to the screenshot operation are comprehensively considered, screenshot operation information is fully utilized when the screenshot quality is evaluated, and the screenshot quality can be evaluated more accurately.
The method for determining the picture quality of the screenshot comprises the following steps: the quality of the screenshot is evaluated in two dimensions from the influence of the original video and the influence of the screenshot operation, and is irrelevant to the image content of the screenshot, so that the quality of the screenshot calculated based on the method can be used as a standard parameter for the screenshot function evaluation. In a possible application scenario, when the screenshot function is used, the quality of a real-time picture of a screenshot generated in real time can be obtained and compared with the quality (standard parameter) of the screenshot, if the quality of the real-time picture is lower than the quality of the screenshot, the screenshot function is indicated to be possibly abnormal, and the cause of the abnormality needs to be further determined; otherwise, if the quality of the real-time picture is greater than or equal to the quality of the screenshot, the screenshot function is normal. The quality of the screenshot can be used as a monitoring screenshot function to normally operate or not.
Optionally, when the method for determining the quality of the captured picture shown in the embodiment is applied to the process of capturing the video, the quality of the captured picture can be determined; optionally, when the video screenshot is used to generate the video cover, the method is also used for judging the screenshot quality of the video cover obtained by screenshot. And the screenshot quality corresponding to the screenshot can be generated in real time after the screenshot operation is finished, and the screenshot quality is fed back to the user, so that the user can determine whether the screenshot needs to be re-captured according to the screenshot quality.
Under other possible application scenes, the method for determining the quality of the screenshot in the embodiment can be further applied to a live screenshot process to determine the quality of the screenshot of the intercepted picture; optionally, when the live screenshot is used as the live cover, the live screenshot quality of the live cover obtained by the screenshot is judged. And the screenshot quality corresponding to the screenshot can be generated in real time after the screenshot operation is finished, and the screenshot quality is fed back to the user, so that the user can determine whether the screenshot needs to be re-captured according to the screenshot quality.
Fig. 8 is a block diagram of a picture quality determining apparatus for screenshot provided in an exemplary embodiment of the application, the apparatus including:
An obtaining module 801, configured to obtain a video frame parameter of a target video frame in response to a screenshot instruction, where the screenshot instruction is triggered by a screenshot operation of a video frame, the target video frame is a video frame corresponding to the video frame, and the video frame parameter is a parameter affecting video frame quality in a video encoding and decoding process;
a determining module 802, configured to determine, based on the video frame parameter, a first impact factor of video frame quality on screenshot quality;
the determining module 802 is further configured to determine a second influencing factor of the screenshot operation on screenshot quality;
the determining module 802 is further configured to determine a screenshot quality of the target screenshot obtained by the screenshot operation based on the first impact factor and the second impact factor.
Optionally, the determining module 802 is further configured to determine a third influencing factor of the source video quality corresponding to the target video frame on the quality of the screenshot;
the determining module 802 is further configured to:
and determining the screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor, the second influence factor and the third influence factor.
Optionally, the determining module 802 is further configured to determine a fourth influencing factor of the screenshot resolution on the screenshot quality based on the screenshot resolution of the target screenshot;
The determining module 802 is further configured to:
and determining the product of the first influence factor, the second influence factor, the third influence factor and the fourth influence factor as the screenshot quality of the target screenshot obtained by the screenshot operation.
Optionally, the determining module 802 is further configured to:
acquiring a video code rate of a source video corresponding to the target video frame and a video frame resolution of the target video frame;
and determining the third influence factor of the source video quality corresponding to the target video frame on screenshot quality based on the video code rate and the video frame resolution.
Optionally, the video frame parameters include at least one of a coding bit number, a video frame resolution, a video coding parameter, and an average quantization parameter of the target video frame;
the determining module 802 is further configured to:
determining the first impact factor of the video frame quality on screenshot quality based on at least one of the number of encoding bits, the video frame resolution, the video encoding parameter, and the average quantization parameter, the video encoding parameter being determined by a video encoding type of the target video frame.
Optionally, the number of coded bits and the first influence factor have a positive correlation;
the video frame resolution and the first influence factor are in positive correlation;
the average quantization parameter and the first influence factor are in negative correlation;
determining the video coding parameter as a first parameter in the case that the video coding type is an I frame, determining the video coding parameter as a second parameter in the case that the video coding type is a B frame, and determining the video coding parameter as a third parameter in the case that the video coding type is a P frame, wherein the first parameter is greater than the second parameter, and the second parameter is greater than the third parameter.
Optionally, the determining module 802 is further configured to:
acquiring a first weight of the coding bit number, a second weight of the video frame resolution, a third weight of the video coding parameter and a fourth weight of the average quantization parameter;
determining the first impact factor of the video frame quality on screenshot quality based on the first weight and the number of encoding bits, the video frame resolution and the second weight, the video encoding parameter and the third weight, and the average quantization parameter and the fourth weight.
Optionally, the obtaining module 801 is further configured to:
acquiring the total number of macro blocks of the target video frame divided in the video coding process and the actual quantization parameters of each macro block under the condition that the video frame parameters are the average quantization parameters;
the average quantization parameter of the target video frame is determined based on the actual quantization parameter and the total number of macroblocks for each macroblock.
Optionally, the determining module 802 is further configured to:
acquiring a picture compression rate in the screenshot operation process, wherein the picture compression rate is a picture compression rate in the target screenshot process generated by the target video frame;
and determining the reciprocal of the picture compression rate as the second influence factor of the screenshot operation on screenshot quality.
Optionally, the determining module 802 is further configured to:
acquiring an actual quantization parameter table corresponding to the target video frame in the screenshot operation process, wherein the actual quantization parameter table is obtained by performing discrete cosine transform on pixel values in the target video frame;
and determining the picture compression rate in the screenshot operation process based on the actual quantization parameter table and a standard quantization parameter table, wherein the standard quantization parameter table is used in the picture compression process.
Optionally, the obtaining module 801 is further configured to:
responding to the screenshot instruction, and determining screenshot time for triggering the screenshot instruction;
determining the target video frame corresponding to the video picture based on the screenshot time and the video duration of the source video;
and acquiring the video frame parameters of the target video frame based on the target video frame.
Optionally, the obtaining module 801 is further configured to obtain a real-time picture quality of a screenshot generated in real time during a use process of the screenshot function;
the determining module 802 is further configured to determine that the screenshot function is abnormal if the real-time picture quality is lower than the screenshot quality.
In summary, the embodiment of the application provides a method for evaluating screenshot quality: in the process of capturing video images to generate the target capturing images, the video frame quality of the target video frames and the distortion loss caused by the capturing operation can influence the capturing image quality of the target capturing images, so that the influence factors of the video frame quality and the capturing operation on the capturing image quality are respectively calculated on two dimensions, and the capturing image quality of the target capturing images is determined according to the first influence factor (the influence factor of the video frame quality dimension on the capturing image quality) and the second influence factor (the influence factor of the capturing operation on the capturing image quality). In the screenshot quality evaluation process, the influence of the original video frame information and the distortion loss caused by screenshot operation on the screenshot quality can be fully considered, and the accuracy of the screenshot quality evaluation is effectively improved; and the screenshot quality evaluation process can be performed in real time in the screenshot operation process, and the comparison calculation of the original video frame and the screenshot is not required after the screenshot operation is completed, so that additional information calculation work can be avoided, and the screenshot quality evaluation efficiency is improved.
Fig. 9 is a schematic diagram of a computer device, according to an example embodiment. The computer apparatus 900 includes a central processing unit (Central Processing Unit, CPU) 901, a system Memory 904 including a random access Memory (Random Access Memory, RAM) 902 and a Read-Only Memory (ROM) 903, and a system bus 905 connecting the system Memory 904 and the central processing unit 901. The computer device 900 also includes a basic Input/Output system (I/O) 906, which helps to transfer information between various devices within the computer device, and a mass storage device 907, for storing an operating system 913, application programs 914, and other program modules 915.
The basic input/output system 906 includes a display 908 for displaying information and an input device 909, such as a mouse, keyboard, etc., for user input of information. Wherein the display 908 and the input device 909 are connected to the central processing unit 901 via an input output controller 910 connected to the system bus 905. The basic input/output system 906 can also include an input/output controller 910 for receiving and processing input from a number of other devices, such as a keyboard, mouse, or electronic stylus. Similarly, the input-output controller 910 also provides output to a display screen, a printer, or other type of output device.
The mass storage device 907 is connected to the central processing unit 901 through a mass storage controller (not shown) connected to the system bus 905. The mass storage device 907 and its associated computer device-readable media provide non-volatile storage for the computer device 900. That is, the mass storage device 907 may include a computer device readable medium (not shown) such as a hard disk or a compact disk-Only (CD-ROM) drive.
The computer device readable medium may include computer device storage media and communication media without loss of generality. Computer device storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer device readable instructions, data structures, program modules or other data. Computer device storage media includes RAM, ROM, erasable programmable read-Only Memory (Erasable Programmable Read Only Memory, EPROM), electrically erasable programmable read-Only Memory (Electrically Erasable Programmable Read-Only Memory, EEPROM), CD-ROM, digital video disk (Digital Video Disc, DVD), or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices. Of course, those skilled in the art will recognize that the computer device storage medium is not limited to the ones described above. The system memory 904 and mass storage device 907 described above may be collectively referred to as memory.
According to various embodiments of the present disclosure, the computer device 900 may also operate through a network, such as the Internet, to remote computer devices on the network. I.e., the computer device 900 may be connected to the network 911 through a network interface unit 912 coupled to the system bus 905, or alternatively, the network interface unit 912 may be used to connect to other types of networks or remote computer device systems (not shown).
The memory further includes one or more programs stored in the memory, and the central processor 901 implements all or part of the steps of the three-dimensional brain midline segmentation method by executing the one or more programs.
The present application also provides a computer readable storage medium having stored therein at least one instruction, at least one program, a code set, or an instruction set, where the at least one instruction, the at least one program, the code set, or the instruction set is loaded and executed by a processor to implement a method for determining picture quality of a screenshot provided by the above method embodiments.
The present application provides a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the method for determining the picture quality of the screenshot provided by the above method embodiment.
The foregoing embodiment numbers of the present application are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program for instructing relevant hardware, where the program may be stored in a computer readable storage medium, and the storage medium may be a read-only memory, a magnetic disk or an optical disk, etc.
The foregoing description of the preferred embodiments of the present application is not intended to limit the application, but rather, the application is to be construed as limited to the appended claims.
Claims (16)
1. A method for determining picture quality of a screenshot, the method comprising:
responding to a screenshot instruction, acquiring video frame parameters of a target video frame, wherein the screenshot instruction is triggered by screenshot operation of a video picture, the target video frame is a video frame corresponding to the video picture, and the video frame parameters are parameters affecting the quality of the video frame in the video encoding and decoding process;
determining a first influence factor of video frame quality on screenshot quality based on the video frame parameters;
Determining a second influence factor of the screenshot operation on screenshot quality;
and determining the screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor and the second influence factor.
2. The method according to claim 1, wherein the method further comprises:
determining a third influence factor of the source video quality corresponding to the target video frame on the screenshot quality;
the determining, based on the first influence factor and the second influence factor, the screenshot quality of the target screenshot obtained by the screenshot operation includes:
and determining the screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor, the second influence factor and the third influence factor.
3. The method according to claim 2, wherein the method further comprises:
determining a fourth influence factor of the screenshot resolution on screenshot quality based on the screenshot resolution of the target screenshot;
the determining, based on the first influence factor, the second influence factor, and the third influence factor, the screenshot quality of the target screenshot obtained by the screenshot operation includes:
And determining the product of the first influence factor, the second influence factor, the third influence factor and the fourth influence factor as the screenshot quality of the target screenshot obtained by the screenshot operation.
4. The method of claim 2, wherein determining a third impact factor of the source video quality corresponding to the target video frame on the quality of the screenshot comprises:
acquiring a video code rate of a source video corresponding to the target video frame and a video frame resolution of the target video frame;
and determining the third influence factor of the source video quality corresponding to the target video frame on screenshot quality based on the video code rate and the video frame resolution.
5. The method of any one of claims 1 to 4, wherein the video frame parameters include at least one of a number of encoding bits of the target video frame, a video frame resolution, a video encoding parameter, and an average quantization parameter;
the determining a first influence factor of the video frame quality on the screenshot quality based on the video frame parameters comprises:
determining the first impact factor of the video frame quality on screenshot quality based on at least one of the number of encoding bits, the video frame resolution, the video encoding parameter, and the average quantization parameter, the video encoding parameter being determined by a video encoding type of the target video frame.
6. The method of claim 5, wherein the step of determining the position of the probe is performed,
the number of the coded bits and the first influence factor are in positive correlation;
the video frame resolution and the first influence factor are in positive correlation;
the average quantization parameter and the first influence factor are in negative correlation;
determining the video coding parameter as a first parameter in the case that the video coding type is an I frame, determining the video coding parameter as a second parameter in the case that the video coding type is a B frame, and determining the video coding parameter as a third parameter in the case that the video coding type is a P frame, wherein the first parameter is greater than the second parameter, and the second parameter is greater than the third parameter.
7. The method of claim 5, wherein said determining said first impact factor of said video frame quality on screenshot quality based on at least one of said number of encoding bits, said video frame resolution, said video encoding parameters, and said average quantization parameters comprises:
acquiring a first weight of the coding bit number, a second weight of the video frame resolution, a third weight of the video coding parameter and a fourth weight of the average quantization parameter;
Determining the first impact factor of the video frame quality on screenshot quality based on the first weight and the number of encoding bits, the video frame resolution and the second weight, the video encoding parameter and the third weight, and the average quantization parameter and the fourth weight.
8. The method of claim 5, wherein the obtaining video frame parameters of the target video frame comprises:
acquiring the total number of macro blocks of the target video frame divided in the video coding process and the actual quantization parameters of each macro block under the condition that the video frame parameters are the average quantization parameters;
the average quantization parameter of the target video frame is determined based on the actual quantization parameter and the total number of macroblocks for each macroblock.
9. The method of any of claims 1 to 4, wherein determining a second impact factor of the screenshot operation on screenshot quality comprises:
acquiring a picture compression rate in the screenshot operation process, wherein the picture compression rate is a picture compression rate in the target screenshot process generated by the target video frame;
and determining the reciprocal of the picture compression rate as the second influence factor of the screenshot operation on screenshot quality.
10. The method of claim 9, wherein the obtaining the picture compression rate during the screenshot operation comprises:
acquiring an actual quantization parameter table corresponding to the target video frame in the screenshot operation process, wherein the actual quantization parameter table is obtained by performing discrete cosine transform on pixel values in the target video frame;
and determining the picture compression rate in the screenshot operation process based on the actual quantization parameter table and a standard quantization parameter table, wherein the standard quantization parameter table is used in the picture compression process.
11. The method according to any one of claims 1 to 4, wherein the acquiring, in response to the screenshot instruction, video frame parameters of the target video frame includes:
responding to the screenshot instruction, and determining screenshot time for triggering the screenshot instruction;
determining the target video frame corresponding to the video picture based on the screenshot time and the video duration of the source video;
and acquiring the video frame parameters of the target video frame based on the target video frame.
12. The method according to any one of claims 1 to 4, further comprising:
Acquiring the quality of a real-time picture of a screenshot generated in real time in the use process of the screenshot function;
and under the condition that the quality of the real-time picture is lower than that of the screenshot, determining that the screenshot function is abnormal.
13. A picture quality determination apparatus for a screenshot, the apparatus comprising:
the acquisition module is used for responding to a screenshot instruction, acquiring video frame parameters of a target video frame, wherein the screenshot instruction is triggered by screenshot operation of a video picture, the target video frame is a video frame corresponding to the video picture, and the video frame parameters are parameters affecting the video frame quality in the video encoding and decoding process;
the determining module is used for determining a first influence factor of video frame quality on screenshot quality based on the video frame parameters;
the determining module is further configured to determine a second influence factor of the screenshot operation on screenshot quality;
and the determining module is further used for determining the screenshot quality of the target screenshot obtained by the screenshot operation based on the first influence factor and the second influence factor.
14. A computer device, the computer device comprising: a processor and a memory storing a computer program that is loaded and executed by the processor to implement the picture quality determination method of the screenshot of any one of claims 1 to 12.
15. A computer readable storage medium storing a computer program loaded and executed by a processor to implement the picture quality determination method of the screenshot of any one of claims 1 to 12.
16. A computer program product, characterized in that it stores a computer program that is loaded and executed by a processor to implement the picture quality determination method of the screenshot according to any one of claims 1 to 12.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211097198.0A CN116993652A (en) | 2022-09-08 | 2022-09-08 | Method, device, equipment, medium and product for determining picture quality of screenshot |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211097198.0A CN116993652A (en) | 2022-09-08 | 2022-09-08 | Method, device, equipment, medium and product for determining picture quality of screenshot |
Publications (1)
Publication Number | Publication Date |
---|---|
CN116993652A true CN116993652A (en) | 2023-11-03 |
Family
ID=88523810
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211097198.0A Pending CN116993652A (en) | 2022-09-08 | 2022-09-08 | Method, device, equipment, medium and product for determining picture quality of screenshot |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116993652A (en) |
-
2022
- 2022-09-08 CN CN202211097198.0A patent/CN116993652A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7453937B2 (en) | Method and device for selecting a transcoding method among a set of transcoding methods | |
US7142599B2 (en) | Method and device for selecting a transcoding method from a set of transcoding methods | |
US9282330B1 (en) | Method and apparatus for data compression using content-based features | |
US20090232206A1 (en) | Image prediction encoding device, image prediction decoding device, image prediction encoding method, image prediction decoding method, image prediction encoding program, and image prediction decoding program | |
CN1596422A (en) | A method and system for estimating objective quality of compressed video data | |
JP2005527159A (en) | Method and system for estimating objective quality of compressed video data | |
CN102187656A (en) | Pixel prediction value generation procedure automatic generation method, image encoding method, image decoding method, devices using these methods, programs for these methods, and recording medium on which these programs are recorded | |
CN112399176A (en) | Video coding method and device, computer equipment and storage medium | |
CN101056408B (en) | Method and apparatus for determining a threshold for skip mode in video coding | |
CN114513655A (en) | Live video quality evaluation method, video quality adjustment method and related device | |
CN112437301A (en) | Code rate control method and device for visual analysis, storage medium and terminal | |
Amirpour et al. | Between two and six? towards correct estimation of jnd step sizes for vmaf-based bitrate laddering | |
US20120207212A1 (en) | Visually masked metric for pixel block similarity | |
CN112584153B (en) | Video compression method and device based on just noticeable distortion model | |
CN103517074B (en) | Image encoding apparatus and its control method | |
DE60036585T2 (en) | Video data coder and method for encoding video data | |
US10979704B2 (en) | Methods and apparatus for optical blur modeling for improved video encoding | |
CN104093022A (en) | Rate distortion optimization method and device | |
CN116993652A (en) | Method, device, equipment, medium and product for determining picture quality of screenshot | |
US20010014123A1 (en) | Method for processing video | |
CN115550650A (en) | Method and device for effectively adjusting compression rate of reference frame image and electronic equipment | |
JP5043849B2 (en) | Variable shape motion estimation in video sequences | |
CN112243129B (en) | Video data processing method and device, computer equipment and storage medium | |
EP3637769B1 (en) | Method and device for determining video frame complexity measure | |
CN113596575A (en) | Video fingerprint data generation method, comparison method and equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |