Video data processing method and device, equipment, medium and product
By comparing and establishing information tables, we can determine the same or similar data in the SoC chip, avoid repeated conversions, and solve the problems of waste of resources and increased power consumption in the SoC chip, and improve processing efficiency and performance.
Patent Information
- Application Number
- CN202411412653.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-11
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2044-10-11
AI Technical Summary
Since there is a large amount of the same data in the same frame of data in the SoC chip, the problem of waste of resources and increased power consumption.
By comparing the initial video data of the current segment with the adjacent rows and video data of adjacent segments of the pixel size of the associated block, a first information table and a second information table are established to determine the video data that meets the preset range, and avoid duplicate data conversion. Directly perform single color space or block conversion.
It effectively avoids repeated data processing, reduces the power consumption of the chip, improves data processing speed and performance, and extends the service life of the chip.
Smart Images

Figure CN119211502A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of server technology, and in particular to a method, device, equipment, medium and product for processing video data. Background Art
[0002] System on Chip (SoC) is a technology that integrates multiple components in traditional computers or other electronic systems into a single chip. This integrated approach can not only reduce size and cost, but also increase computing speed and enhance system functionality.
[0003] In SoC chips, due to the small changes in the host operating system interface, a large amount of identical data exists in the same frame of data. Whether the data is in compression mode or in pixel mode (YUV mode formed by three components of brightness (Y), blue color difference (U) and red color difference (V)), a large amount of on-chip storage resources are used for data format conversion. Due to the existence of a large amount of identical data, on-chip resources also process the same data, resulting in a waste of resources, further increasing the power consumption of the chip.
[0004] Therefore, how to save resources of SoC chips and reduce power consumption is an urgent problem to be solved by those skilled in the art. Summary of the invention
[0005] The purpose of the present invention is to provide a method, device, equipment, medium and product for processing video data to solve the problem that a large amount of identical data in the same frame of data leads to waste of processing resources and increased power consumption of the chip.
[0006] In order to solve the above technical problems, the present invention provides a method for processing video data, comprising: Retrieve initial video data of the current segment stored by the host and / or the double data rate synchronous dynamic random access memory; Determine the first video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment; and store the address information of the first video data and the initial video data of the current segment in the first information table; wherein the first video data is video data that satisfies the first preset range of the difference with the initial video data of the current segment; and a row of video data includes at least one segment of video data; Determine the second video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the adjacent second preset segment of the video data; and store the similarity results of the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size in the second information table; wherein the second video data is video data that satisfies the second preset range of the difference with the initial video data of the current segment; The initial video data of the current segment is converted into a data format according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data.
[0007] On the one hand, initial video data of the current segment respectively stored by the host machine and the double data rate synchronous dynamic random access memory are obtained; wherein the initial video data of each current segment occupies one line respectively.
[0008] On the other hand, in the process of determining the first video data, adjacent rows of the block pixel size are row data respectively occupied by the initial video data of each current segment, and the initial video data of each current segment belongs to the same block pixel size; In the process of determining the second video data, the initial video data of each current segment occupies different rows of the same block pixel size.
[0009] On the other hand, when the initial video data of the current segment is acquired by the host machine or the double data rate synchronous dynamic random access memory, the first video data is determined according to a comparison relationship between the initial video data of the current segment and each video data of the stored adjacent rows and adjacent first preset segments of the corresponding block pixel size; Correspondingly, the second video data is determined according to a comparison relationship between the initial video data of the current segment and the stored adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment.
[0010] On the other hand, determining the first video data according to the comparison relationship between the initial video data of the current segment and the video data of adjacent rows of the corresponding block pixel size and adjacent first preset segments includes: Determining whether the initial video data of each current segment in adjacent rows in a vertical direction consisting of rows where the initial video data of each current segment is located are the same; If they are the same, it is determined that the initial video data of each current segment is the same, one initial video data of the current segment is retained, and the address information corresponding to the initial video data of each current segment is recorded; If they are different, then the video data of the adjacent i-th segment in each row in the horizontal direction are respectively subjected to difference processing with the initial video data of each current segment; wherein 1≤i≤N, N is a positive integer, and N is less than or equal to the first preset segment; If the difference after the difference processing is within the first preset range, the video data of the adjacent i-th segment in the respective rows in the horizontal direction are used as the first video data, the video data of the adjacent i-th segment or the initial video data of the current segment are retained, and the address information corresponding to the video data of the adjacent i-th segment and the initial video data of the current segment is recorded; If the difference value after the difference processing is not within the first preset range, it is determined that the first preset range of the difference value with the initial video data of the current segment is not satisfied.
[0011] On the other hand, determining the first video data according to the comparison relationship between the initial video data of the current segment and the video data of adjacent rows of the corresponding block pixel size and adjacent first preset segments includes: Determining whether the initial video data of each current segment in adjacent rows in a vertical direction consisting of rows where the initial video data of each current segment is located are the same; If they are the same, it is determined that the initial video data of each current segment is the same, one initial video data of the current segment is retained, and the address information corresponding to the initial video data of each current segment is recorded; If they are different, then the video data of the adjacent i-th segment in each row in the horizontal direction are respectively subjected to difference processing with the initial video data of each current segment; wherein 1≤i≤N, N is a positive integer, and N is less than or equal to the first preset segment; If the difference after the difference processing is within the first preset range, the video data of the adjacent i-th segment in the respective same line in the horizontal direction is used as the first video data, the video data of the adjacent i-th segment in the respective same line in the horizontal direction or the initial video data of the current segment is retained, and the address information corresponding to the video data of the adjacent i-th segment in the respective same line in the horizontal direction and the initial video data of the current segment is recorded; If the difference after the difference processing is not within the first preset range, it is determined that the video data of the i-th segment of the intersecting adjacent rows in the vertical direction are respectively subjected to difference processing with the initial video data of the respective current segments; If the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction are respectively subjected to difference processing with the initial video data of the respective current segments, and the difference values after the difference processing are within a first preset range, the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction are used as the first video data, the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction or the initial video data of the current segment are retained, and the address information corresponding to the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction and the initial video data of the current segment is recorded; If the video data of adjacent i-th segments in each row in the vertical direction are respectively subjected to difference processing with the initial video data of each current segment, and the difference values obtained after the difference processing are not within the first preset range, it is determined that the first preset range of the difference with the initial video data of the current segment is not satisfied.
[0012] On the other hand, the difference processing process includes: Performing difference processing on the pixel point data corresponding to the video data of the adjacent i-th segment and the initial video data of the current segment to obtain difference data corresponding to each pixel point data; The difference data corresponding to each pixel point data is summed up to obtain first summed data as the difference after the difference processing.
[0013] On the other hand, the segment length of the initial video data of the current segment is determined by the amount of compressed data in the compression mode of the video processing strategy.
[0014] On the other hand, the adjacent rows of the block pixel size are the current row and the previous row of data determined by dividing the row data within the block pixel size into every two rows.
[0015] On the other hand, the adjacent rows of the block pixel size are the number of rows of the row data within the block pixel size in sequence of the current row and the previous row; wherein, except for the first row, each video data of each row is compared twice as an adjacent row.
[0016] On the other hand, the process of establishing the first information table includes: The video data of the adjacent i-th segment and the initial video data of the current segment are stored in the first information table in the form of binary data, and the video data of each field corresponds to preset bit width information; wherein the binary data corresponding to each video data records the segment position relationship between the first video data and the initial video data of the current segment.
[0017] On the other hand, each line of data of different block pixel sizes of the second video data includes one segment of data; and the adjacent second preset segment is zero.
[0018] On the other hand, determining the second video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment includes: Acquire video data of adjacent rows in the horizontal direction corresponding to the row where the initial video data of each current segment is located within the adjacent block pixel size; Comparing the video data of adjacent rows in each horizontal direction with the corresponding initial video data of each current segment; If the differences between the video data of the adjacent rows in the horizontal direction and the corresponding initial video data of the current segments are all less than or equal to the second preset range, determining the second video data; If the difference between the video data of the adjacent rows in the horizontal direction and the corresponding initial video data of the current segments is greater than the second preset range, then comparing the video data of the intersecting rows of the rows corresponding to the initial video data of the current segments within the adjacent block pixel size; If the differences between the video data of the intersecting rows corresponding to the rows where the initial video data of each current segment is located within the adjacent block pixel size are all less than or equal to the second preset range, determining the second video data; If the difference between the video data of the intersecting rows corresponding to the rows where the initial video data of each current segment is located within the adjacent block pixel size is greater than the second preset range, it is determined that the second preset range of the difference with the initial video data of the current segment is not met.
[0019] On the other hand, the process of determining the similarity between the second video data and the initial video data of the current segment in the corresponding pixel size of the corresponding block and the pixel size of the adjacent block includes: Obtaining a comparison result of the video data within the pixel size of the corresponding block and the pixel size of the adjacent block; wherein the comparison result includes the second video data and video data within a second preset range that does not satisfy the difference with the initial video data of the current segment; Determining the proportion information occupied by the second video data in each comparison result; If the proportion information occupied by the second video data is greater than a preset proportion, it is determined that the pixel size of the corresponding block is similar to the video data within the pixel size of an adjacent block.
[0020] On the other hand, the process of determining the similarity between the second video data and the initial video data of the current segment in the corresponding pixel size of the corresponding block and the pixel size of the adjacent block includes: Obtaining a comparison result of the video data within the pixel size of the corresponding block and the pixel size of the adjacent block; wherein the comparison result includes the second video data and video data within a second preset range that does not satisfy the difference with the initial video data of the current segment; Determining the proportion information occupied by the second video data in each comparison result; If the proportion information occupied by the second video data is greater than the preset proportion, and there are video data of adjacent rows in the horizontal direction whose difference does not satisfy the second preset range, performing difference processing on the video data of the adjacent rows in the horizontal direction that does not satisfy the second preset range and the pixel point data corresponding to the initial video data of the current segment to obtain difference data corresponding to each pixel point data; Adding the difference data corresponding to each pixel point data to obtain second added data; If the second summed data is greater than the first preset data, it is determined that the video data within the pixel size of the corresponding block is not similar to the video data within the pixel size of the adjacent block.
[0021] On the other hand, storing the similarity result between the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size in the second information table includes: The similarity results corresponding to the pixel size of the block and the pixel size of the adjacent block are stored in the second information table in the form of binary data; wherein, if the similarity results corresponding to the pixel size of the block and the pixel size of the adjacent block are similar, only the video data corresponding to the pixel size of the block or the pixel size of the adjacent block is read.
[0022] On the other hand, performing data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data includes: When the video processing strategy is a compression mode, the initial video data of the current segment is converted into a data format according to the first information table and the second information table to obtain processed video data; wherein, the compression mode is that the initial video data is subjected to color space conversion and video compression to obtain video data in a compressed format.
[0023] On the other hand, performing data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data includes: When the video processing strategy is a pixel mode, the data format conversion processing is performed on the initial video data of the current segment according to the first information table to obtain processed video data; wherein, the pixel mode is the video data obtained by converting the initial video data through a color space.
[0024] In order to solve the above technical problems, the present invention further provides a video data processing device, comprising: An acquisition module, configured to acquire initial video data of a current segment stored by a host machine and / or a double data rate synchronous dynamic random access memory; A first determination module is used to determine the first video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment; and store the address information of the first video data and the initial video data of the current segment in a first information table; wherein the first video data is video data that satisfies a first preset range of difference with the initial video data of the current segment; and a row of video data includes at least one segment of video data; A second determination module is used to determine the second video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the adjacent second preset segment of the video data; and store the similarity results between the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size in the second information table; wherein the second video data is video data that satisfies the second preset range of the difference with the initial video data of the current segment; The data conversion module is used to perform data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data.
[0025] In order to solve the above technical problems, the present invention further provides a video data processing device, comprising: Memory for storing computer programs; A processor is used to implement the steps of the method for processing video data as described above when executing the computer program.
[0026] In order to solve the above technical problem, the present invention also provides a non-volatile storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the video data processing method as described above are implemented.
[0027] In order to solve the above technical problem, the present invention also provides a computer program product, including a computer program / instruction, which implements the steps of the video data processing method when executed by a processor.
[0028] The present invention provides a method for processing video data, which determines first video data that meets a first preset range of difference with the initial video data of the current segment by comparing the initial video data of the current segment with the adjacent rows of the block pixel size and the video data of the adjacent first preset segment, that is, if the difference between each video data and the initial video data of the current segment meets the first preset range, it means that the initial video data of the current segment is the same or similar to the video data of the pixel size, then skip processing is performed and only one type of data is output. When comparing in different block pixel sizes, the second video data that meets a second preset range of difference with the initial video data of the current segment is determined based on the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment, that is, if the difference between each video data and the initial video data of the current segment meets the second preset range, it means that the two block pixel sizes are the same or similar, then only data of one block pixel size is output.
[0029] The beneficial effect of the present invention is that before data conversion is performed, the initial video data of the current segment is stored in the host machine and / or DDR, thereby ensuring the diversity and flexibility of data acquisition. The first information table and the second information table established directly through comparison processing can determine whether the initial video data of the current segment has the same data or similar data as other video data, thereby avoiding the waste of resources caused by repeated conversion of each segment of data in the same frame and reducing the power consumption of the chip. In the process of comparing the initial video data of the current segment, a first information table is created through comparison processing to facilitate single color space conversion of the same or similar data and avoid repeated data processing. At the same time, based on the comparison processing, a second information table is created to achieve a single block conversion of the same or similar data, avoid repeated data processing, speed up data processing, and improve the performance and service life of the chip.
[0030] Secondly, in the acquisition process of the two-line video data, the comparison is directly performed without the need for DDR cache process, thereby improving the efficiency of data processing. In the process of determining the first video data and the second video data corresponding to the row data comparison and the block data comparison, the initial video data of the current segment of each segment is placed in the corresponding row position to facilitate data comparison. For data comparison, it is necessary to compare the corresponding first video data and the second video data with the stored adjacent rows of the pixel size of the corresponding block and the stored adjacent rows and the adjacent second preset segments within the pixel size of the adjacent block of the pixel size of the corresponding block, respectively, to ensure that the data comparison has a basis. In the row data comparison process, the adjacent rows in the vertical direction and the adjacent segments corresponding to each row are compared with the initial video data of the current segment of the row, while ensuring the parallel comparison of data, the video data of the adjacent rows are also compared, thereby improving the accuracy of data comparison. In the difference processing process, the pixel point data are difference processed one by one to obtain the corresponding difference data, and then the difference after difference processing is obtained by summing up, thereby ensuring the calculation accuracy of the corresponding pixel point data in the data comparison process and improving the accuracy of data screening.
[0031] In addition, the present invention also provides a video data processing device, equipment, medium and product, which have the same beneficial effects as the above-mentioned video data processing method. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] In order to more clearly illustrate the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0033] Figure 1 A flowchart of a method for processing video data provided by an embodiment of the present invention; Figure 2 A schematic diagram of video processing of a server management control chip provided by an embodiment of the present invention; Figure 3 A flowchart of Y data calculation of a color space conversion function provided by an embodiment of the present invention; Figure 4 A flowchart of U data calculation for a color space conversion function provided by an embodiment of the present invention; Figure 5 A flowchart of V data calculation for a color space conversion function provided by an embodiment of the present invention; Figure 6 A processing architecture diagram of a BLOCK conversion module provided in an embodiment of the present invention; Figure 7A schematic diagram of row data comparison provided by an embodiment of the present invention; Figure 8 A schematic diagram of block data comparison provided by an embodiment of the present invention; Fig. 9 An architecture diagram of a data capture preprocessing subsystem provided by an embodiment of the present invention; Fig.10 An architectural diagram of a color space conversion subsystem provided by an embodiment of the present invention; Fig.11 An architectural diagram of a BLOCK conversion subsystem provided by an embodiment of the present invention; Fig.12 A structural diagram of a video data processing device provided by an embodiment of the present invention; Fig.13 A structural diagram of a video data processing device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0034] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0035] The core of the present invention is to provide a method, device, equipment, medium and product for processing video data to solve the problem that a large amount of identical data in the same frame of data leads to waste of processing resources and increased power consumption of the chip.
[0036] In order to enable those skilled in the art to better understand the solution of the present invention, the present invention is further described in detail below in conjunction with the accompanying drawings and specific implementation methods.
[0037] The processing flow of the video function of the traditional SoC chip is to first convert the original optical three primary colors (Red-Green-Blue, RGB) format data, and then convert the color space to generate YUV format video data formed by three components of pixel format brightness (Y), blue color difference (U) and red color difference (V). At this time, the YUV data has two channels, one is directly written into the double data rate synchronous dynamic random access memory (Double Data Rate Synchronous Dynamic Random-Access Memory, DDR), and the other is through the video compression module (such as H.264 format, Joint Photographic Experts Group (JointPhotographic Experts Group, JPEG) format, etc.), to obtain compressed video data, and then write the compressed data to the external DDR. In YUV mode, the video in YUV format is directly input to the output control module and then written to the external DDR.
[0038] A typical SoC chip with integrated video function, that is, the processing flow of the video function in a traditional baseboard management control chip is as follows: the original video data on the host side is transmitted to the VGA module inside the baseboard management control chip via the Peripheral Component Interconnect Express (PCIe) high-speed serial bus, and the VGA generates the original video data in RGB format, which is then processed as described above.
[0039] Because in the real application scenario of the server management and control chip, the monitoring stage will be processed for a long time, that is, the change of the server host operating system interface is very small, and there is a large amount of identical data in the same frame. However, in the traditional scheme, in the compression mode, the same data in the same frame must be converted into color space and BLOCK format, and in the YUV mode, the same data in the same frame must be converted into color space. Because the color space conversion function requires a large number of multiplication and addition operations, it will greatly increase the power consumption of the chip and affect the service life of the chip, and the BLOCK format conversion requires a large amount of on-chip storage resources. In the traditional scheme, at least 16 rows of data need to be stored. According to the 1920*1200 resolution, the on-chip resources required are at least 1920*16*3=92160Bytes, that is, 90KB of on-chip resources, which will greatly occupy the area of the SoC chip. In the actual server management and control chip, the on-chip storage resources account for 1 / 4 of the overall area of the chip, and there are a large number of repeated BLOCK conversions of the same data in the traditional scheme. The processing method of video data provided by the present invention can solve the above technical problems.
[0040] Figure 1A flowchart of a method for processing video data provided by an embodiment of the present invention is shown in FIG. Figure 1 As shown, the method includes: S11: Acquire initial video data of the current segment stored by the host machine and / or the double data rate synchronous dynamic random access memory; S12: determining the first video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment; and storing the address information of the first video data and the initial video data of the current segment in the first information table; The first video data is video data that satisfies a first preset range of difference with the initial video data of the current segment; a line of video data includes at least one segment of video data; S13: Determine the second video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment; and store the similarity results between the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size in the second information table; The second video data is video data that satisfies a second preset range of difference from the initial video data of the current segment; S14: performing data format conversion processing on the initial video data of the current segment according to the video processing strategies corresponding to the first information table and the second information table to obtain processed video data.
[0041] Specifically, the initial video data of the current segment stored in the host machine and / or DDR in step S11, it can be understood that the video data processed in this embodiment are all processed in the same frame of video data, one frame of video data includes multiple lines of video data, and one line of video data includes at least one segment of video data. The initial video data of the current segment transmitted by two paths can be obtained at the same time, that is, two segments of the initial video data of the current segment, to achieve subsequent parallel processing. The initial video data of the current segment transmitted by any path can also be obtained, that is, one segment of the initial video data of the current segment, which is not limited here and can be set according to actual conditions. Figure 2 A schematic diagram of video processing of a server management control chip provided by an embodiment of the present invention is shown in FIG. Figure 2 As shown in the figure, one way is that the host HOST transmits the data to the data capture module through the video graphics array (VGA) module, which is the digital visual interface (DVI) method represented by arrow 1; the other way is that the arrow 2 indicates that the advanced extensible interface (AXI) bus is actively transmitted to the VGA video memory A ( Figure 2 The original video data of the host (operating system interface) is transmitted to the VGA module inside the baseboard management control chip through PCIe, and VGA generates the original video data in RGB format. Figure 2 The space B in is used to store the data output by the output control module.
[0042] The data in RGB format is converted into color space according to the matrix conversion formula to obtain video data in YUV format. The conversion process is completed using the matrix conversion formula: Y=(0.257*R)+(0.504*G)+(0.098*B)+16; U=0.148*R–0.291*G+0.439*B+128; V=0.439*R-0.368*G-0.071*B+128.
[0043] in, Figure 3 A flowchart of Y data calculation of a color space conversion function provided by an embodiment of the present invention, such as Figure 3 As shown, the data parameters corresponding to R, G, and B (PARAM_0, PARAM_1, and PARAM_2, respectively) are added to the data of PARAM_3 being 16 to obtain the Y data. Figure 4 A flowchart of U data calculation for a color space conversion function provided by an embodiment of the present invention is shown in FIG. Figure 4 As shown, the data parameters corresponding to R, G, and B (PARAM_4, PARAM_5, and PARAM_6, respectively) are added to the data of PARAM_7 being 128 to obtain the U data. Figure 5 A flowchart of V data calculation for a color space conversion function provided by an embodiment of the present invention, such as Figure 5 As shown, the data parameters corresponding to R, G, and B (PARAM_8, PARAM_9, and PARAM_10, respectively) are added to the data of PARAM_11 being 128 to obtain the V data.
[0044] The video data in YUV format has two channels, one is input to the post-stage BLOCK conversion module to generate BLOCK format data, and the other is directly input to the output control module and then written into DDR.
[0045] Figure 6 A processing architecture diagram of a BLOCK conversion module provided in an embodiment of the present invention, such as Figure 6As shown, the block conversion module (BLOCK conversion module) realizes the BLOCK conversion of YUV data. According to the YUV444 / YUV420 format, the size of BLOCK is 16*16 or 8*8, so it needs 16 Y_RAM (Y_0-Y_15), 16 U_RAM (U_0-U_15), and 16 V_RAM (V_0-V_15). Figure 6 YUV_RAM_ARRAY (pixel storage array) in.
[0046] The JPEG compression module receives the YUV data in BLOCK format, and then performs video compression to obtain the compressed data in JPEG format, which is then output to the output control module. The output control module receives the compressed video data or the original video data in YUV format, and then writes it into DDR, which is then read by the driver of the network module and sent to the remote end through the network for display.
[0047] In step S12, the first video data is determined based on the comparison relationship between the initial video data of the current segment and the adjacent rows of the pixel size of the block to which it belongs, and the video data of the adjacent first preset segment. If the initial video data of the current segment is obtained in a certain way, it is necessary to compare it with the video data of the adjacent rows of the current segment and the adjacent first preset segment within the same pixel size to determine whether it is the same or similar video data as the initial video data of the current segment. If it exists, it is determined as the first video data, and the address information of the first video data and the initial video data of the current segment is stored in the first information table. The corresponding comparison method is not limited, and can be based on the comparison of each pixel point data in the segment to determine the corresponding difference, or it can be based on each segment through a certain specific algorithm. It can be set according to the actual situation. The first preset segment can be an adjacent segment, two segments, etc., which is not limited here. The adjacent row is only the video data set in the previous row of the current segment.
[0048] The comparison relationship between the adjacent rows of the adjacent block pixel sizes corresponding to the initial video data of the current segment in step S13 and the video data of the adjacent second preset segment determines whether there is video data that is the same or similar to the initial video data of the current segment. If there is, it is used as the second video data. And the similarity results of the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size are stored in the second information table. In other words, the second information table stores the similarity results of the two block pixel sizes. The second preset range corresponding to the second video data can be the same as the first preset range in step S12, or it can be different. It is not limited here and can be set according to actual conditions.
[0049] It is understandable that the comparison process in step S13 may be the same as or different from the comparison process in step S12, which is not limited here.
[0050] In step S14, the initial video data of the current segment is converted into a data format according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data. It can be understood that the first information table is located at Figure 2 The color conversion module in the block conversion module, the second information table is located in the block conversion module. Since the video data processing path includes two paths, one is that the color conversion module directly gives it to the output control module, and the other is that the video compression module is performed to the output control module after passing through the color conversion module and the BLOCK conversion module. Therefore, the corresponding video processing strategy of the first information table and the second information table is designed based on two paths. There can be only the first information table, or the first information table and the second information table perform data format conversion processing on the initial video data of the current segment to obtain the processed video data. Specifically, through the first information table and the second information table, it can be known whether the stored video data contains data that is the same or similar to the initial video data of the current segment, so as to directly skip the processing and save some resources.
[0051] The embodiment of the present invention provides a method for processing video data, which determines the first video data that meets the first preset range of the difference with the initial video data of the current segment by comparing the initial video data of the current segment with the adjacent rows of the block pixel size and the video data of the adjacent first preset segment, that is, if the difference between each video data and the initial video data of the current segment meets the first preset range, it means that the initial video data of the current segment is the same or similar to the video data of the pixel size, then skip processing is performed, and only one type of data is output. When comparing in different block pixel sizes, the second video data that meets the second preset range of the difference with the initial video data of the current segment is determined according to the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment, that is, if the difference between each video data and the initial video data of the current segment meets the second preset range, it means that the two block pixel sizes are the same or similar, then only one type of block pixel size data is output. Before data conversion is performed, the initial video data of the current segment is stored by the host and / or DDR to ensure the diversity and flexibility of data acquisition. The first information table and the second information table established directly through comparison processing can determine whether the initial video data of the current segment has the same data or similar data as other video data, which can avoid the waste of resources caused by repeated conversion of each segment of data in the same frame and reduce the power consumption of the chip. In the process of comparing the initial video data of the current segment, the first information table is created through comparison processing to facilitate single color space conversion of the same or similar data and avoid repeated data processing. At the same time, based on the comparison processing, the second information table is created to achieve a single block conversion of the same or similar data, avoid repeated data processing, speed up data processing, and improve the performance and service life of the chip.
[0052] In some embodiments, initial video data of the current segment stored in the host machine and the double data rate synchronous dynamic random access memory are obtained; wherein the initial video data of each current segment occupies one line respectively.
[0053] It can be understood that the two ways of obtaining the initial video data of the two current segments in this embodiment respectively occupy one line, and the formed parallel video data is subsequently compared, and two adjacent lines of original video data are captured at the same time, one way is obtained through the DVI interface, such as lines 0, 2, 4..., and the other way is obtained by active acquisition, such as lines 1, 3, 5... Therefore, the submodule internally integrates the DVI interface, AXI Master read interface, resolution analysis, pixel counting and other functions, and the two adjacent lines of data obtained are not cached internally, and are directly compared in parallel.
[0054] The acquisition process of the dual-line video data provided in this embodiment directly compares without requiring a DDR cache process, thereby improving the efficiency of data processing.
[0055] In some embodiments, in the process of determining the first video data, adjacent rows of the block pixel size are row data respectively occupied by initial video data of each current segment, and the initial video data of each current segment belongs to the same block pixel size; In determining the second video data, the initial video data of each current segment occupies different rows of the same block pixel size.
[0056] It is understandable that in the process of determining the first video data and the second video data, the initial video data of the current segment occupies different positions. In the process of determining the first video data, the initial video data of each current segment occupies different rows, but belongs to the same block pixel size. Figure 7 A schematic diagram of row data comparison provided by an embodiment of the present invention, such as Figure 7 As shown, there are two rows of data in total, and each row of data includes three segments of data. The initial video data of the current segment is in the last segment of each row of data. The comparison process is based on the initial video data of the current segment of each row. It can also be based on the comparison of the video data of other adjacent segments of its own row, or the comparison of the video data of adjacent segments of cross rows, etc.
[0057] Figure 8 A schematic diagram of block data comparison provided by an embodiment of the present invention, such as Figure 8 As shown, the initial video data of each current segment occupies different rows of the same block pixel size, that is, Figure 8 LINE_DATA_0 and LINE_DATA_2 of BLOCK A in .
[0058] In the process of determining the first video data and the second video data corresponding to the row data comparison and the block data comparison provided by the present invention, the initial video data of each current segment is placed in the corresponding row position to facilitate data comparison.
[0059] In some embodiments, when the initial video data of the current segment is acquired by the host machine or the double data rate synchronous dynamic random access memory, the first video data is determined according to a comparison relationship between the initial video data of the current segment and each video data of the stored adjacent rows and adjacent first preset segments of the corresponding block pixel size; Correspondingly, the second video data is determined according to the comparison relationship between the initial video data of the current segment and the stored adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment.
[0060] It is understandable that the initial video data of the current segment obtained by the host machine or a certain way of DDR needs to be compared with the video data of adjacent rows and adjacent segments that have been stored in order to facilitate the comparison of row data and block data.
[0061] Specifically, the first video data is determined based on the comparison relationship between the initial video data of the current segment and the stored adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment; the second video data is determined based on the comparison relationship between the initial video data of the current segment and the stored adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment.
[0062] The data comparison provided in this embodiment needs to be compared with the stored adjacent rows and adjacent first preset segments of the corresponding block pixel size; the stored adjacent rows and adjacent second preset segments within the adjacent block pixel size of the corresponding block pixel size are compared to determine the corresponding first video data and second video data, so as to ensure that the data comparison has a basis.
[0063] In some embodiments, determining the first video data according to a comparison relationship between the initial video data of the current segment and the video data of adjacent rows of the corresponding block pixel size and adjacent first preset segments includes: Determine whether the initial video data of each current segment in adjacent rows in the vertical direction formed by the rows where the initial video data of each current segment is located are the same; If they are the same, it is determined that the initial video data of each current segment is the same, the initial video data of one current segment is retained, and the address information corresponding to the initial video data of each current segment is recorded; If they are different, then the video data of the adjacent i-th segment in each row in the horizontal direction are respectively subjected to difference processing with the initial video data of each current segment; wherein 1≤i≤N, N is a positive integer, and N is less than or equal to the first preset segment; If the difference after difference processing is within the first preset range, the video data of the adjacent i-th segment in each row in the horizontal direction is used as the first video data, the video data of the adjacent i-th segment or the initial video data of the current segment is retained, and the address information corresponding to the video data of the adjacent i-th segment and the initial video data of the current segment is recorded; If the difference value after the difference processing is not within the first preset range, it is determined that the first preset range of the difference value with the initial video data of the current segment is not satisfied.
[0064] Specifically, Figure 7As shown, the initial video data of each current segment in the adjacent rows in the vertical direction formed by the rows where the initial video data of each current segment is located are first checked to see if they are the same. If they are the same, it means that there is data that is the same as the initial video data of the current segment, and then the initial video data of one current segment can be retained. At this time, the first video data is the data that is the same as the initial video data of the current segment.
[0065] If they are not the same, the video data of the adjacent i-th segment in each row in the horizontal direction are successively subjected to difference processing with the initial video data of each current segment. It can be understood here that the video data of the adjacent first segment is first subjected to difference processing with the initial video data of each current segment. If the difference is within the first preset range, the video data of the adjacent first segment in each row in the horizontal direction is used as the first video data, the video data of the adjacent first segment or the initial video data of the current segment is retained, and the address information corresponding to the video data of the adjacent first segment and the initial video data of the current segment is recorded. If the difference after the difference processing is not within the first preset range, it is determined that the first preset range of the difference with the initial video data of the current segment is not satisfied. Continue to compare the video data of the adjacent second segment with the initial video data of each current segment for difference processing, and compare the video data of the last segment one by one.
[0066] The row data comparison process of this embodiment compares the adjacent rows in the vertical direction and the adjacent segments corresponding to each row with the initial video data of the current segment of its own row, thereby ensuring parallel comparison of data while also comparing the video data of adjacent rows, thereby improving the accuracy of data comparison.
[0067] In some embodiments, determining the first video data according to a comparison relationship between the initial video data of the current segment and the video data of adjacent rows of the corresponding block pixel size and adjacent first preset segments includes: Determine whether the initial video data of each current segment in adjacent rows in the vertical direction formed by the rows where the initial video data of each current segment is located are the same; If they are the same, it is determined that the initial video data of each current segment is the same, the initial video data of one current segment is retained, and the address information corresponding to the initial video data of each current segment is recorded; If they are different, then the video data of the adjacent i-th segment in each row in the horizontal direction are respectively subjected to difference processing with the initial video data of each current segment; wherein 1≤i≤N, N is a positive integer, and N is less than or equal to the first preset segment; If the difference after the difference processing is within the first preset range, the video data of the adjacent i-th segment in the respective same line in the horizontal direction is used as the first video data, the video data of the adjacent i-th segment in the respective same line in the horizontal direction or the initial video data of the current segment is retained, and the address information corresponding to the video data of the adjacent i-th segment in the respective same line in the horizontal direction and the initial video data of the current segment is recorded; If the difference after the difference processing is not within the first preset range, it is determined that the video data of the i-th segment of the intersecting adjacent rows in the vertical direction are respectively subjected to difference processing with the initial video data of the respective current segments; If the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction are respectively subjected to difference processing with the initial video data of the respective current segments, and the difference values after the difference processing are within a first preset range, the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction are used as the first video data, the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction or the initial video data of the current segment are retained, and the address information corresponding to the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction and the initial video data of the current segment is recorded; If the video data of the adjacent i-th segments in each row in the vertical direction are respectively subjected to difference processing with the initial video data of the respective current segments, and the difference values obtained after the difference processing are not within the first preset range, it is determined that the first preset range of the difference value with the initial video data of the current segment is not satisfied.
[0068] Based on the above embodiment, if the difference after difference processing is not within the first preset range, the video data of the i-th segment of the adjacent vertical lines is further determined to be difference processed with the initial video data of the current segment. Figure 7 For example, the video data of two adjacent segments are compared with the cross-adjacent segments. For example, CUR_DATA_0 (the initial video data_0 of the current segment) is compared with the video data of the first cross-adjacent segment (DATA_1, i.e. data_1). CUR_DATA_0 is compared with the video data of the second cross-adjacent segment (DATA_3, i.e. data_3). This comparison method also uses successive comparison, and the specific comparison process is not repeated here.
[0069] The row data comparison process of this embodiment adds the comparison of cross-adjacent segments in the vertical direction on the basis of the process of comparing adjacent rows in the vertical direction and the adjacent segments corresponding to each row with the initial video data of the current segment of the row itself. While ensuring parallel comparison of data, video data comparison of cross-adjacent segments of adjacent rows is also performed to improve the accuracy of data comparison.
[0070] In some embodiments, the difference processing process includes: Performing difference processing on the pixel point data corresponding to the video data of the adjacent i-th segment and the initial video data of the current segment to obtain difference data corresponding to each pixel point data; The difference data corresponding to each pixel point data is summed up to obtain first summed data as the difference after the difference processing.
[0071] Specifically, the difference processing of the video data between segments is based on the difference processing of the pixel point data corresponding to the same position to obtain the difference data corresponding to each pixel point data. The difference data corresponding to each pixel point data is summed to obtain the first summed data as the difference after the difference processing.
[0072] This embodiment provides a difference processing process, which performs difference processing on pixel point data one by one to obtain corresponding difference data, and then performs addition processing to obtain the difference after difference processing, thereby ensuring the calculation accuracy of the corresponding pixel point data during the data comparison process and improving the accuracy of data screening.
[0073] In some embodiments, the process of establishing the first information table includes: The video data of the adjacent i-th segment and the initial video data of the current segment are stored in the first information table in the form of binary data, and the video data of each field corresponds to preset bit width information; wherein the binary data corresponding to each video data records the segment position relationship between the first video data and the initial video data of the current segment.
[0074] Specifically, Figure 7 Taking the two adjacent data segments shown as an example, Table 1 is a first information table, as shown in Table 1: Table 1
[0075] See Table 1, CUR_DATA_0 indicates Figure 7 The initial video data of the current segment in CUR_DATA_0, CUR_DATA_1 indicates Figure 7 The initial video data of the current segment in _1; DATA_0, DATA_1, DATA_2, DATA_3 represent Figure 7 Data_0, data_1, data_2, data_3 in the binary data are 0001, 0010, 0011, 0100, 0101, etc. The video data of each field corresponds to the preset bit width information. The preset bit width information here is the same, and it also corresponds to 4 binary data. Take 4'h1 as an example, it means 4 binary data representation, h represents hexadecimal data 1, and 1 is converted to binary 0001.
[0076] CUR_DATA_0 refers to the data of CMP_LENGTH length of the 0th / 2nd / 4th... segments (such as the 64th-95th pixels) obtained through the DVI interface, and CUR_DATA_1 refers to the data of CMP_LENGTH length of the 1st / 3rd / 5th... segments (such as the 64th-95th pixels) obtained by active acquisition.
[0077] DATA_0 refers to the first CMP_LENGTH length of reference data adjacent to CUR_DATA_0, DATA_2 refers to the first CMP_LENGTH length of reference data adjacent to DATA_0, DATA_1 refers to the first CMP_LENGTH length of reference data adjacent to CUR_DATA_1, and DATA_3 refers to the first CMP_LENGTH length of reference data adjacent to DATA_1.
[0078] First, CUR_DATA_0 and CUR_DATA_1 are compared, that is, the corresponding positions are subtracted, and then the absolute value of the subtracted value is accumulated. If the accumulated value does not exceed CMP_THREHOLD, CUR_DATA_0 and CUR_DATA_1 are considered to be similar comparison segments, and the first information table is updated. The final information table is a 4-bit wide information corresponding to each field.
[0079] The process of establishing the first information table provided in this embodiment is stored in the form of binary data, which saves memory space occupied by the data and facilitates rapid identification of corresponding identical or similar video data.
[0080] In some embodiments, the segment length of the initial video data of the current segment is determined by the amount of compressed data in the compression mode of the video processing strategy.
[0081] Specifically, the segment length is the comparison length when comparing two adjacent rows of data, such as 16 or 32. The larger the value, the better the merging of the same or similar data can be, and the larger the amount of data reduced after comparison will be. However, the compression quality will decrease when the image is compressed. The smaller the value, the smaller the amount of data reduced after comparison will be, and the compression quality will increase when the image is compressed.
[0082] The specific length of the segment length provided in this embodiment is determined by the amount of compressed data in the compression mode of the video processing strategy to ensure that the compression quality of the compressed data amount and the data amount comparison process are in a balanced state.
[0083] Correspondingly, the first preset range and the second preset range are similar. The larger the preset range, the larger the amount of data reduced after comparison, but the compression quality during image compression will decrease simultaneously. The smaller the value, the smaller the amount reduced after comparison, and the compression quality during image compression will increase simultaneously. The specific configuration value depends on the user's needs. You can also use the system default configuration.
[0084] In some embodiments, the adjacent rows of the block pixel size are the current row and the previous row of data determined by dividing the row data within the block pixel size into every two rows.
[0085] It can be understood that adjacent rows are the current row and the previous row of data determined by segmentation every two rows, that is, the row data is compared only once each time, for example, the video data of row 0 is compared with row 1, the video data of row 2 is compared with row 3, and so on.
[0086] In other embodiments, in order to improve the comparison accuracy of data, adjacent rows of the block pixel size are the number of rows in which the row data within the block pixel size is sequentially carried out with the current row and the previous row; wherein, except for the first row, each row of video data is compared twice as adjacent rows.
[0087] Specifically, except for the first line of video data, each of the remaining lines of video data can be used as adjacent lines and compared twice. For example, the video data of line 0 is compared with the video data of line 1, and the video data of line 1 is compared with the video data of line 2, and so on.
[0088] The comparison process of two adjacent rows of data provided in this embodiment saves data comparison time in the embodiment divided into two rows. In the second embodiment, except for the first row comparison, the remaining video data of each row are compared twice to improve the accuracy of data comparison.
[0089] In some embodiments, each row of data of different block pixel sizes of the second video data includes one segment of data; and the adjacent second preset segment is zero.
[0090] Specifically, Figure 8 As shown, each row of data includes a segment of data, and the corresponding adjacent second preset segment is 0. Therefore, the comparison at this time can only be performed by comparing data of different block pixel sizes. If there is an adjacent second preset segment, the data within the same block pixel size is first compared, referring to the above-mentioned row data comparison process. Then the data of different block pixel sizes are compared, so that the comparison result of the data of two block pixel sizes is finally achieved.
[0091] In some embodiments, determining the second video data according to a comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment includes: Obtaining video data of adjacent rows in the horizontal direction of the row where the initial video data of each current segment is located within the adjacent block pixel size; Compare the video data of adjacent rows in each horizontal direction with the initial video data of each corresponding current segment; If the differences between the video data of the adjacent rows in each horizontal direction and the initial video data of each corresponding current segment are all less than or equal to the second preset range, determining the second video data; If there is a difference between the video data of adjacent rows in each horizontal direction and the corresponding initial video data of each current segment that is greater than a second preset range, then comparing the video data of the intersecting rows of the rows where the initial video data of each current segment is located within the adjacent block pixel size; If the differences between the video data of the intersecting rows corresponding to the rows where the initial video data of each current segment is located within the adjacent block pixel size are all less than or equal to the second preset range, then determining the second video data; If the difference between the video data of the intersecting rows corresponding to the rows where the initial video data of each current segment is located within the adjacent block pixel size is greater than the second preset range, it is determined that the second preset range of the difference with the initial video data of the current segment is not satisfied.
[0092] Specifically, Figure 8 As shown, since there is no adjacent second preset segment at present, only the lines are compared. Therefore, the video data of the adjacent lines in the horizontal direction are compared with the initial video data of the corresponding current segments, that is, LINE_DATA_0 ( Figure 8 The initial video data of the current segment in LINE_DATA_0) and LINE_DATA_1 ( Figure 8 LINE_DATA_1) in the comparison, LINE_DATA_2 ( Figure 8 The initial video data of the current segment in LINE_DATA_2) and LINE_DATA_3 ( Figure 8 _3), if the corresponding difference values are all less than or equal to the second preset range, the second video data is determined, which means that there is video data that is the same or similar to the initial video data of each current segment, and the video data that is the same or similar to the initial video data of each current segment is used as the second video data.
[0093] If the difference between the video data of adjacent rows in each horizontal direction and the initial video data of the corresponding current segments is greater than the second preset range, the video data of the intersecting rows of the rows corresponding to the initial video data of the current segments in the adjacent block pixel size are compared; if the difference between the video data of the intersecting rows of the rows corresponding to the initial video data of the current segments in the adjacent block pixel size is less than or equal to the second preset range, the second video data is determined, which means that there is video data that is the same or similar to the initial video data of the current segments, and the video data that is the same or similar to the initial video data of the current segments is used as the second video data. If the difference between the video data of the intersecting rows of the rows corresponding to the initial video data of the current segments in the adjacent block pixel size is greater than the second preset range, it is determined that the second preset range of the difference with the initial video data of the current segment is not satisfied.
[0094] The process of comparing video data of adjacent rows in the horizontal direction and comparing video data of intersecting rows provided in this embodiment further expands the comparison range and improves the accuracy of the compared data.
[0095] In some embodiments, the process of determining the similarity between the second video data and the initial video data of the current segment in terms of the pixel size of the corresponding block and the pixel size of the adjacent block includes: Obtaining a comparison result of the video data within the pixel size of the corresponding block and the pixel size of the adjacent block; wherein the comparison result includes the second video data and video data within a second preset range that does not satisfy the difference with the initial video data of the current segment; Determining the proportion information occupied by the second video data in each comparison result; If the proportion information occupied by the second video data is greater than the preset proportion, it is determined that the pixel size of the corresponding block is similar to the video data within the pixel size of the adjacent block.
[0096] Specifically, Figure 8 For example, the size of the corresponding BLOCK (block pixel size_A and block pixel size_B) is 16*16, and the size of CMP_LENGTH is 32, so 8 comparison results will be obtained, namely: Result_0 (comparison result of row 0 and row 1 of BLOCK_A / BLOCK_B) - (similar / dissimilar); Result_1 (Comparison result of row 2 and row 3 of BLOCK_A / BLOCK_B) - (similar / dissimilar); Result_2 (comparison results of rows 4 and 5 of BLOCK_A / BLOCK_B) - (similar / dissimilar); Result_3 (Comparison results of rows 6 and 7 of BLOCK_A / BLOCK_B) - (similar / dissimilar); Result_4 (Comparison results of rows 8 and 9 of BLOCK_A / BLOCK_B) - (similar / dissimilar); Result_5 (Comparison results of rows 10 and 11 of BLOCK_A / BLOCK_B) - (similar / dissimilar); Result_6 (Comparison results of rows 12 and 13 of BLOCK_A / BLOCK_B) - (similar / dissimilar); Result_7 (Comparison results of rows 14 and 15 of BLOCK_A / BLOCK_B) - (similar / dissimilar).
[0097] The proportion information occupied by the second video data is determined in each comparison result, that is, in the statistics of Result_0-Result_7, the number of similar and identical results = M; the occupied proportion information is M / 8. If the proportion information is greater than the preset proportion, it means that the pixel size of the block to which it belongs is similar to the video data within the pixel size of the adjacent block, that is, BLOCK_A and BLOCK_B are similar.
[0098] The preset ratio may be set by configuring a register according to the user, or by using a default value, etc., which is not limited here and can be set according to actual conditions.
[0099] In some other embodiments, the process of determining the similarity between the second video data and the initial video data of the current segment in the corresponding pixel size of the corresponding block and the pixel size of the adjacent block includes: Obtaining a comparison result of the video data within the pixel size of the corresponding block and the pixel size of the adjacent block; wherein the comparison result includes the second video data and video data within a second preset range that does not satisfy the difference with the initial video data of the current segment; Determining the proportion information occupied by the second video data in each comparison result; If the proportion information occupied by the second video data is greater than the preset proportion, and there are video data of adjacent rows in the horizontal direction whose difference does not meet the second preset range, then difference processing is performed on the video data of the adjacent rows in the horizontal direction that does not meet the second preset range and the pixel point data corresponding to the initial video data of the current segment to obtain difference data corresponding to each pixel point data; Adding the difference data corresponding to each pixel point data to obtain second added data; If the second summed data is greater than the first preset data, it is determined that the pixel size of the corresponding block is not similar to the video data within the pixel size of the adjacent block.
[0100] Specifically, based on the above embodiment, if the proportion information occupied by the second video data is greater than the preset proportion, the difference of the video data of the adjacent rows in the horizontal direction is continued to be compared to see whether it meets the second preset range. If not, the video data of the adjacent rows in the horizontal direction that do not meet the second preset range are subjected to difference processing with the pixel data corresponding to the initial video data of the current segment to obtain the difference data corresponding to each pixel data. In other words, even if the video data of multiple rows in the two block pixel sizes are similar, but there is a large difference in the video data of the last row, that is, the difference exceeds the second preset range, it is necessary to continue to determine whether the two block pixel sizes are similar, and the difference data corresponding to each pixel data is summed to obtain the second sum data. If the second sum data is greater than the first preset data, it means that the video data of the two block pixel sizes are not similar. This is in accordance with the scene judgment process in which most of the fields in two adjacent BLOCKs are similar, but only a few segments are not similar, and the pixel values of these segments are very different, so that the judgment is more accurate.
[0101] This embodiment provides two specific methods for comparing block data. The first method determines the similarity of block pixel sizes only through ratio information, and the second method determines the similarity of block pixel sizes through difference processing of pixel point data on the basis of the determination through ratio information. Regardless of the comparison method, similar comparison of block pixel processing is achieved, thereby improving the comparison accuracy of data.
[0102] In some embodiments, storing similar results of the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size in the second information table includes: The similarity results corresponding to the pixel size of the block and the pixel size of the adjacent block are stored in the second information table in the form of binary data; wherein, if the similarity results corresponding to the pixel size of the block and the pixel size of the adjacent block are similar, only the video data corresponding to the pixel size of the block or the pixel size of the adjacent block is read.
[0103] Specifically, Figure 8 Taking the two adjacent data segments shown in the figure as an example, Table 2 is the second information table. In YUV420 mode, the comparison size inside the module is recorded as BLOCK_LENGTH=16; in YUV444 mode, the comparison size inside the module is recorded as N=8. As shown in Table 2: Table 2
[0104] See Table 2, LINE_DATA_0 and LINE_DATA_2 correspond to Figure 8 The initial video data of the current segment_0 and the initial video data of the current segment_2. LINE_DATA_1 and LINE_DATA_3 represent Figure 8 In row data_1 and row data_3, it should be noted that Figure 8 The initial video data of the current segment_0 and the initial video data of the current segment_2 in the current segment only indicate Figure 8 The data comparison is irrelevant to other graphs. Similar BLOCK judgment results: if a group of BLOCKs are similar (BLOCK_A and BLOCK_B), the information of BLOCK_A is 2'b01 and the information of BLOCK_B is 2'b10; if a group of BLOCKs are dissimilar (BLOCK_A and BLOCK_B), the information of BLOCK_A is 2'b11 and the information of BLOCK_B is 2'b11.
[0105] The process of establishing the second information table provided in this embodiment is stored in the form of binary data, which saves memory space occupied by the data and facilitates rapid identification of corresponding identical or similar video data.
[0106] In some embodiments, performing data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data includes: When the video processing strategy is a compression mode, the initial video data of the current segment is converted into a data format according to the first information table and the second information table to obtain processed video data; wherein the compression mode is the initial video data being converted into a color space and compressed to obtain video data in a compressed format.
[0107] Fig. 9 An architecture diagram of a data capture preprocessing subsystem provided by an embodiment of the present invention, such as Fig. 9 As shown, the initial video data of the current segment in two ways is obtained through a dual-row data acquisition module, the segment length and preset range data in the size threshold module are obtained, the first information table is created through a row data comparison module, and the second information table is created through a block data comparison module.
[0108] Fig.10 An architecture diagram of a color space conversion subsystem provided by an embodiment of the present invention, such as Fig.10 As shown, there are two Y data calculation modules, two U data calculation modules, and two V data calculation modules because it is possible that the RGB data acquisition module may obtain data through two channels at the same time. For example, 4'b0101 and 4'b1000 are obtained at the same time, indicating that the RGB data acquisition module (optical three primary colors data acquisition module) needs to obtain RGB data from two channels (RGB data channel 0 (optical three primary colors data channel 0) and RGB data channel 1 (optical three primary colors data channel 1)) at the same time, and perform color space conversion respectively. Figures 3 to 5The schematic diagram avoids repeated color space conversion of a large number of identical or similar data. The calculation of one Y / U / V component requires three multiplications and three additions, which greatly reduces the power consumption of the chip and increases the service life of the chip.
[0109] Mainly through the first information table parsing control module, the front-stage data capture preprocessing subsystem reads information table 1, each field corresponds to a 4-bit width, and the information of two fields is obtained at the same time, that is, the data in two 4-bit wide first information tables are obtained at the same time. Table 3 is a parsing table for parsing the first information table, as shown in Table 3: Table 3
[0110] Fig.11 An architecture diagram of a BLOCK conversion subsystem provided by an embodiment of the present invention, such as Fig.11 As shown, it mainly includes a second information table parsing control module, a BLOCK data recovery module, a YUV RAM array (16 Y_RAMs / 16 U_RAMs / 16 V_RAMs), a YUV RAM array write controller, a YUV RAM array read controller, and a YUV data acquisition module.
[0111] Because YUV data is input in rows, Figure 8 For example, only after completing the input of BLOCK_A and BLOCK_B, can the information in the second information table of BLOCK_A and BLOCK_B be obtained. Each BLOCK corresponds to a 2-bit width, and obtaining the information of two BLOCKs at the same time means obtaining the information data in two 2-bit wide second information tables at the same time.
[0112] Therefore, on the writing side, it is consistent with the traditional solution, but on the reading side, the information in the second information table is obtained through the second information table parsing control module. Table 4 is a parsing table for parsing the second information table, as shown in Table 4: Table 4
[0113] See Table 4. When the second information table parsing controller obtains {2'b01, 2'b10}, it parses out that the two groups of BLOCK data in the current BLOCK group are similar, and then controls the YUV RAM array read controller to skip reading the next BLOCK after reading the previous BLOCK of the current group, and directly complete the BLOCK data by the BLOCK data recovery module. For example, if BLOCK_A is read but the data of BLOCK_B is not read, the size of the current BLOCK is 16*16, Y_BLOCK reads Y_RAM_0-Y_RAM_15 16 times each, U_BLOCK reads U_RAM_0-U_RAM_15 16 times each, and V_BLOCK reads V_RAM_0-V_RAM_15 16 times each. Then, when the next BLOCK of the current BLOCK group is obtained, there is no need to read it from the YUVRAM array again. The BLOCK data recovery module can directly copy the data of the previous BLOCK (including Y_BLOCK, U_BLOCK, V_BLOCK) and pass it to the subsequent JPEG compression module.
[0114] If the controller obtains {2'b11, 2'b11} when parsing the second information table, it is consistent with the traditional solution, and the order of the front and back blocks of a group of blocks can be generated.
[0115] In some other embodiments, performing data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data includes: When the video processing strategy is pixel mode, the data format conversion processing is performed on the initial video data of the current segment according to the first information table to obtain processed video data; wherein the pixel mode is the video data obtained by converting the initial video data through color space conversion.
[0116] It can be understood that, based on the corresponding path in the pixel mode, the initial video data of the current segment is converted into a data format only through the first information table to obtain the processed video data.
[0117] The two video processing strategies provided in this embodiment have different corresponding information tables in different modes, which makes the video processing diversified. Regardless of the video processing strategy, it can avoid the repeated generation of adjacent and similar BLOCK data, speed up the video processing speed, and improve the overall performance of the chip.
[0118] The above describes in detail various embodiments corresponding to the method for processing video data. On this basis, the present invention also discloses a video data processing device corresponding to the above method. Fig.12FIG. 1 is a structural diagram of a video data processing device provided by an embodiment of the present invention. Fig.12 As shown, the video data processing device includes: An acquisition module 11 is used to acquire initial video data of a current segment stored by a host machine and / or a double data rate synchronous dynamic random access memory; The first determination module 12 is used to determine the first video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment; and store the address information of the first video data and the initial video data of the current segment in the first information table; wherein the first video data is the video data that satisfies the first preset range of the difference with the initial video data of the current segment; and a row of video data includes at least one segment of video data; The second determination module 13 is used to determine the second video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the adjacent second preset segment of the video data; and store the similarity results between the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size in the second information table; wherein the second video data is the video data that satisfies the second preset range of the difference with the initial video data of the current segment; The data conversion module 14 is used to perform data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data.
[0119] Since the embodiments of the device part correspond to the above embodiments, please refer to the description of the embodiments of the method part for the embodiments of the device part, and will not be repeated here.
[0120] For an introduction to a video data processing device provided by the present invention, please refer to the above method embodiment, and the present invention will not be repeated here. It has the same beneficial effects as the above video data processing method.
[0121] Fig.13 A structural diagram of a video data processing device provided by an embodiment of the present invention, such as Fig.13 As shown, the device includes: A memory 21, used for storing computer programs; The processor 22 is used to implement the steps of the video data processing method when executing the computer program.
[0122] Among them, the processor 22 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 22 may be implemented in at least one hardware form of a digital signal processor (DSP), a field-programmable gate array (FPGA), and a programmable logic array (PLA). The processor 22 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a central processing unit (CPU); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 22 may be integrated with a graphics processing unit (GPU), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 22 may also include an artificial intelligence (AI) processor, which is used to process computing operations related to machine learning.
[0123] The memory 21 may include one or more non-volatile storage media, which may be non-transitory. The memory 21 may also include a high-speed random access memory, and a non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In this embodiment, the memory 21 is at least used to store the following computer program 211, wherein, after the computer program is loaded and executed by the processor 22, it can implement the relevant steps of the video data processing method disclosed in any of the aforementioned embodiments. In addition, the resources stored in the memory 21 may also include an operating system 212 and data 213, etc., and the storage method may be short-term storage or permanent storage. Among them, the operating system 212 may include Windows, Unix, Linux, etc. The data 213 may include but is not limited to data involved in the video data processing method, etc.
[0124] In some embodiments, the video data processing device may further include a display screen 23 , an input / output interface 24 , a communication interface 25 , a power supply 26 , and a communication bus 27 .
[0125] Those skilled in the art can understand that Fig.13 The structure shown in the figure does not constitute a limitation on the video data processing device, and may include more or less components than those shown in the figure.
[0126] The processor 22 implements the video data processing method provided by any of the above embodiments by calling the instructions stored in the memory 21 .
[0127] For an introduction to a video data processing device provided by the present invention, please refer to the above method embodiment, and the present invention will not be repeated here. It has the same beneficial effects as the above video data processing method.
[0128] Furthermore, the present invention also provides a non-volatile storage medium, on which a computer program is stored, and when the computer program is executed by the processor 22, the steps of the above-mentioned video data processing method are implemented.
[0129] It is understandable that if the method in the above embodiment is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a non-volatile storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium and executes all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.
[0130] For an introduction to a non-volatile storage medium provided by the present invention, please refer to the above method embodiment, which will not be described in detail herein. The non-volatile storage medium has the same beneficial effects as the above video data processing method.
[0131] Furthermore, the present invention also provides a computer program product, comprising a computer program / instruction, which implements the steps of the method for processing video data when executed by a processor.
[0132] For an introduction to a computer program product provided by the present invention, please refer to the above method embodiment, which will not be described in detail herein. The computer program product has the same beneficial effects as the above video data processing method.
[0133] The above is a detailed introduction to a video data processing method, device, equipment, medium and product provided by the present invention. The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same and similar parts between the embodiments can be referenced to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description. It should be pointed out that for ordinary technicians in this technical field, without departing from the principle of the present invention, several improvements and modifications can be made to the present invention, and these improvements and modifications also fall within the scope of protection of the present invention.
[0134] It should also be noted that, in this specification, relational terms such as first and second, etc. are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "comprises", "comprising" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device including the element.
Claims
1. A method for processing video data, characterized in that: include: Retrieve initial video data of the current segment stored by the host and / or the double data rate synchronous dynamic random access memory; Determine the first video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment; and store the address information of the first video data and the initial video data of the current segment in the first information table; wherein the first video data is video data that satisfies the first preset range of the difference with the initial video data of the current segment; and a row of video data includes at least one segment of video data; Determine the second video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the adjacent second preset segment of the video data; and store the similarity results of the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size in the second information table; wherein the second video data is video data that satisfies the second preset range of the difference with the initial video data of the current segment; The initial video data of the current segment is converted into a data format according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data.
2. The method for processing video data according to claim 1, characterized in that: The initial video data of the current segment respectively stored by the host machine and the double data rate synchronous dynamic random access memory are obtained; wherein the initial video data of each current segment occupies one line respectively.
3. The method for processing video data according to claim 2, characterized in that: In the process of determining the first video data, adjacent rows of the block pixel size are row data respectively occupied by the initial video data of each current segment, and the initial video data of each current segment belongs to the same block pixel size; In the process of determining the second video data, the initial video data of each current segment occupies different rows of the same block pixel size.
4. The method for processing video data according to claim 1, characterized in that: When the initial video data of the current segment is acquired by the host machine or the double data rate synchronous dynamic random access memory, the first video data is determined according to a comparison relationship between the initial video data of the current segment and each video data of the stored adjacent rows and adjacent first preset segments of the corresponding block pixel size; Correspondingly, the second video data is determined according to a comparison relationship between the initial video data of the current segment and the stored adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment.
5. The method for processing video data according to claim 3, characterized in that: Determining the first video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment includes: Determining whether the initial video data of each current segment in adjacent rows in a vertical direction consisting of rows where the initial video data of each current segment is located are the same; If they are the same, determining that the initial video data of each current segment is the same, retaining one initial video data of the current segment, and recording the address information corresponding to the initial video data of each current segment; If they are different, then the video data of the adjacent i-th segment in each row in the horizontal direction are respectively subjected to difference processing with the initial video data of each current segment; wherein 1≤i≤N, N is a positive integer, and N is less than or equal to the first preset segment; If the difference after the difference processing is within the first preset range, the video data of the adjacent i-th segment in the respective rows in the horizontal direction are used as the first video data, the video data of the adjacent i-th segment or the initial video data of the current segment are retained, and the address information corresponding to the video data of the adjacent i-th segment and the initial video data of the current segment is recorded; If the difference value after the difference processing is not within the first preset range, it is determined that the first preset range of the difference value with the initial video data of the current segment is not satisfied.
6. The method for processing video data according to claim 3, characterized in that: Determining the first video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment includes: Determining whether the initial video data of each current segment in adjacent rows in a vertical direction consisting of rows where the initial video data of each current segment is located are the same; If they are the same, determining that the initial video data of each current segment is the same, retaining one initial video data of the current segment, and recording the address information corresponding to the initial video data of each current segment; If they are different, then the video data of the adjacent i-th segment in each row in the horizontal direction are respectively subjected to difference processing with the initial video data of each current segment; wherein 1≤i≤N, N is a positive integer, and N is less than or equal to the first preset segment; If the difference after the difference processing is within the first preset range, the video data of the adjacent i-th segment in the respective same line in the horizontal direction is used as the first video data, the video data of the adjacent i-th segment in the respective same line in the horizontal direction or the initial video data of the current segment is retained, and the address information corresponding to the video data of the adjacent i-th segment in the respective same line in the horizontal direction and the initial video data of the current segment is recorded; If the difference after the difference processing is not within the first preset range, it is determined that the video data of the i-th segment of the intersecting adjacent rows in the vertical direction are respectively subjected to difference processing with the initial video data of the respective current segments; If the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction are respectively subjected to difference processing with the initial video data of the respective current segments, and the difference values after the difference processing are within a first preset range, the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction are used as the first video data, the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction or the initial video data of the current segment are retained, and the address information corresponding to the video data of the i-th segment of the cross-adjacent i-th segment in the adjacent rows in the vertical direction and the initial video data of the current segment is recorded; If the video data of adjacent i-th segments in each row in the vertical direction are respectively subjected to difference processing with the initial video data of each current segment, and the difference values obtained after the difference processing are not within the first preset range, it is determined that the first preset range of the difference with the initial video data of the current segment is not satisfied.
7. The method for processing video data according to claim 5 or 6, characterized in that: The difference processing process includes: Performing difference processing on the pixel point data corresponding to the video data of the adjacent i-th segment and the initial video data of the current segment to obtain difference data corresponding to each pixel point data; The difference data corresponding to each pixel point data is summed up to obtain first summed data as the difference after the difference processing.
8. The method for processing video data according to claim 1, characterized in that: The segment length of the initial video data of the current segment is determined by the amount of compressed data in the compression mode of the video processing strategy.
9. The method for processing video data according to claim 1, characterized in that: The adjacent rows of the block pixel size are the current row and the previous row of data determined by dividing the row data within the block pixel size into every two rows.
10. The method for processing video data according to claim 1, characterized in that: The adjacent rows of the block pixel size are the number of rows of the row data within the block pixel size in the order of the current row and the previous row; wherein, except for the first row, each video data of each row is compared twice as an adjacent row.
11. The method for processing video data according to claim 5 or 6, characterized in that: The process of establishing the first information table includes: The video data of the adjacent i-th segment and the initial video data of the current segment are stored in the first information table in the form of binary data, and the video data of each field corresponds to preset bit width information; wherein the binary data corresponding to each video data records the segment position relationship between the first video data and the initial video data of the current segment.
12. The method for processing video data according to claim 3, characterized in that: Each row of data of different block pixel sizes of the second video data includes one segment of data; and the adjacent second preset segment is 0.
13. The method for processing video data according to claim 12, characterized in that: Determining the second video data according to a comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the video data of the adjacent second preset segment includes: Acquire video data of adjacent rows in the horizontal direction corresponding to the row where the initial video data of each current segment is located within the adjacent block pixel size; Comparing the video data of adjacent rows in each horizontal direction with the corresponding initial video data of each current segment; If the differences between the video data of the adjacent rows in the horizontal direction and the corresponding initial video data of the current segments are all less than or equal to the second preset range, determining the second video data; If the difference between the video data of the adjacent rows in the horizontal direction and the corresponding initial video data of the current segments is greater than the second preset range, then comparing the video data of the intersecting rows of the rows corresponding to the initial video data of the current segments within the adjacent block pixel size; If the differences between the video data of the intersecting rows corresponding to the rows where the initial video data of each current segment is located within the adjacent block pixel size are all less than or equal to the second preset range, determining the second video data; If the difference between the video data of the intersecting rows corresponding to the rows where the initial video data of each current segment is located within the adjacent block pixel size is greater than the second preset range, it is determined that the second preset range of the difference with the initial video data of the current segment is not met.
14. The method for processing video data according to claim 13, characterized in that: The process of determining the similarity result between the second video data and the initial video data of the current segment in the corresponding block pixel size to the adjacent block pixel size includes: Obtaining a comparison result of the video data within the pixel size of the corresponding block and the pixel size of the adjacent block; wherein the comparison result includes the second video data and video data within a second preset range that does not satisfy the difference with the initial video data of the current segment; Determining the proportion information occupied by the second video data in each comparison result; If the proportion information occupied by the second video data is greater than a preset proportion, it is determined that the pixel size of the corresponding block is similar to the video data within the pixel size of an adjacent block.
15. The method for processing video data according to claim 13, characterized in that: The process of determining the similarity result between the second video data and the initial video data of the current segment in the corresponding block pixel size to the adjacent block pixel size includes: Obtaining a comparison result of the video data within the pixel size of the corresponding block and the pixel size of the adjacent block; wherein the comparison result includes the second video data and video data within a second preset range that does not satisfy the difference with the initial video data of the current segment; Determining the proportion information occupied by the second video data in each comparison result; If the proportion information occupied by the second video data is greater than the preset proportion, and there are video data of adjacent rows in the horizontal direction whose difference does not satisfy the second preset range, performing difference processing on the video data of the adjacent rows in the horizontal direction that does not satisfy the second preset range and the pixel point data corresponding to the initial video data of the current segment to obtain difference data corresponding to each pixel point data; Adding the difference data corresponding to each pixel point data to obtain second added data; If the second summed data is greater than the first preset data, it is determined that the video data within the pixel size of the corresponding block is not similar to the video data within the pixel size of the adjacent block.
16. The method for processing video data according to claim 14 or 15, characterized in that: The similarity result between the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size is stored in the second information table, comprising: The similarity results corresponding to the pixel size of the block and the pixel size of the adjacent block are stored in the second information table in the form of binary data; wherein, if the similarity results corresponding to the pixel size of the block and the pixel size of the adjacent block are similar, only the video data corresponding to the pixel size of the block or the pixel size of the adjacent block is read.
17. The method for processing video data according to claim 1, characterized in that: The method further comprises: performing data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data, including: When the video processing strategy is a compression mode, the initial video data of the current segment is converted into a data format according to the first information table and the second information table to obtain processed video data; wherein, the compression mode is that the initial video data is subjected to color space conversion and video compression to obtain video data in a compressed format.
18. The method for processing video data according to claim 1, characterized in that: The method further comprises: performing data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data, including: When the video processing strategy is a pixel mode, the data format conversion processing is performed on the initial video data of the current segment according to the first information table to obtain processed video data; wherein, the pixel mode is the video data obtained by converting the initial video data through a color space.
19. A video data processing device, characterized in that: include: an acquisition module, configured to acquire initial video data of a current segment stored by a host machine and / or a double data rate synchronous dynamic random access memory; A first determination module is used to determine the first video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows of the corresponding block pixel size and the video data of the adjacent first preset segment; and store the address information of the first video data and the initial video data of the current segment in a first information table; wherein the first video data is video data that satisfies a first preset range of difference with the initial video data of the current segment; and a row of video data includes at least one segment of video data; A second determination module is used to determine the second video data according to the comparison relationship between the initial video data of the current segment and the adjacent rows within the adjacent block pixel size of the corresponding block pixel size and the adjacent second preset segment of the video data; and store the similarity results between the second video data and the initial video data of the current segment in the corresponding block pixel size and the adjacent block pixel size in the second information table; wherein the second video data is video data that satisfies the second preset range of the difference with the initial video data of the current segment; The data conversion module is used to perform data format conversion processing on the initial video data of the current segment according to the video processing strategy corresponding to the first information table and the second information table to obtain processed video data.
20. A video data processing device, characterized in that: include: Memory for storing computer programs; A processor, configured to implement the steps of the method for processing video data as claimed in any one of claims 1 to 18 when executing the computer program.
21. A non-volatile storage medium, characterized in that: The non-volatile storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for processing video data according to any one of claims 1 to 18 are implemented.
22. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instruction is executed by a processor, the steps of the method for processing video data according to any one of claims 1 to 18 are implemented.
Citation Information
Patent Citations
Video data processing method and storage equipment
CN101060624A
Method and apparatus for decoding image based on skip mode
CN102511163A
Video data displaying method, device and system
CN106454012A
Video compression processing method and device and medium
CN114051145A
Image compression system, method, equipment and medium
CN117156287A
Cited By
Video compression method and device, medium and product
CN119767007A
Synthetic video processing method and device, equipment, medium and product
CN119893012A
