CN113873255B - Video data transmission method, video data decoding method and related devices - Google Patents

Video data transmission method, video data decoding method and related devices Download PDF

Info

Publication number
CN113873255B
CN113873255B CN202111472327.5A CN202111472327A CN113873255B CN 113873255 B CN113873255 B CN 113873255B CN 202111472327 A CN202111472327 A CN 202111472327A CN 113873255 B CN113873255 B CN 113873255B
Authority
CN
China
Prior art keywords
data
transmitted
video
transmission
video data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111472327.5A
Other languages
Chinese (zh)
Other versions
CN113873255A (en
Inventor
张贞雷
李拓
满宏涛
刘同强
周玉龙
邹晓峰
王贤坤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202111472327.5A priority Critical patent/CN113873255B/en
Publication of CN113873255A publication Critical patent/CN113873255A/en
Application granted granted Critical
Publication of CN113873255B publication Critical patent/CN113873255B/en
Priority to PCT/CN2022/100477 priority patent/WO2023103336A1/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/42Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation
    • H04N19/423Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation characterised by memory arrangements
    • H04N19/426Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation characterised by memory arrangements using memory downsizing methods

Abstract

The application discloses a video data transmission method, which is applied to a substrate management control chip and comprises the following steps: respectively storing the video compression data to a first storage space and a second storage space according to a ping-pong operation structure; reading data with the same byte length from the first storage space and the second storage space; judging whether the similarity of the first data to be transmitted and the second data to be transmitted is greater than or equal to a preset value; if so, setting the first to-be-transmitted data added with the first transmission identifier as current frame data, and setting a second transmission identifier corresponding to the first transmission identifier as next frame data; and sending the current frame data and the next frame data to a video data receiving end. The method and the device can reduce the occupation of data transmission on the network bandwidth. The application also discloses a video data decoding method, a video data transmission device, a video data decoding device, an electronic device and a storage medium, which have the beneficial effects.

Description

Video data transmission method, video data decoding method and related devices
Technical Field
The present application relates to the field of data processing, and in particular, to a video data transmission method, a video data decoding method, and related apparatuses.
Background
The transmission flow of the video compression system in the traditional baseboard management control chip is as follows: firstly, the VGA transmits video information of a HOST HOST to a video compression control module for video compression, after the compression is completed, data is written into a DDR, an EMAC (network card) drive reads the compressed data, and the video data is transmitted to a remote place through a network for remote display.
However, the conventional scheme has the condition that video data is large and network bandwidth is occupied. An important function of the baseboard management chip is to implement remote monitoring management, and in an application scenario, besides the video compression function, many other functions also occupy network bandwidth, such as performing firmware update remotely (firmware files are transmitted to the local through a network) or reading/setting local server state information. If the network bandwidth occupied by the video function is large, other functions of the substrate management control chip are greatly influenced, the performance of the substrate management control chip is influenced to a certain extent or a great extent, and especially, the local server meets the condition of needing emergency treatment and even causes the safety risk of the local server.
Therefore, how to reduce the occupation of network bandwidth by data transmission is a technical problem that needs to be solved by those skilled in the art at present.
Disclosure of Invention
An object of the present application is to provide a video data transmission method, a video data decoding method, a video data transmission apparatus, a video data decoding apparatus, an electronic device, and a storage medium, which can reduce the occupation of network bandwidth by data transmission.
In order to solve the above technical problem, the present application provides a video data transmission method, which is applied to a baseboard management control chip, and the video data transmission method includes:
compressing video data sent by a host end to obtain video compressed data, and respectively storing the video compressed data to a first storage space and a second storage space according to a ping-pong operation structure;
if a data transmission instruction is received, reading first to-be-transmitted data with a preset byte length from the first storage space, and reading second to-be-transmitted data with the preset byte length from the second storage space;
judging whether the similarity of the first data to be transmitted and the second data to be transmitted is greater than or equal to a preset value;
if so, setting the first to-be-transmitted data added with the first transmission identifier as current frame data, and setting a second transmission identifier corresponding to the first transmission identifier as next frame data;
and sending the current frame data and the next frame data to a video data receiving end.
Optionally, after determining whether the similarity between the first to-be-transmitted data and the second to-be-transmitted data is greater than a preset value, the method further includes:
and if the similarity between the first data to be transmitted and the second data to be transmitted is smaller than the preset value, setting the first data to be transmitted as the current frame data, and setting the second data to be transmitted as the next frame data.
Optionally, before setting the first to-be-transmitted data added with the first transmission identifier as current frame data, the method further includes:
generating a first transmission identifier corresponding to the first data to be transmitted; wherein the First transmission identifier comprises an identification field Flag, a frame type field First _ frame, a start position field Begin _ cnt, and a repeated data length field pixel _ num; the frame type field First _ frame of the First transport identifier has a value of 1.
Optionally, setting the first to-be-transmitted data added with the first transmission identifier as current frame data includes:
and adding the first transmission identifier before the first data to be transmitted to obtain the current frame data.
Optionally, before setting the second transmission identifier corresponding to the first transmission identifier as the next frame of data, the method further includes:
generating a second transmission identifier corresponding to the first transmission identifier; wherein the second transmission identifier comprises an identification field Flag, a frame type field First _ frame, a start position field Begin _ cnt, and a repeated data length field pixel _ num; the value of the frame type field First _ frame of the second transmission identifier is 0, and the values of the identification field Flag, the start position field Begin _ cnt and the repeated data length field pixel _ num in the second transmission identifier are all the same as the First transmission identifier.
The application also provides a video data decoding method, which is applied to a video data receiving end, and the video data decoding method comprises the following steps:
receiving current frame data and next frame data transmitted by a base plate management control chip through the video data transmission method;
judging whether the current frame data comprises a first transmission identifier or not; if so, decoding first data to be transmitted in the current frame data to obtain a first decoding result, and adding the first decoding result to a cache;
judging whether the next frame data comprises a second transmission identifier or not; if so, reading the first decoding result from the cache as a second decoding result corresponding to the next frame data;
and generating video data to be displayed according to the first decoding result and the second decoding result.
The application also provides a video data transmission device, is applied to the base plate management control chip, video data transmission device includes:
the data storage module is used for compressing video data sent by the host end to obtain video compressed data and respectively storing the video compressed data to a first storage space and a second storage space according to a ping-pong operation structure;
the data reading module is used for reading first to-be-transmitted data with a preset byte length from the first storage space and reading second to-be-transmitted data with the preset byte length from the second storage space if a data transmission instruction is received;
the similarity judging module is used for judging whether the similarity of the first data to be transmitted and the second data to be transmitted is greater than or equal to a preset value;
the data setting module is used for setting the first data to be transmitted added with a first transmission identifier as current frame data and setting a second transmission identifier corresponding to the first transmission identifier as next frame data if the similarity between the first data to be transmitted and the second data to be transmitted is greater than or equal to the preset value;
and the data transmission module is used for transmitting the current frame data and the next frame data to a video data receiving end.
The present application further provides a video data decoding apparatus applied to a video data receiving end, the video data decoding apparatus includes:
the data receiving module is used for receiving the current frame data and the next frame data transmitted by the baseboard management control chip through the video data transmission method;
the first judging module is used for judging whether the current frame data comprises a first transmission identifier or not; if so, decoding first data to be transmitted in the current frame data to obtain a first decoding result, and adding the first decoding result to a cache;
the second judging module is used for judging whether the next frame data comprises a second transmission identifier or not; if so, reading the first decoding result from the cache as a second decoding result corresponding to the next frame data;
and the display module is used for generating video data to be displayed according to the first decoding result and the second decoding result.
The present application further provides a storage medium having stored thereon a computer program which, when executed, implements the steps of the above-described video data transmission method and/or the above-described video data decoding method.
The application also provides an electronic device, which comprises a memory and a processor, wherein the memory stores a computer program, and the processor realizes the steps of the video data transmission method and/or the video data decoding method when calling the computer program in the memory.
The application provides a video data transmission method, which is applied to a substrate management control chip and comprises the following steps: compressing video data sent by a host end to obtain video compressed data, and respectively storing the video compressed data to a first storage space and a second storage space according to a ping-pong operation structure; if a data transmission instruction is received, reading first to-be-transmitted data with a preset byte length from the first storage space, and reading second to-be-transmitted data with the preset byte length from the second storage space; judging whether the similarity of the first data to be transmitted and the second data to be transmitted is greater than or equal to a preset value; if so, setting the first to-be-transmitted data added with the first transmission identifier as current frame data, and setting a second transmission identifier corresponding to the first transmission identifier as next frame data; and sending the current frame data and the next frame data to a video data receiving end.
According to the method and the device, the video compression data are respectively stored into the first storage space and the second storage space according to the structure of ping-pong operation, when the video compression data are required to be transmitted to a data receiving end, the first data to be transmitted with the preset byte length are read from the first storage space, and the second data to be transmitted with the preset byte length are read from the second storage space. If the similarity between the first to-be-transmitted data and the second to-be-transmitted data is greater than or equal to a preset value, the two data are considered to be data with the same content, at this time, the first to-be-transmitted data added with the first transmission identifier is set as current frame data, the second transmission identifier corresponding to the first transmission identifier is set as next frame data, and then the current frame data and the next frame data are sent to a video data receiving end. By the method, the same data can be prevented from being repeatedly transmitted, and the occupation of data transmission on network bandwidth is reduced. The present application also provides a video data decoding method, a video data transmission device, a video data decoding device, an electronic device, and a storage medium, which have the above beneficial effects and are not described herein again.
Drawings
In order to more clearly illustrate the embodiments of the present application, the drawings needed for the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings can be obtained by those skilled in the art without inventive effort.
Fig. 1 is a flowchart of a video data transmission method according to an embodiment of the present application;
fig. 2 is a flowchart of a video data decoding method according to an embodiment of the present application;
fig. 3 is a diagram illustrating a transmission scheme of compressed video data in a conventional scheme;
FIG. 4 is a schematic diagram of a compressed video data transmission scheme according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a video data transmission apparatus according to an embodiment of the present application;
fig. 6 is a schematic structural diagram of a video data decoding apparatus according to an embodiment of the present disclosure.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Referring to fig. 1, fig. 1 is a flowchart of a video data transmission method according to an embodiment of the present disclosure.
The specific steps may include:
s101: compressing video data sent by a host end to obtain video compressed data, and respectively storing the video compressed data to a first storage space and a second storage space according to a ping-pong operation structure;
the present embodiment can be applied to a baseboard management control chip, the baseboard management control system generally refers to a system for monitoring the state (temperature, fan, main CPU operating condition, etc.) of a server in the field of servers, and the baseboard management control chip can also transmit local video information to a remote end through a network for remote display and monitoring.
After receiving the video compression data sent by the host, the video compression module can be used for compressing the video data to obtain the video compression data. After the video compression data value is obtained, the video compression data value can be written into two areas of a and B in the DDR respectively according to the structure of ping-pong operation by taking a frame as a unit, namely a 0 th frame writing address a, a 1 st frame writing address B, a 2 nd frame writing address a, and a 3 rd frame writing address B … …. The first storage space can store the video compression data of the odd frames and the second storage space can store the video compression data of the even frames. When comparing adjacent frame data, the present embodiment may compare the nth frame with the (N + 1) th frame, compare the (N + 2) th frame with the (N + 3) th frame, compare the (N + 4) th frame with the (N + 5) th frame, … …, and so on. After the comparison of the adjacent frame data, the next frame data (after the modification by adding the identifier) may be temporarily stored, and then the current frame data is preferentially transmitted and the next frame data is transmitted. For example, when comparing the 0 th frame and the 1 st frame, the 0 th frame and the 1 st frame are read back from the DDR, but the 0 th frame is preferentially transmitted, and then the 1 st frame is transmitted, so that the 1 st frame (after the identifier modification is added) needs to be temporarily stored.
S102: if a data transmission instruction is received, reading first to-be-transmitted data with a preset byte length from the first storage space, and reading second to-be-transmitted data with the preset byte length from the second storage space;
after the data transmission instruction is obtained, the first data to be transmitted and the second data to be transmitted with the same length can be read from the first storage space and the second storage space respectively. As a possible implementation manner, the present embodiment may count the network bandwidth in real time, and determine the read data length according to the network bandwidth, that is: and determining the preset byte length according to the network bandwidth, wherein the size of the network bandwidth is positively correlated with the preset byte length.
S103: judging whether the similarity of the first data to be transmitted and the second data to be transmitted is greater than or equal to a preset value; if yes, entering S104; if not, the flow is ended.
In this embodiment, the video compressed data is respectively stored in the first storage space and the second storage space according to a ping-pong operation structure, so that the first data to be transmitted and the second data to be transmitted are video data of adjacent frames, and if the similarity between the first data to be transmitted and the second data to be transmitted is high, it can be determined that image contents corresponding to the first data to be transmitted and the second data to be transmitted are the same contents. If yes, the relevant operation of S104 can be entered; if not, the operation flow of this embodiment may be ended, and the first data to be transmitted may also be set as current frame data, the second data to be transmitted may also be set as next frame data, and then the current frame data and the next frame data are sent to the video data receiving end. Therefore, after judging whether the similarity between the first data to be transmitted and the second data to be transmitted is greater than a preset value, if the similarity between the first data to be transmitted and the second data to be transmitted is less than the preset value, the first data to be transmitted is set as the current frame data, and the second data to be transmitted is set as the next frame data.
Specifically, the embodiment may generate a first transmission identifier corresponding to the first to-be-transmitted data; wherein the First transmission identifier comprises an identification field Flag, a frame type field First _ frame, a start position field Begin _ cnt, and a repeated data length field pixel _ num; the frame type field First _ frame of the First transport identifier has a value of 1. The embodiment may further generate a second transmission identifier corresponding to the first transmission identifier; wherein the second transmission identifier comprises an identification field Flag, a frame type field First _ frame, a start position field Begin _ cnt, and a repeated data length field pixel _ num; the value of the frame type field First _ frame of the second transmission identifier is 0, and the values of the identification field Flag, the start position field Begin _ cnt and the repeated data length field pixel _ num in the second transmission identifier are all the same as the First transmission identifier.
S104: setting the first to-be-transmitted data added with a first transmission identifier as current frame data, and setting a second transmission identifier corresponding to the first transmission identifier as next frame data;
as a possible implementation manner, the present embodiment may add the first transmission identifier before the first to-be-transmitted data to obtain the current frame data.
S105: and sending the current frame data and the next frame data to a video data receiving end.
In this embodiment, the video compressed data is respectively stored in a first storage space and a second storage space according to a ping-pong operation structure, and when the video compressed data needs to be transmitted to a data receiving end, first to-be-transmitted data with a preset byte length is read from the first storage space, and second to-be-transmitted data with the preset byte length is read from the second storage space. If the similarity between the first to-be-transmitted data and the second to-be-transmitted data is greater than or equal to a preset value, the two data are considered to be data with the same content, at this time, the first to-be-transmitted data added with the first transmission identifier is set as current frame data, the second transmission identifier corresponding to the first transmission identifier is set as next frame data, and then the current frame data and the next frame data are sent to a video data receiving end. By the method, the same data can be prevented from being repeatedly transmitted, and the occupation of data transmission on network bandwidth is reduced.
Referring to fig. 2, fig. 2 is a flowchart illustrating a video data decoding method according to an embodiment of the present disclosure.
The specific steps may include:
s201: receiving current frame data and next frame data transmitted by a substrate management control chip;
the present embodiment may be applied to a video data receiving end, and the current frame data and the next frame data may be data transmitted according to the video data transmission method described in the embodiment corresponding to fig. 1
S202: judging whether the current frame data comprises a first transmission identifier or not; if so, decoding first data to be transmitted in the current frame data to obtain a first decoding result, and adding the first decoding result to a cache;
further, if the current frame data does not include the first transmission identifier, the current frame data and the next frame data may be directly decoded to obtain a first decoding result and a second decoding result.
S203: judging whether the next frame data comprises a second transmission identifier or not; if so, reading the first decoding result from the cache as a second decoding result corresponding to the next frame data;
further, if the next frame data does not include the second transmission identifier, the next frame data may be decoded to obtain a second decoding result.
S204: and generating video data to be displayed according to the first decoding result and the second decoding result.
In this embodiment, the current frame data and the next frame data transmitted in the embodiment corresponding to fig. 1 are received, if the current frame data includes a first transmission identifier, it is indicated that the current frame data is a first frame of repeated data, and if the next frame data includes a second transmission identifier, it is indicated that the next frame data is repeated data of the current frame data, at this time, the first decoding result may be read from the cache as a second decoding result corresponding to the next frame data, and then the video data to be displayed is generated according to the first decoding result and the second decoding result. By the method, the repeated transmission of the same data can be avoided, the occupation of the data transmission on the network bandwidth is reduced, and the calculated amount of the decoded data can be reduced.
The flow described in the above embodiment is explained below by an embodiment in practical use.
Referring to fig. 3, fig. 3 is a schematic diagram of a transmission scheme of compressed video data in a conventional scheme, where a transmission flow of compressed video provided by this embodiment includes: the video information of the HOST HOST is transmitted to a video compression control module (CMP, compression) of the baseboard management control chip; the video compression control module compresses original video data and writes the compressed data to the DDR. And the network driver initiates a command for reading the compressed video data and performs network packaging on the read data. And the network card EMAC converts the network packet containing the video data into an Ethernet frame format and sends the Ethernet frame format to the port physical layer PHY. The port physical layer PHY delivers video data to the far end through the network wire/network.
In the above-mentioned conventional scheme, there are the following drawbacks: video data of a host display card is generated continuously, video information with huge data volume occupies a large network bandwidth when being sent through a network, an important function of a substrate management chip is to realize remote monitoring management, and in an application scene, besides the video compression function, many other functions also occupy the network bandwidth, such as remote firmware update (firmware files are transmitted to the local through the network) or reading/setting local server state information and the like. If the network bandwidth occupied by the video function is large, other functions of the substrate management control chip are greatly influenced, the performance of the substrate management control chip is influenced to a certain extent or a great extent, especially if the local server meets the condition of needing emergency treatment, the safety risk of the local server is even caused, and if the SoC system needs to run more important application programs (needing quick response), the system cannot meet the requirement. SoC (System on Chip, SoC for short) is a System on Chip, in which a microprocessor, an analog IP core, a digital IP core and a memory (or an off-Chip memory control interface) are integrated on a single Chip, and the SoC is usually customized by a customer or a standard product oriented to a specific purpose.
In view of the above-mentioned drawbacks in the conventional schemes, the present application provides a new scheme for reducing network bandwidth in a baseboard management control chip. The scheme is optimized on the basis of the traditional scheme, a video compression module adopts ping-pong operation when writing compressed data, writes in two DDR address spaces of an A/B (double data rate), modifies an EMAC (electronic component assembly) drive, sequentially and respectively reads two areas of the A/B, a COMP (COMP) comparison unit is added in the EMAC, compares the consistency of the video data of the front frame and the rear frame on the length of the current descriptor, modifies the corresponding data into a flag bit if the data of the rear frame under the current descriptor is the same as the data of the front frame, and then analyzes the corresponding flag bit information when the far-end video is decoded. In a real application scene, the change of two frames before and after is very small or not changed, or the probability that the change is only locally generated is very large, so the scheme can greatly reduce the video data volume transmitted by a network.
Referring to fig. 4, fig. 4 is a schematic diagram of a compressed video data transmission scheme according to an embodiment of the present application, and an implementation flow of the scheme is as follows:
step 1: the host end transmits the video information to a video compression control module CMP of a substrate management control chip;
the original image information output by the local video card needs to be compressed by the video compression control module CMP before being transmitted to the remote end through the network, so as to reduce the video data volume and the network bandwidth.
Step 2: after the video compression module CMP completes the video compression, the video is written into two areas a and B in the DDR respectively according to the structure of ping-pong operation, that is, the 0 th frame write address a, the 1 st frame write address B, the 2 nd frame write address a, and the 3 rd frame write address B … …, in units of frames.
And step 3: the network driver running on the CPU sequentially initiates operations of reading the a and B addresses, and it should be noted that, in each initiated operation, the read data length needs to be uniform, for example, 256 bytes/1024 bytes are read. Meanwhile, the data length can be adjusted by a user according to the real-time statistical network bandwidth, so that the network bandwidth occupied by the video data is reduced to the maximum extent.
And 4, step 4: and a COMP (compare unit) newly added in the network card EMAC, which is used for comparing the compressed video data read back by the network driver, and if the compressed video data are consistent, modifying the corresponding data in the next frame into an identifier form, wherein the identifier form is { Flag, Fisrt _ frame, Begin _ cnt, pixel _ num }, wherein Flag is an identifier, can be referred to as 32' hfffffff, and Fisrt _ frame is set to 0, and indicates that the current data is the next frame and needs to be supplemented at a decoding end. Begin _ cnt, which indicates the starting position of the current data segment in the frame, and pixel _ num, which indicates the length of the repeated data.
Further modification of the current frame requires the addition of Flag, Fisrt _ frame, Begin _ cnt, pixel _ num, before the data end repeated with the next frame, where the referenceable setting is 32' hfffffff, and the Fisrt _ frame is set to 1, which indicates that the current data is the current frame and needs to be buffered at the decoding end (for the complement data of the next frame). Begin _ cnt, which indicates the starting position of the current data segment in the frame, and pixel _ num, which indicates the length of the repeated data. As can be seen from the above discussion, the current frame requires the transmission of the identifier + the repeated data side, while the latter frame requires only the transmission of the identifier.
And 5: the network card EMAC respectively sends the two frames of data after passing through the COMP module to the far end, the decoding program of the far end also needs to be modified correspondingly, after detecting Flag = 32' hfffffff, the Fisrt _ frame is detected, and if the Fisrt _ frame =1, the data of pixel _ num quantity started from Begin _ cnt needs to be cached. Meanwhile, after detecting Flag = 32' hfffffff, if the Fisrt _ frame is detected again, and if the Fisrt _ frame =0, the data of pixel _ num number is directly and sequentially fetched from the cache to complete the current frame.
The embodiment is optimized on the basis of a traditional scheme, a video compression module adopts ping-pong operation when writing compressed data, writes in two DDR address spaces of an A/B, modifies an EMAC drive, sequentially and respectively reads two areas of the A/B, a COMP comparison unit is added in the EMAC, the consistency of the video data of the front frame and the rear frame on the length of a current descriptor is compared, if the data of the rear frame under the current descriptor is the same as the data of the front frame, the corresponding data is modified into a marker, the current frame data is modified correspondingly (the identifier is added), and then the corresponding marker bit information is analyzed when the far-end video is decoded, so that the completion operation of the data is carried out. In a real application scene, the change of two frames before and after is very small or not changed, or the probability that the change is only locally generated is very large, so the scheme can greatly reduce the video data volume transmitted by a network.
In the embodiment, a COMP comparison function is added in the network card EMAC, the data consistency of the two frames of data in the same area before and after the data are compared, if the data are consistent, the area corresponding to the next frame only transmits the identifier, the current frame data transmits the identifier plus normal data, and the data completion of the next frame is carried out at a decoding end, so that the video data volume transmitted by a network is greatly reduced, the network bandwidth is reduced, and the system performance is improved. In the embodiment, the network driver can detect the network bandwidth in real time, and dynamically adjust the data length of the DDR read by the network driver, so that the optimal data length can be achieved. In the embodiment, the ping-pong structure is adopted to store and compress the video data, only part of the traditional scheme is modified, the implementation is not complex, but the video data amount in the baseboard management control chip can be greatly reduced, and the network bandwidth is reduced.
Referring to fig. 5, fig. 5 is a schematic structural diagram of a video data transmission device according to an embodiment of the present application, where the video data transmission device is applied to a baseboard management control chip, and the video data transmission device includes:
the data storage module 501 is configured to compress video data sent by a host to obtain video compressed data, and store the video compressed data in a first storage space and a second storage space according to a ping-pong operation structure;
a data reading module 502, configured to read a first to-be-transmitted data with a preset byte length from the first storage space and read a second to-be-transmitted data with the preset byte length from the second storage space if a data transmission instruction is received;
a similarity determination module 503, configured to determine whether a similarity between the first to-be-transmitted data and the second to-be-transmitted data is greater than or equal to a preset value;
a data setting module 504, configured to set, as current frame data, the first to-be-transmitted data to which a first transmission identifier is added, and set, as next frame data, a second transmission identifier corresponding to the first transmission identifier, if the similarity between the first to-be-transmitted data and the second to-be-transmitted data is greater than or equal to the preset value;
and a data transmission module 505, configured to send the current frame data and the next frame data to a video data receiving end.
In this embodiment, the video compressed data is respectively stored in a first storage space and a second storage space according to a ping-pong operation structure, and when the video compressed data needs to be transmitted to a data receiving end, first to-be-transmitted data with a preset byte length is read from the first storage space, and second to-be-transmitted data with the preset byte length is read from the second storage space. If the similarity between the first to-be-transmitted data and the second to-be-transmitted data is greater than or equal to a preset value, the two data are considered to be data with the same content, at this time, the first to-be-transmitted data added with the first transmission identifier is set as current frame data, the second transmission identifier corresponding to the first transmission identifier is set as next frame data, and then the current frame data and the next frame data are sent to a video data receiving end. By the method, the same data can be prevented from being repeatedly transmitted, and the occupation of data transmission on network bandwidth is reduced.
Further, the method also comprises the following steps:
and the data setting module is used for setting the first data to be transmitted as the current frame data and the second data to be transmitted as the next frame data if the similarity between the first data to be transmitted and the second data to be transmitted is smaller than a preset value after judging whether the similarity between the first data to be transmitted and the second data to be transmitted is larger than the preset value.
Further, the method also comprises the following steps:
a first identifier generating module, configured to generate a first transmission identifier corresponding to the first data to be transmitted, before the first data to be transmitted, to which the first transmission identifier is added, is set as current frame data; wherein the First transmission identifier comprises an identification field Flag, a frame type field First _ frame, a start position field Begin _ cnt, and a repeated data length field pixel _ num; the frame type field First _ frame of the First transport identifier has a value of 1.
Further, the data setting module 504 is configured to add the first transmission identifier before the first data to be transmitted, so as to obtain the current frame data.
Further, the method also comprises the following steps:
a second identifier generation module, configured to generate a second transmission identifier corresponding to the first transmission identifier before setting the second transmission identifier corresponding to the first transmission identifier as subsequent frame data; wherein the second transmission identifier comprises an identification field Flag, a frame type field First _ frame, a start position field Begin _ cnt, and a repeated data length field pixel _ num; the value of the frame type field First _ frame of the second transmission identifier is 0, and the values of the identification field Flag, the start position field Begin _ cnt and the repeated data length field pixel _ num in the second transmission identifier are all the same as the First transmission identifier.
Referring to fig. 6, fig. 6 is a schematic structural diagram of a video data decoding apparatus according to an embodiment of the present application, the apparatus is applied to a video data receiving end, and the video data decoding apparatus includes:
a data receiving module 601, configured to receive current frame data and next frame data transmitted by the bmc chip according to the video data transmission method of any one of claims 1 to 5;
a first determining module 602, configured to determine whether the current frame data includes a first transmission identifier; if so, decoding first data to be transmitted in the current frame data to obtain a first decoding result, and adding the first decoding result to a cache;
a second determining module 603, configured to determine whether the next frame data includes a second transmission identifier; if so, reading the first decoding result from the cache as a second decoding result corresponding to the next frame data;
a display module 604, configured to generate video data to be displayed according to the first decoding result and the second decoding result.
In this embodiment, the current frame data and the next frame data transmitted in the embodiment corresponding to fig. 1 are received, if the current frame data includes a first transmission identifier, it is indicated that the current frame data is a first frame of repeated data, and if the next frame data includes a second transmission identifier, it is indicated that the next frame data is repeated data of the current frame data, at this time, the first decoding result may be read from the cache as a second decoding result corresponding to the next frame data, and then the video data to be displayed is generated according to the first decoding result and the second decoding result. By the method, the repeated transmission of the same data can be avoided, the occupation of the data transmission on the network bandwidth is reduced, and the calculated amount of the decoded data can be reduced.
Since the embodiments of the apparatus portion and the method portion correspond to each other, please refer to the description of the embodiments of the method portion for the embodiments of the apparatus portion, which is not repeated here.
The present application further provides a storage medium having a computer program stored thereon, which when executed, can implement the steps provided by the above-mentioned video data transmission method and/or the above-mentioned video data decoding method. The storage medium may include: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The present application further provides an electronic device, which may include a memory and a processor, where the memory stores a computer program, and when the processor calls the computer program in the memory, the electronic device may implement the steps provided by the above video data transmission method and/or the above video data decoding method. Of course, the electronic device may also include various network interfaces, power supplies, and the like.
The embodiments are described in a progressive manner in the specification, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description. It should be noted that, for those skilled in the art, it is possible to make several improvements and modifications to the present application without departing from the principle of the present application, and such improvements and modifications also fall within the scope of the claims of the present application.
It is further noted that, in the present specification, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.

Claims (10)

1. A video data transmission method is applied to a baseboard management control chip and comprises the following steps:
compressing video data sent by a host end to obtain video compressed data, and respectively storing the video compressed data to a first storage space and a second storage space according to a ping-pong operation structure;
if a data transmission instruction is received, reading first to-be-transmitted data with a preset byte length from the first storage space, and reading second to-be-transmitted data with the preset byte length from the second storage space;
judging whether the similarity of the first data to be transmitted and the second data to be transmitted is greater than or equal to a preset value;
if so, setting the first to-be-transmitted data added with the first transmission identifier as current frame data, and setting a second transmission identifier corresponding to the first transmission identifier as next frame data;
and sending the current frame data and the next frame data to a video data receiving end.
2. The video data transmission method according to claim 1, wherein after determining whether the similarity between the first to-be-transmitted data and the second to-be-transmitted data is greater than a preset value, the method further comprises:
and if the similarity between the first data to be transmitted and the second data to be transmitted is smaller than the preset value, setting the first data to be transmitted as the current frame data, and setting the second data to be transmitted as the next frame data.
3. The video data transmission method according to claim 1, wherein before said setting of said first data to be transmitted added with a first transmission identifier as current frame data, further comprising:
generating a first transmission identifier corresponding to the first data to be transmitted; wherein the First transmission identifier comprises an identification field Flag, a frame type field First _ frame, a start position field Begin _ cnt, and a repeated data length field pixel _ num; the frame type field First _ frame of the First transport identifier has a value of 1.
4. The video data transmission method according to claim 1, wherein the setting of the first data to be transmitted with the first transmission identifier added thereto as current frame data includes:
and adding the first transmission identifier before the first data to be transmitted to obtain the current frame data.
5. The video data transmission method according to claim 1, further comprising, before setting the second transmission identifier corresponding to the first transmission identifier as the subsequent frame data:
generating a second transmission identifier corresponding to the first transmission identifier; wherein the second transmission identifier comprises an identification field Flag, a frame type field First _ frame, a start position field Begin _ cnt, and a repeated data length field pixel _ num; the value of the frame type field First _ frame of the second transmission identifier is 0, and the values of the identification field Flag, the start position field Begin _ cnt and the repeated data length field pixel _ num in the second transmission identifier are all the same as the First transmission identifier.
6. A video data decoding method applied to a video data receiving end, the video data decoding method comprising:
receiving current frame data and next frame data transmitted by a baseboard management control chip through the video data transmission method of any one of claims 1 to 5;
judging whether the current frame data comprises a first transmission identifier or not; if so, decoding first data to be transmitted in the current frame data to obtain a first decoding result, and adding the first decoding result to a cache;
judging whether the next frame data comprises a second transmission identifier or not; if so, reading the first decoding result from the cache as a second decoding result corresponding to the next frame data;
and generating video data to be displayed according to the first decoding result and the second decoding result.
7. A video data transmission device is applied to a baseboard management control chip, and comprises:
the data storage module is used for compressing video data sent by the host end to obtain video compressed data and respectively storing the video compressed data to a first storage space and a second storage space according to a ping-pong operation structure;
the data reading module is used for reading first to-be-transmitted data with a preset byte length from the first storage space and reading second to-be-transmitted data with the preset byte length from the second storage space if a data transmission instruction is received;
the similarity judging module is used for judging whether the similarity of the first data to be transmitted and the second data to be transmitted is greater than or equal to a preset value;
the data setting module is used for setting the first data to be transmitted added with a first transmission identifier as current frame data and setting a second transmission identifier corresponding to the first transmission identifier as next frame data if the similarity between the first data to be transmitted and the second data to be transmitted is greater than or equal to the preset value;
and the data transmission module is used for transmitting the current frame data and the next frame data to a video data receiving end.
8. A video data decoding apparatus applied to a video data receiving end, the video data decoding apparatus comprising:
a data receiving module, configured to receive current frame data and next frame data transmitted by the baseboard management control chip according to the video data transmission method of any one of claims 1 to 5;
the first judging module is used for judging whether the current frame data comprises a first transmission identifier or not; if so, decoding first data to be transmitted in the current frame data to obtain a first decoding result, and adding the first decoding result to a cache;
the second judging module is used for judging whether the next frame data comprises a second transmission identifier or not; if so, reading the first decoding result from the cache as a second decoding result corresponding to the next frame data;
and the display module is used for generating video data to be displayed according to the first decoding result and the second decoding result.
9. An electronic device, comprising a memory in which a computer program is stored and a processor, wherein the processor implements the steps of the video data transmission method according to any one of claims 1 to 5 and/or the video data decoding method according to claim 6 when calling the computer program in the memory.
10. A storage medium having stored thereon computer-executable instructions which, when loaded and executed by a processor, carry out the steps of a video data transmission method according to any one of claims 1 to 5 and/or a video data decoding method according to claim 6.
CN202111472327.5A 2021-12-06 2021-12-06 Video data transmission method, video data decoding method and related devices Active CN113873255B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202111472327.5A CN113873255B (en) 2021-12-06 2021-12-06 Video data transmission method, video data decoding method and related devices
PCT/CN2022/100477 WO2023103336A1 (en) 2021-12-06 2022-06-22 Video data transmission method, video data decoding method, and related apparatuses

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111472327.5A CN113873255B (en) 2021-12-06 2021-12-06 Video data transmission method, video data decoding method and related devices

Publications (2)

Publication Number Publication Date
CN113873255A CN113873255A (en) 2021-12-31
CN113873255B true CN113873255B (en) 2022-02-18

Family

ID=78985897

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111472327.5A Active CN113873255B (en) 2021-12-06 2021-12-06 Video data transmission method, video data decoding method and related devices

Country Status (2)

Country Link
CN (1) CN113873255B (en)
WO (1) WO2023103336A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113873255B (en) * 2021-12-06 2022-02-18 苏州浪潮智能科技有限公司 Video data transmission method, video data decoding method and related devices
CN114051145B (en) * 2022-01-11 2022-04-22 苏州浪潮智能科技有限公司 Video compression processing method, device and medium
CN115209145A (en) * 2022-09-15 2022-10-18 苏州浪潮智能科技有限公司 Video compression method, system, device and readable storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101127819A (en) * 2007-10-12 2008-02-20 杭州华三通信技术有限公司 A method and device for image transmission
CN102810294A (en) * 2012-08-01 2012-12-05 京东方科技集团股份有限公司 Displaying method, displaying device and displaying system
CN107835424A (en) * 2017-12-18 2018-03-23 合肥亚慕信息科技有限公司 A kind of media sync transmission player method based on data perception
CN113709490A (en) * 2021-07-30 2021-11-26 山东云海国创云计算装备产业创新中心有限公司 Video compression method, device, system and medium

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5174641A (en) * 1990-07-25 1992-12-29 Massachusetts Institute Of Technology Video encoding method for television applications
TW201134224A (en) * 2009-10-15 2011-10-01 Omnivision Tech Inc Low-cost video encoder
CN202206502U (en) * 2011-09-23 2012-04-25 湖南城市学院 Door access video signal transmitting device
CN102946529B (en) * 2012-10-19 2016-03-02 华中科技大学 Based on image transmitting and the treatment system of FPGA and multi-core DSP
JP2018192002A (en) * 2017-05-17 2018-12-06 オリンパス株式会社 Endoscope apparatus and imaging method
CN110532219B (en) * 2019-06-25 2021-04-27 北京理工大学 FPGA-based ping-pong data storage removing method
CN113873255B (en) * 2021-12-06 2022-02-18 苏州浪潮智能科技有限公司 Video data transmission method, video data decoding method and related devices

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101127819A (en) * 2007-10-12 2008-02-20 杭州华三通信技术有限公司 A method and device for image transmission
CN102810294A (en) * 2012-08-01 2012-12-05 京东方科技集团股份有限公司 Displaying method, displaying device and displaying system
CN107835424A (en) * 2017-12-18 2018-03-23 合肥亚慕信息科技有限公司 A kind of media sync transmission player method based on data perception
CN113709490A (en) * 2021-07-30 2021-11-26 山东云海国创云计算装备产业创新中心有限公司 Video compression method, device, system and medium

Also Published As

Publication number Publication date
WO2023103336A1 (en) 2023-06-15
CN113873255A (en) 2021-12-31

Similar Documents

Publication Publication Date Title
CN113873255B (en) Video data transmission method, video data decoding method and related devices
JP6316974B2 (en) Flash memory compression
CN109756230B (en) Data compression storage method, data compression method, device, equipment and medium
US20210318836A1 (en) Data compression method and apparatus
CN109753207B (en) Information processing method and device and storage medium
US20180300250A1 (en) Method and apparatus for storing data
CN114051145B (en) Video compression processing method, device and medium
CN108377394B (en) Image data reading method of video encoder, computer device and computer-readable storage medium
CN109889894A (en) Media file coding/decoding method, device and storage medium
WO2017132797A1 (en) Data arrangement method, storage apparatus, storage controller and storage array
CN114466196B (en) Video data processing method, system, device and computer readable storage medium
CN113573072B (en) Image processing method and device and related components
US20240104780A1 (en) Image compression method and apparatus, and intelligent terminal and computer-readable storage medium
US10489350B2 (en) Data compression with inline compression metadata
WO2023083213A1 (en) Data decoding method and apparatus, electronic device and readable storage medium
CN113704206B (en) Metadata processing method and device, electronic equipment and storage medium
CN114422807B (en) Transmission optimization method based on Spice protocol
CN115033544A (en) Data compression method, device, equipment and medium based on relation numerical value
US7903119B2 (en) Compression of image regions according to graphics command type
CN113641643A (en) File writing method and device
CN115633181B (en) Picture processing method, system, device, image compression device and storage medium
CN108989813A (en) A kind of high efficiency of compression/decompression method, computer installation and storage medium
CN113596506B (en) Performance optimization method and system for live cache, electronic device and storage medium
US20220083267A1 (en) High Bandwidth Controller Memory Buffer For Peer To Peer Data Transfer
WO2023201784A1 (en) Method, apparatus and system for transmitting composite photograph data, and electronic device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant