CN109151584B - Method and device for controlling network flow - Google Patents

Method and device for controlling network flow Download PDF

Info

Publication number
CN109151584B
CN109151584B CN201811043061.0A CN201811043061A CN109151584B CN 109151584 B CN109151584 B CN 109151584B CN 201811043061 A CN201811043061 A CN 201811043061A CN 109151584 B CN109151584 B CN 109151584B
Authority
CN
China
Prior art keywords
image data
code stream
dct coefficient
dct
blocks
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
CN201811043061.0A
Other languages
Chinese (zh)
Other versions
CN109151584A (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.)
Huawei Cloud Computing Technologies Co Ltd
Original Assignee
Huawei Technologies 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201811043061.0A priority Critical patent/CN109151584B/en
Publication of CN109151584A publication Critical patent/CN109151584A/en
Application granted granted Critical
Publication of CN109151584B publication Critical patent/CN109151584B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/443OS processes, e.g. booting an STB, implementing a Java virtual machine in an STB or power management in an STB
    • H04N21/4437Implementing a Virtual Machine [VM]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/186Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a colour or a chrominance component
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/60Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding
    • H04N19/625Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding using discrete cosine transform [DCT]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/238Interfacing the downstream path of the transmission network, e.g. adapting the transmission rate of a video stream to network bandwidth; Processing of multiplex streams
    • H04N21/2385Channel allocation; Bandwidth allocation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/45Management operations performed by the client for facilitating the reception of or the interaction with the content or administrating data related to the end-user or to the client device itself, e.g. learning user preferences for recommending movies, resolving scheduling conflicts
    • H04N21/462Content or additional data management, e.g. creating a master electronic program guide from data received from the Internet and a Head-end, controlling the complexity of a video stream by scaling the resolution or bit-rate based on the client capabilities
    • H04N21/4621Controlling the complexity of the content stream or additional data, e.g. lowering the resolution or bit-rate of the video stream for a mobile client with a small screen

Abstract

The application provides a method for controlling network traffic, which is executed by a virtual machine, wherein an application program runs in the virtual machine, and the method comprises the following steps: acquiring a current sequence instruction, wherein the current sequence instruction carries target image data to be drawn, and the current sequence instruction is generated by the application program; determining a code stream length threshold according to a network bandwidth and a preset frame rate, wherein the network bandwidth is a currently available network bandwidth distributed for the virtual machine; compressing the target image data by using a progressive jpeg compression method to generate a target code stream, wherein the length of the target code stream is less than or equal to the code stream length threshold; and outputting the target code stream. The method can reduce the possibility of network jamming and enhance the fluency experience of the user.

Description

Method and device for controlling network flow
Technical Field
The present application relates to the field of information technology, and more particularly, to a method and apparatus for controlling network traffic.
Background
With the development of public cloud services, desktop cloud is one of common applications deployed on public cloud, and maintaining smooth and stable operation of the desktop cloud in a wide area network environment is one of the major challenges faced by the desktop cloud.
In a wide area network environment, large delay, transmission bandwidth limitation, packet loss, jitter and the like all have great influence on the user experience of the desktop cloud. Especially, when a desktop cloud is subjected to scene switching (for example, a full-screen image update caused by a user opening an application), necessary transmission of a large amount of update data is often caused, so that a peak bandwidth is generated, congestion of a wide area network is caused, and images of the virtual machine or even multiple virtual machines are blocked or even disconnected, so that user experience of a client is affected.
Therefore, it is desirable to provide a network flow control technique to maintain smooth experience for users under a wide area network.
Disclosure of Invention
The application provides a method for controlling network flow, which can reduce the possibility of network jamming and enhance the fluency experience of users.
In a first aspect, a method for controlling network traffic is provided, where the method is performed by a virtual machine, where an application program runs in the virtual machine, and the method includes: acquiring a current sequence instruction, wherein the current sequence instruction carries target image data to be drawn, and the current sequence instruction is generated by the application program; determining a code stream length threshold according to a network bandwidth and a preset frame rate, wherein the network bandwidth is a currently available network bandwidth distributed for the virtual machine; compressing the target image data by using a progressive jpeg compression method to generate a target code stream, wherein the length of the target code stream is less than or equal to the code stream length threshold; and outputting the target code stream.
The method comprises the steps of determining a code stream length threshold according to a currently available network bandwidth and a preset frame rate distributed to a virtual machine, and controlling the length of a target code stream according to the code stream length threshold, so that the length of the output target code stream is not greater than the code stream threshold length, and the network bandwidth required by the transmission of the target code stream is controlled, and further the possibility of network jamming caused by overlarge network bandwidth required by the transmission of the target code stream is reduced, and the fluency experience of a user is enhanced.
Optionally, the compressing the N-layer DCT coefficient set by using a progressive jpeg compression method to generate the target code stream includes: compressing the N layers of DCT coefficient sets by using a progressive jpeg compression method to generate an original code stream, and generating the target code stream according to the code stream length threshold and the original code stream, wherein the length of the original code stream is greater than the code stream length threshold; or, according to the code stream length threshold, compressing the N-layer DCT coefficient set by using a progressive jpeg compression method to generate the target code stream.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes: and determining that the drawing area of the target image data indicated by the current sequence instruction is a pseudo video area, wherein the pseudo video area is an area meeting a preset rule.
Before the target image data is compressed by using a progressive jpeg compression method and a target code stream is generated, whether a drawing area of the target image data indicated by a current sequence instruction is a pseudo video area or not is determined, when the drawing area of the target image data is the pseudo video area, the target image data carried by the current sequence instruction is compressed by using the progressive jpeg compression method, and the sequence instruction which is not marked as a video mode by virtual display driving is prevented from being directly coded by using other compression methods, namely, when the drawing area of the target image data which is not marked as the video mode by the sequence instruction of the video mode by virtual display driving is the pseudo video area, the target image data carried by the current sequence instruction is compressed by using the progressive jpeg compression method, so that the network bandwidth required by the transmission of the target code stream is controlled, and the possibility of network jamming caused by overlarge network bandwidth required by the transmission of the target code stream is reduced, thereby enhancing the fluency experience for the user.
With reference to the first aspect, in certain implementations of the first aspect, the target image data includes a plurality of image data blocks, and the preset rule includes: the hit rate of the image data blocks is smaller than or equal to a preset hit rate threshold, the ratio of high-complexity blocks in non-hit blocks in the image data blocks is larger than or equal to a preset complexity threshold, and the horizontal and vertical coordinates of the drawing area of the target image data of the current sequence instruction and the previous sequence instruction are the same, wherein the time interval between the current sequence instruction and the previous sequence instruction is smaller than or equal to a preset time threshold.
With reference to the first aspect, in certain implementations of the first aspect, the generating the target code stream includes: aiming at the image data blocks, generating a plurality of DCT coefficient matrixes, wherein each image data block corresponds to 3 DCT coefficient matrixes, and the 3 DCT coefficient matrixes correspond to the three components one by one; dividing the plurality of DCT coefficient matrixes into N layers of DCT coefficient sets, wherein N is an integer greater than or equal to 2, each layer of DCT coefficient set comprises a plurality of DCT coefficients, the DCT coefficients consist of DCT coefficients with the same index values corresponding to the same components in the image data blocks, and the DCT coefficients in the DCT coefficient set with the index value of 1 correspond to the brightness components; and compressing the N layers of DCT coefficient sets by using a progressive jpeg compression method to generate the target code stream.
By dividing a plurality of Discrete Cosine Transform (DCT) coefficient matrixes into N layers of DCT coefficient sets and enabling a plurality of DCT coefficients in the DCT coefficient set with the index value of 1 to correspond to the brightness component, after the N layers of DCT coefficient sets are compressed by using a progressive jpeg compression method, the plurality of DCT coefficients corresponding to the brightness component are borne at the higher bit of the generated target code stream, and because the brightness component corresponds to the outline information of the image, when a client analyzes the target code stream to obtain target image data and renders the target image data, the outline information of the target image can be presented to a user earlier, so that the visual experience of the user is improved.
With reference to the first aspect, in certain implementations of the first aspect, a value of N is 8, a size of the DCT coefficient matrix is 8 by 8, a DCT coefficient set with an index value of 0 in the N layers of DCT coefficients includes a DCT coefficient with an index value of 0 corresponding to a luminance component in the plurality of image data blocks, a DCT coefficient with an index value of 0 corresponding to a chrominance component and a DCT coefficient with an index value of 0 corresponding to a saturation component, a DCT coefficient set with an index value of 1 includes DCT coefficients with index values of 1 to 20 corresponding to luminance components in the plurality of image data blocks, a DCT coefficient set with an index value of 2 includes DCT coefficients with index values of 21 to 35 corresponding to a luminance component in the plurality of image data blocks, a DCT coefficient set with an index value of 3 includes DCT coefficients with index values of 1 to 35 corresponding to chrominance components in the plurality of image data blocks, the DCT coefficient set with an index value of 4 includes DCT coefficients with index values of 1 to 35 corresponding to saturation components in the plurality of image data blocks, the DCT coefficient set with an index value of 5 includes DCT coefficients with index values of 36 to 63 corresponding to luminance components in the plurality of image data blocks, the DCT coefficient set with an index value of 6 includes DCT coefficients with index values of 36 to 63 corresponding to chrominance components in the plurality of image data blocks, and the DCT coefficient set with an index value of 7 includes DCT coefficients with index values of 36 to 63 corresponding to saturation components in the plurality of image data blocks.
By layering the Discrete Cosine Transform (DCT) coefficient matrixes according to the method, the probability of a large number of mosaics appearing at a display end when a network is blocked can be reduced, and the visual experience of a user is improved.
In a second aspect, there is provided an apparatus for controlling network traffic, the apparatus being configured to perform the method of the first aspect or any possible implementation manner of the first aspect. In particular, the apparatus may include means for performing the method of the first aspect or any possible implementation of the first aspect for controlling network traffic.
In a third aspect, an apparatus for controlling network traffic is provided that includes a memory and a processor. The memory is to store instructions; the processor executes the instructions stored by the memory to cause the apparatus to perform the method of controlling network traffic in the first aspect or any possible implementation of the first aspect.
In a fourth aspect, a computer-readable storage medium is provided, in which instructions are stored, which, when executed on a computer, cause the computer to perform the method of controlling network traffic in the first aspect or any possible implementation manner of the first aspect.
In a fifth aspect, there is provided a computer program product comprising instructions which, when run on a computer, cause the computer to perform the method of controlling network traffic of the first aspect or any possible implementation manner of the first aspect.
Drawings
Fig. 1 is a schematic flow chart of a method for controlling network traffic provided by an embodiment of the present application.
Fig. 2 is a scan sequence diagram of a DCT coefficient matrix according to an embodiment of the present application.
Fig. 3 is a schematic block diagram of an apparatus for controlling network traffic according to an embodiment of the present disclosure.
Fig. 4 is another schematic block diagram of an apparatus for controlling network traffic according to an embodiment of the present disclosure.
Detailed Description
The technical solution in the present application will be described below with reference to the accompanying drawings.
First, a general method for improving user fluency in a desktop cloud scenario is introduced.
The method adopts an active prediction updating technology of the client, namely, the client actively predicts according to a sequence instruction, when the refreshing time is up but the subsequent sequence instruction is not up, the client refreshes according to the predicted sequence instruction, and the display content rendered according to the predicted sequence instruction is presented to a user; and when a real instruction comes, carrying out fault tolerance and correction on the displayed content, and finally displaying the correct content to a user.
The technical difficulty of the method lies in the real-time and accurate prediction of the sequence instruction behaviors. Therefore, once prediction deviation occurs, an error instant display result is caused, and the fluency experience of the user is influenced
The embodiment of the invention provides a method for controlling network flow, which determines a code stream length threshold according to a currently available network bandwidth and a preset frame rate distributed for a virtual machine, and controls the length of a target code stream according to the code stream length threshold, so that the length of the output target code stream is not greater than the code stream threshold length, the network bandwidth required by transmitting the target code stream is controlled, the possibility of network jamming caused by overlarge network bandwidth required by transmitting the target code stream is further reduced, and the fluency experience of a user is enhanced.
The method 100 for controlling network traffic according to the embodiment of the present invention is introduced below, where the method 100 is applied to a cloud desktop scene and executed by a virtual machine, and an application program runs in the virtual machine.
The virtual machine acquires a sequence instruction generated by a user triggering application program, compresses image data carried in the sequence instruction into a code stream and sends the code stream to the client, the client processes the code stream to obtain the image data, renders the image data and finally displays the rendered image to the user. The method specifically comprises the following steps.
101, obtaining a current sequence instruction, wherein the current sequence instruction carries target image data to be drawn, and the current sequence instruction is generated by the application program.
Specifically, a user triggers an application running on the virtual machine to generate a sequence instruction (e.g., a current sequence instruction), the current sequence instruction is intercepted by a virtual display driver in the virtual machine, and the current sequence instruction carries image data (e.g., target image data) to be drawn on a display end. The virtual display driver is communicated with a server program running in the virtual machine, and the server program acquires a current sequence instruction intercepted by the virtual display driver.
For example, when a user opens a word and then rolls a mouse, the operation of rolling the mouse by the user triggers a word application program to generate a sequence instruction, the sequence instruction carries the content of the word to be drawn on a computer display screen, the sequence instruction is intercepted by a virtual display driver in a virtual machine, and a server program acquires the current sequence instruction intercepted by the virtual display driver.
And 102, determining a code stream length threshold according to a network bandwidth and a preset frame rate, wherein the network bandwidth is a currently available network bandwidth allocated to the virtual machine.
And 104, compressing the target image data by using a joint photographic experts group (jpeg) compression method to generate a target code stream, wherein the length of the target code stream is less than or equal to the code stream length threshold.
And 105, outputting the target code stream.
Specifically, the server program obtains a current sequence instruction intercepted by the virtual display driver, determines a code stream length threshold according to a network bandwidth (for example, a currently available network bandwidth allocated to the virtual machine) and a preset frame rate, and compresses target image data carried in the current sequence instruction by using an advanced jpeg compression method to generate a target code stream, wherein the length of the target code stream is less than or equal to the code stream length threshold.
For example, the virtual network node includes 10 virtual machines, and if the total available network bandwidth of the virtual network node is 100 mbits, the current available network bandwidth allocated to each virtual machine is 10 mbits, and if the preset frame rate is 10, that is, 10 frames of code streams need to be transmitted per second, the network bandwidth allocated to each frame of code stream is 1 mbit, that is, the service-side program determines that the code stream length threshold is 1 mbit according to the current available network bandwidth and the preset frame rate.
In addition, the currently available network bandwidth allocated to each virtual machine may also change with the change of round-trip time (RTT) besides the total number of virtual machines and the preset frame rate, for example, when the RTT required by the network is 80 milliseconds (ms), assuming that the currently available network bandwidth allocated to the virtual machine is 4 megabits at this time, if the RTT required by the network becomes 40ms, the currently available network bandwidth of the virtual machine also correspondingly changes to 2 megabits.
The method comprises the steps of determining a code stream length threshold according to a currently available network bandwidth and a preset frame rate distributed to a virtual machine, and controlling the length of a target code stream according to the code stream length threshold, so that the length of the output target code stream is not greater than the code stream threshold length, and the network bandwidth required by the transmission of the target code stream is controlled, and further the possibility of network jamming caused by overlarge network bandwidth required by the transmission of the target code stream is reduced, and the fluency experience of a user is enhanced.
The following describes a method for generating a target code stream by compressing target image data by using a progressive jpeg compression method according to an embodiment of the present invention.
By way of example and not limitation, the target image data includes a plurality of image data blocks, each image data block including a luminance component, a chrominance component, and a saturation component, the generating the target code stream including: generating a plurality of Discrete Cosine Transform (DCT) coefficient matrices for the plurality of image data blocks, each image data block corresponding to 3 DCT coefficient matrices, the 3 DCT coefficient matrices corresponding to the three components one-to-one; dividing the plurality of DCT coefficient matrixes into N layers of DCT coefficient sets, wherein N is an integer greater than or equal to 2, each layer of DCT coefficient set comprises a plurality of DCT coefficients, the plurality of DCT coefficients consist of DCT coefficients with the same index values corresponding to the same components in the plurality of image data blocks, and the plurality of DCT coefficients in the DCT coefficient set with the index value of 1 correspond to the brightness components; and compressing the N layers of DCT coefficient sets by using a progressive jpeg compression method to generate the target code stream.
Specifically, when the server program compresses the target image data by using a progressive jpeg compression method, the target image data is divided into a plurality of image data blocks, and each image data block comprises a luminance component, a chrominance component and a saturation component.
For example, the luminance component (denoted as Y component), the chrominance component (denoted as U component), and the saturation component (denoted as V component) of each image data block are each 1 matrix of 8 by 8, i.e., each image data block corresponds to 3 matrices of 8 by 8 components. The server program calculates corresponding Discrete Cosine Transform (DCT) coefficients for 3 8 by 8 component matrices corresponding to each image block data, that is, each component matrix corresponds to 1 8 by 8 DCT coefficient matrix, and each image data block corresponds to 3 8 by 8 DCT coefficient matrices.
As shown in fig. 2, the server re-orders the DCT coefficients in each DCT coefficient matrix according to the scan order diagram shown in fig. 2, and taking a DCT coefficient matrix as an example, after re-arranging the elements in the DCT coefficient matrix according to the scan order shown in fig. 2, the order of the DCT coefficients in the DCT coefficient matrix is shown in table 1.
TABLE 1
0 1 5 6 14 15 27 28
2 4 7 13 16 26 29 42
3 8 12 17 25 30 41 43
9 11 18 24 31 40 44 53
10 19 23 32 39 45 52 54
20 22 33 38 46 51 55 60
21 34 37 47 50 56 59 61
35 36 48 49 57 58 62 63
The server program divides the DCT coefficients in all DCT coefficient matrices corresponding to the plurality of image data blocks into N layers of DCT coefficient sets, where N is an integer greater than or equal to 2, each layer of DCT coefficient set includes a plurality of DCT coefficients, and the plurality of DCT coefficients are composed of DCT coefficients having the same index value corresponding to the same component in the plurality of image data blocks, for example, the DCT coefficient in the DCT coefficient set having an index value of 1 is a DCT coefficient having the same index value corresponding to the Y component in the plurality of image data blocks.
After the N-layer DCT coefficient set is generated, the server program may compress the N-layer DCT coefficient set by using a progressive jpeg compression method through the following two methods, and generate the target code stream.
By dividing a plurality of Discrete Cosine Transform (DCT) coefficient matrixes into N layers of DCT coefficient sets and enabling a plurality of DCT coefficients in the DCT coefficient set with the index value of 1 to correspond to the brightness component, after the N layers of DCT coefficient sets are compressed by using a progressive jpeg compression method, the plurality of DCT coefficients corresponding to the brightness component are borne at the higher bit of the generated target code stream, and because the brightness component corresponds to the outline information of the image, when a client analyzes the target code stream to obtain target image data and renders the target image data, the outline information of the target image can be presented to a user earlier, so that the visual experience of the user is improved.
Method 1
By way of example and not limitation, the generating the target code stream by compressing the N-layer DCT coefficient set using a progressive jpeg compression method includes: and compressing the N layers of DCT coefficient sets by using a progressive jpeg compression method to generate an original code stream, and generating the target code stream according to the code stream length threshold and the original code stream, wherein the length of the original code stream is greater than the code stream length threshold.
Specifically, when the server program compresses the N-layer DCT coefficient set by using the progressive jpeg compression method, the server program may first compress the N-layer DCT coefficient set by using the progressive jpeg compression method to generate a code stream (e.g., an original code stream), where the length of the original code stream is greater than the code stream length threshold.
Because the length of the original code stream is greater than the code stream length threshold, the server program generates a target code stream according to the code stream length threshold and the original code stream before outputting the original code stream.
For example, the value of N is 8, and the 8-layer DCT coefficient sets are, in order from the top layer to the bottom layer:
the DCT coefficient set with the index value of 0 comprises a DCT coefficient with the index value of 0 corresponding to the Y component in the image data blocks, a DCT coefficient with the index value of 0 corresponding to the U component and a DCT coefficient with the index value of 0 corresponding to the V component, wherein the DCT coefficient with the index value of 0 corresponding to the Y component is a Direct Current (DC) component of the Y component, the DCT coefficient with the index value of 0 corresponding to the U component is a DC component of the U component, and the DCT coefficient with the index value of 0 corresponding to the V component is a DC component of the V component;
the DCT coefficient set with the index value of 1 comprises DCT coefficients with the index values of 1 to 20 corresponding to Y components in the image data blocks, wherein the DCT coefficients with the index values of 1 to 20 corresponding to the Y components are low-frequency Alternating Current (AC) components of the Y components;
the DCT coefficient set with the index value of 2 comprises DCT coefficients with the index values of 21 to 35 corresponding to Y components in the image data blocks, wherein the DCT coefficients with the index values of 21 to 35 corresponding to the Y components are intermediate-frequency AC components of the Y components;
the DCT coefficient set with the index value of 3 comprises DCT coefficients with the index values of 1 to 35 corresponding to U components in the image data blocks, wherein the DCT coefficients with the index values of 1 to 35 corresponding to the U components are low-frequency AC components of the U components;
the DCT coefficient set with the index value of 4 comprises DCT coefficients with the index values of 1 to 35 corresponding to V components in the image data blocks, wherein the DCT coefficients with the index values of 1 to 35 corresponding to the V components are low-frequency AC components of the V components;
the DCT coefficient set with the index value of 5 comprises DCT coefficients with the index values of 36 to 63 corresponding to Y components in the image data blocks, wherein the DCT coefficients with the index values of 36 to 63 corresponding to the Y components are high-frequency AC components of the Y components;
the DCT coefficient set with the index value of 6 comprises DCT coefficients with the index values of 36 to 63 corresponding to U components in the image data blocks, wherein the DCT coefficients with the index values of 36 to 63 corresponding to the U components are high-frequency AC components of the U components;
the DCT coefficient set with an index value of 7 includes DCT coefficients with index values of 36 to 63 corresponding to V components in the plurality of image data blocks, where the DCT coefficients with index values of 36 to 63 corresponding to V components are high-frequency AC components of the V components.
By layering the Discrete Cosine Transform (DCT) coefficient matrixes according to the method, the probability of a large number of mosaics appearing at a display end when a network is blocked can be reduced, and the visual experience of a user is improved.
The server program performs compression coding on the 8 layers of DCT coefficients to generate an original code stream, the original code stream corresponds to the 8 layers of DCT coefficients before compression, the original code stream also comprises 8 layers of code streams, and adjacent code streams are separated by a start off flag (SOS), wherein the 1 st layer of code stream comprises a code stream obtained by performing compression coding on a DCT coefficient set with an index value of 0, the 2 nd layer of code stream comprises the 1 st layer of code stream and a code stream obtained by performing compression coding on a DCT coefficient set with an index value of 1, the 3 rd layer of code stream comprises the 1 st layer of code stream, the 2 nd layer of code stream and a code stream obtained by performing compression coding on a DCT coefficient set with an index value of 2, and so on, the 8 th layer comprises the 1 st to 7 th layer of code streams and a code stream obtained by performing compression coding on a DCT coefficient set with an index value of 7.
The server program determines the length of a code stream to be output (for example, a target code stream) according to the determined code stream length threshold, determines that the code stream length in the 8 layers of code streams is not greater than the code stream length threshold, and determines the code stream of the corresponding layer with the highest code stream layer number as the target code stream.
For example, the value of the code stream threshold length is 10 megabits, the length of the 6 th layer code stream of the original code stream generated by the server program is 7, the length of the generated 7 th layer code stream is 9, and the length of the generated 8 th layer code stream is 12, then the server program determines the 7 th layer code stream as the target code stream, and outputs the 7 th layer code stream to the client.
Method 2
By way of example and not limitation, the generating the target code stream by compressing the N-layer DCT coefficient set using a progressive jpeg compression method includes: and compressing the N-layer DCT coefficient set by using a progressive jpeg compression method according to the code stream length threshold value to generate the target code stream.
Specifically, the method 2 is similar to the method 1, and is different in that after the server program obtains the 8-layer DCT coefficient set with index values from 0 to 7, the server program does not generate the original code stream, but directly generates a target code stream with a code stream length not greater than the code stream length threshold according to the determined code stream length threshold, and outputs the target code stream to the client.
The server program may perform calculation before performing compression coding on the 8-layer DCT coefficient set having an index value of 0 to an index value of 7, for example, by performing calculation, the server program determines that the length of the generated 7 th layer code stream is 7 megabits, the length of the generated 8 th layer code stream is 9 megabits, and the length threshold of the code stream determined by the server program is 8 megabits, and then the server program generates only the 7 th layer code stream (for example, a target code stream) and outputs the 7 th layer code stream to the client when performing compression coding on the 8-layer DCT coefficient set having an index value of 0 to an index value of 7 according to the code stream length threshold.
In the embodiment of the present invention, only the two methods for generating the target code stream are described as examples, and the embodiment of the present invention is not particularly limited.
It should be noted that when a virtual display driver in a virtual machine intercepts a current sequence of instructions triggered by an application program, the virtual display driver marks the current sequence of instructions, for example, if target image data carried by the current sequence of instructions relates to a complex slide show (PPT) gradual animation, the virtual display driver marks the current sequence of instructions as a video mode; otherwise, if the target graphic data carried by the current sequence of instructions designs a simple PPT gradual-change animation, the virtual display driver does not mark the current sequence of instructions as a video mode.
In the prior art, if the current sequence instruction is not marked as a video mode, the server program compresses the target image data by adopting other compression methods, and finally sends the generated target code stream to the client. If other compression methods are adopted to compress the target image data, a very large transmission bandwidth may be required when the generated target code stream is transmitted, and therefore, a network may be jammed, and the fluency experience of a user is further affected.
To address this problem, the method 100 provided in this embodiment of the present invention further includes, before step 104:
and 103, determining the drawing area of the target image data indicated by the current sequence instruction as a pseudo video area, wherein the pseudo video area is an area meeting a preset rule.
Specifically, before compressing and encoding target image data carried by a current sequence instruction, a server program firstly determines that a drawing area of the target image data indicated by the current sequence instruction is a pseudo video area, and when the drawing area of the target image data is the pseudo video area, the server program compresses and encodes the target image data by adopting a progressive jpeg compression method, wherein the pseudo video area is an area meeting a preset rule. The drawing area of the target image data refers to a corresponding rendering area on a display screen when the client renders the target image data.
For example, after the server program acquires the current sequence instruction triggered by the application program, if the virtual display driver does not mark the intercepted current sequence instruction triggered by the application program as a video mode, the server program determines whether a drawing area of target image data indicated by the current sequence instruction is a pseudo video area before compression coding is performed on the target image data carried by the current sequence instruction, and when the drawing area of the target image data is the pseudo video area, the server program compresses and codes the target image data by using a progressive jpeg compression method.
Before the target image data is compressed by using a progressive jpeg compression method and a target code stream is generated, whether a drawing area of the target image data indicated by a current sequence instruction is a pseudo video area or not is determined, when the drawing area of the target image data is the pseudo video area, the target image data carried by the current sequence instruction is compressed by using the progressive jpeg compression method, and the sequence instruction which is not marked as a video mode by virtual display driving is prevented from being directly coded by using other compression methods, namely, when the drawing area of the target image data which is not marked as the video mode by the sequence instruction of the video mode by virtual display driving is the pseudo video area, the target image data carried by the current sequence instruction is compressed by using the progressive jpeg compression method, so that the network bandwidth required by the transmission of the target code stream is controlled, and the possibility of network jamming caused by overlarge network bandwidth required by the transmission of the target code stream is reduced, thereby enhancing the fluency experience for the user.
By way of example and not limitation, the preset rules include: the hit rate of the image data blocks is less than or equal to a preset hit rate threshold, the high complexity block ratio of non-hit blocks in the image data blocks is greater than or equal to a preset complexity threshold, and the abscissa and ordinate of the drawing area of the target image data of the current sequence of instructions are the same as those of the previous sequence of instructions, wherein the time interval between the current sequence of instructions and the previous sequence of instructions is less than or equal to a preset time threshold.
The hit rate of the image data blocks refers to a ratio of hit blocks in the plurality of image data blocks to the plurality of image data blocks, and a hit block refers to a certain image block that is carried in at least one sequence command before the current sequence command.
The high complexity block ratio in the non-hit blocks refers to a ratio of high complexity blocks in the non-hit blocks in the plurality of image data blocks to all non-hit blocks, the high complexity blocks generally refer to data blocks corresponding to natural image (e.g., landscape) data, and the low complexity blocks generally refer to data blocks corresponding to text image (e.g., text in word) data.
Specifically, the target image data carried by the current sequence of instructions may be divided into a plurality of image data blocks, and if the hit rate of the plurality of image blocks is less than or equal to a preset hit rate threshold, and the high-complexity block ratio in non-hit blocks of the plurality of image data blocks is greater than or equal to a preset complexity threshold, and the horizontal and vertical coordinates of the drawing region of the target image data of the current sequence of instructions are the same, and the time interval between the current sequence of instructions and the previous sequence of instructions is less than or equal to a preset time threshold, the server determines the drawing region of the target image data indicated by the current sequence of instructions as a pseudo-video region, and performs compression encoding on the target image data carried by the current sequence of instructions by using a progressive jpeg compression method.
For example, if the hit rate of the multiple image blocks carried by the current sequence instruction is 20%, the hit rate threshold is 26%; and, the high complexity block ratio in the non-hit blocks in the plurality of image data blocks is 33%, and the complexity threshold is 15%; the abscissa and ordinate of the drawing area of the target image data indicated by the current sequence of instructions are (1, 16), and the abscissa and ordinate of the drawing area of the target image data indicated by the previous sequence of instructions are (1, 16); and if the time interval between the current sequence instruction and the previous sequence instruction is 10ms and the preset time threshold is 12ms, the server program determines the drawing area of the target image data indicated by the current sequence instruction as a pseudo video area, and compresses and encodes the target image data carried by the current sequence instruction by adopting a progressive jpeg compression method.
It should be noted that the current sequence instruction and the previous sequence instruction may be two physically adjacent sequence instructions, or may also be two logically adjacent sequence instructions, for example, the previous sequence instruction may be a sequence instruction whose time threshold value between the current sequence instruction and the current sequence instruction is less than or equal to a preset time threshold value. The embodiment of the present invention is not particularly limited thereto.
It should be noted that, the above is only an example that the preset rule is considered to be satisfied if the horizontal and vertical coordinates of the drawing areas of the target image data of the current sequence command and the previous sequence command are the same, but the embodiment of the present invention is not limited to this, for example, if the horizontal and vertical coordinates of the drawing areas of the target image data of the current sequence command and the previous sequence command are divided by 64 and the rounded values are the same, the preset rule is still considered to be satisfied; or, if the difference between the abscissa and the ordinate of the drawing region of the target image data of the current sequence of instructions and the previous sequence of instructions is within a preset range, the preset rule is still considered to be satisfied.
It should be further noted that, in the embodiment of the present invention, step 103 may be used in combination with steps 101, 102, 104, and 105 in method 100, but the embodiment of the present invention is not limited to this, and for example, step 103 may also be used alone, that is, when determining that the drawing region of the target image data is a pseudo video region, the target image data carried by the current sequence instruction is compressed by using a progressive jpeg compression method, and at this time, the length of the generated target code stream may not be limited.
When the step 103 is used alone, compared with the case that the sequence instruction which is not marked as the video mode by the virtual display driver is directly coded by using other compression methods, the method can also control the network bandwidth required by the transmission target code stream, thereby reducing the possibility of network jamming caused by overlarge network bandwidth required by the transmission target code stream and enhancing the fluency experience of the user.
The method for controlling network traffic according to the embodiment of the present invention is described above with reference to fig. 1 to 2, and the apparatus for controlling network traffic according to the embodiment of the present invention is described below with reference to fig. 3 to 4.
Fig. 3 is a schematic block diagram of an apparatus 200 for controlling network traffic according to an embodiment of the present invention, where the apparatus 200 runs an application, and includes a processing module 201 and a sending module 202.
A processing module 201, configured to obtain a current sequence of instructions, where the current sequence of instructions carries target image data to be rendered, and the current sequence of instructions is generated by the application program;
the processing module 201 is further configured to determine a code stream length threshold according to a network bandwidth and a preset frame rate, where the network bandwidth is a currently available network bandwidth allocated to the virtual machine;
the processing module 201 is further configured to compress the target image data by using a progressive jpeg compression device to generate a target code stream, where the length of the target code stream is less than or equal to the code stream length threshold;
and a sending module 202, configured to output the target code stream.
Optionally, the processing module 201 is further configured to determine, before the target image data is compressed by using a progressive jpeg compression apparatus to generate a target code stream, that the drawing area of the target image data indicated by the current sequence instruction is a pseudo video area, where the pseudo video area is an area meeting a preset rule.
Optionally, the target image data includes a plurality of image data blocks, and the preset rule includes: the hit rate of the image data blocks is less than or equal to a preset hit rate threshold, the high complexity block ratio of non-hit blocks in the image data blocks is greater than or equal to a preset complexity threshold, and the abscissa and ordinate of the drawing area of the target image data of the current sequence of instructions are the same as those of the previous sequence of instructions, wherein the time interval between the current sequence of instructions and the previous sequence of instructions is less than or equal to a preset time threshold.
Optionally, the target image data includes a plurality of image data blocks, each image data block includes a luminance component, a chrominance component, and a saturation component, the processing module 201 is further configured to generate a plurality of DCT coefficient matrices for the plurality of image data blocks, each image data block corresponds to 3 DCT coefficient matrices, and the 3 DCT coefficient matrices correspond to the three components one to one; dividing the plurality of DCT coefficient matrixes into N layers of DCT coefficient sets, wherein N is an integer greater than or equal to 2, each layer of DCT coefficient set comprises a plurality of DCT coefficients, the plurality of DCT coefficients consist of DCT coefficients with the same index values corresponding to the same components in the plurality of image data blocks, and the plurality of DCT coefficients in the DCT coefficient set with the index value of 1 correspond to the brightness components; and compressing the N layers of DCT coefficient sets by using a progressive jpeg compression method to generate the target code stream.
Optionally, the processing module 201 is further configured to compress the N-layer DCT coefficient set by using a progressive jpeg compression apparatus, generate an original code stream, and generate the target code stream according to the code stream length threshold and the original code stream, where the length of the original code stream is greater than the code stream length threshold; or, according to the code stream length threshold, compressing the N-layer DCT coefficient set by using a progressive jpeg compression method to generate the target code stream.
Optionally, the value of N is 8, the size of the DCT coefficient matrix is 8 by 8, a DCT coefficient set with an index value of 0 in the N layers of DCT coefficients includes a DCT coefficient with an index value of 0 corresponding to a luminance component in the plurality of image data blocks, a DCT coefficient with an index value of 0 corresponding to a chrominance component and a DCT coefficient with an index value of 0 corresponding to a saturation component, a DCT coefficient set with an index value of 1 includes DCT coefficients with index values of 1 to 20 corresponding to luminance components in the plurality of image data blocks, a DCT coefficient set with an index value of 2 includes DCT coefficients with index values of 21 to 35 corresponding to luminance components in the plurality of image data blocks, a DCT coefficient set with an index value of 3 includes DCT coefficients with index values of 1 to 35 corresponding to chrominance components in the plurality of image data blocks, a DCT coefficient set with an index value of 4 includes a DCT coefficient with an index value of 1 to 35 corresponding to a saturation component in the plurality of image data blocks, the DCT coefficient set with an index value of 5 includes DCT coefficients with index values of 36 to 63 corresponding to luminance components in the plurality of image data blocks, the DCT coefficient set with an index value of 6 includes DCT coefficients with index values of 36 to 63 corresponding to chrominance components in the plurality of image data blocks, and the DCT coefficient set with an index value of 7 includes DCT coefficients with index values of 36 to 63 corresponding to saturation components in the plurality of image data blocks.
The apparatus 200 for controlling network traffic according to the embodiment of the present invention may correspond to performing the method 100 described in the embodiment of the present invention, and the above and other operations and/or functions of each unit in the apparatus 200 are respectively for implementing the corresponding flow of the method 100 in fig. 1, and are not described herein again for brevity.
Fig. 4 is a schematic block diagram of an apparatus 300 for controlling network traffic according to an embodiment of the present invention, where the apparatus 300 for controlling network traffic runs an application, and the apparatus includes: a memory 301 and a processor 302.
A memory 301 for storing programs.
Execution of the program in the memory by the processor 302 causes the apparatus 300 to perform the steps in the method of controlling network traffic (e.g., method 100) described in embodiments of the present invention.
Embodiments of the present invention provide a computer-readable storage medium, where instructions are stored, and when the instructions are executed on a computer, the instructions cause the computer to execute a method for controlling network traffic according to an embodiment of the present invention.
Embodiments of the present invention provide a computer program product comprising instructions that, when executed on a computer, cause the computer to perform a method of controlling network traffic according to embodiments of the present invention.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: 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 above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (12)

1. A method for controlling network traffic, the method being performed by a virtual machine, the virtual machine having an application running therein, comprising:
acquiring a current sequence instruction, wherein the current sequence instruction carries target image data to be drawn, and the current sequence instruction is generated by the application program;
determining a code stream length threshold according to a network bandwidth and a preset frame rate, wherein the network bandwidth is a currently available network bandwidth distributed for the virtual machine;
compressing the target image data by using a progressive jpeg compression method to generate a target code stream, wherein the length of the target code stream is less than or equal to the code stream length threshold;
outputting the target code stream;
before the target image data is compressed by using a progressive jpeg compression method and a target code stream is generated, the method further comprises the following steps:
and determining that the drawing area of the target image data indicated by the current sequence instruction is a pseudo video area, wherein the pseudo video area is an area meeting a preset rule.
2. The method of claim 1, wherein the target image data comprises a plurality of image data blocks, and wherein the preset rule comprises: the hit rate of the image data blocks is smaller than or equal to a preset hit rate threshold, the ratio of high-complexity blocks in non-hit blocks in the image data blocks is larger than or equal to a preset complexity threshold, and the horizontal and vertical coordinates of the drawing area of the target image data of the current sequence instruction and the previous sequence instruction are the same, wherein the time interval between the current sequence instruction and the previous sequence instruction is smaller than or equal to a preset time threshold.
3. The method of claim 1 or 2, wherein the target image data comprises a plurality of image data blocks, each image data block comprising a luminance component, a chrominance component, and a saturation component, and wherein generating the target codestream comprises:
aiming at the image data blocks, generating a plurality of DCT coefficient matrixes, wherein each image data block corresponds to 3 DCT coefficient matrixes, and the 3 DCT coefficient matrixes correspond to the three components one by one;
dividing the plurality of DCT coefficient matrixes into N layers of DCT coefficient sets, wherein N is an integer greater than or equal to 2, each layer of DCT coefficient set comprises a plurality of DCT coefficients, the DCT coefficients consist of DCT coefficients with the same index values corresponding to the same components in the image data blocks, and the DCT coefficients in the DCT coefficient set with the index value of 1 correspond to the brightness components;
and compressing the N layers of DCT coefficient sets by using a progressive jpeg compression method to generate the target code stream.
4. The method according to claim 3, wherein said compressing the set of N-layer DCT coefficients by using a progressive jpeg compression method to generate the target code stream comprises:
compressing the N layers of DCT coefficient sets by using a progressive jpeg compression method to generate an original code stream, and generating the target code stream according to the code stream length threshold and the original code stream, wherein the length of the original code stream is greater than the code stream length threshold; or
And compressing the N-layer DCT coefficient set by using a progressive jpeg compression method according to the code stream length threshold value to generate the target code stream.
5. The method of claim 3, wherein N is 8, the size of the DCT coefficient matrix is 8 by 8,
the DCT coefficient set with the index value of 0 in the N layers of DCT coefficients comprises the DCT coefficient with the index value of 0 corresponding to the brightness component, the DCT coefficient with the index value of 0 corresponding to the chroma component and the DCT coefficient with the index value of 0 corresponding to the saturation component in the plurality of image data blocks,
the set of DCT coefficients having an index value of 1 includes DCT coefficients having index values of 1 to 20 corresponding to luminance components in the plurality of blocks of image data,
the set of DCT coefficients having an index value of 2 includes DCT coefficients having index values of 21 to 35 corresponding to luminance components in the plurality of blocks of image data,
the set of DCT coefficients having an index value of 3 includes DCT coefficients having index values of 1 to 35 corresponding to chrominance components in the plurality of blocks of image data,
the DCT coefficient set having an index value of 4 includes DCT coefficients having index values of 1 to 35 corresponding to saturation components in the plurality of blocks of image data,
the DCT coefficient set having an index value of 5 includes DCT coefficients having index values of 36 to 63 corresponding to luminance components in the plurality of blocks of image data,
the DCT coefficient set having an index value of 6 includes DCT coefficients having index values of 36 to 63 corresponding to chrominance components in the plurality of blocks of image data,
the DCT coefficient set having an index value of 7 includes DCT coefficients having index values of 36 to 63 corresponding to saturation components in the plurality of image data blocks.
6. An apparatus for controlling network traffic, wherein an application is running in the apparatus, comprising:
the processing module is used for acquiring a current sequence instruction, wherein the current sequence instruction carries target image data to be drawn, and the current sequence instruction is generated by the application program;
the processing module is further configured to determine a code stream length threshold according to a network bandwidth and a preset frame rate, where the network bandwidth is a currently available network bandwidth allocated to the virtual machine;
the processing module is further configured to compress the target image data by using a progressive jpeg compression device to generate a target code stream, where the length of the target code stream is less than or equal to the code stream length threshold;
the sending module is used for outputting the target code stream;
the processing module is further configured to determine that a drawing area of the target image data indicated by the current sequence instruction is a pseudo video area before the target code stream is generated by compressing the target image data with a progressive jpeg compression device, where the pseudo video area is an area satisfying a preset rule.
7. The apparatus of claim 6, wherein the target image data comprises a plurality of image data blocks, and wherein the preset rule comprises: the hit rate of the image data blocks is smaller than or equal to a preset hit rate threshold, the ratio of high-complexity blocks in non-hit blocks in the image data blocks is larger than or equal to a preset complexity threshold, and the horizontal and vertical coordinates of the drawing area of the target image data of the current sequence instruction and the previous sequence instruction are the same, wherein the time interval between the current sequence instruction and the previous sequence instruction is smaller than or equal to a preset time threshold.
8. The apparatus of claim 6 or 7, wherein the target image data comprises a plurality of image data blocks, each image data block comprising a luminance component, a chrominance component, and a saturation component, and wherein the processing module is further configured to generate a plurality of DCT coefficient matrices for the plurality of image data blocks, each image data block corresponding to 3 DCT coefficient matrices, the 3 DCT coefficient matrices corresponding to the three components one to one; dividing the plurality of DCT coefficient matrixes into N layers of DCT coefficient sets, wherein N is an integer greater than or equal to 2, each layer of DCT coefficient set comprises a plurality of DCT coefficients, the DCT coefficients consist of DCT coefficients with the same index values corresponding to the same components in the image data blocks, and the DCT coefficients in the DCT coefficient set with the index value of 1 correspond to the brightness components; and compressing the N layers of DCT coefficient sets by using a progressive jpeg compression method to generate the target code stream.
9. The apparatus of claim 8, wherein the processing module is further configured to compress the N-layer DCT coefficient sets using a progressive jpeg compression apparatus to generate an original code stream, and generate the target code stream according to the code stream length threshold and the original code stream, where a length of the original code stream is greater than the code stream length threshold; or, according to the code stream length threshold, compressing the N-layer DCT coefficient set by using a progressive jpeg compression method to generate the target code stream.
10. The apparatus of claim 8, wherein N is 8, wherein the size of the DCT coefficient matrix is 8 by 8,
the DCT coefficient set with the index value of 0 in the N layers of DCT coefficients comprises the DCT coefficient with the index value of 0 corresponding to the brightness component, the DCT coefficient with the index value of 0 corresponding to the chroma component and the DCT coefficient with the index value of 0 corresponding to the saturation component in the plurality of image data blocks,
the set of DCT coefficients having an index value of 1 includes DCT coefficients having index values of 1 to 20 corresponding to luminance components in the plurality of blocks of image data,
the set of DCT coefficients having an index value of 2 includes DCT coefficients having index values of 21 to 35 corresponding to luminance components in the plurality of blocks of image data,
the set of DCT coefficients having an index value of 3 includes DCT coefficients having index values of 1 to 35 corresponding to chrominance components in the plurality of blocks of image data,
the DCT coefficient set having an index value of 4 includes DCT coefficients having index values of 1 to 35 corresponding to saturation components in the plurality of blocks of image data,
the DCT coefficient set having an index value of 5 includes DCT coefficients having index values of 36 to 63 corresponding to luminance components in the plurality of blocks of image data,
the DCT coefficient set having an index value of 6 includes DCT coefficients having index values of 36 to 63 corresponding to chrominance components in the plurality of blocks of image data,
the DCT coefficient set having an index value of 7 includes DCT coefficients having index values of 36 to 63 corresponding to saturation components in the plurality of image data blocks.
11. An apparatus for controlling network traffic, wherein an application is running in the apparatus, comprising:
a memory for storing a program;
a processor for executing a program stored in the memory, the apparatus performing the method of controlling network traffic of any of claims 1 to 5 when the program in the memory is executed.
12. A computer-readable storage medium having stored therein instructions which, when executed on a computer, cause the computer to perform the method of controlling network traffic of any of claims 1 to 5.
CN201811043061.0A 2018-09-07 2018-09-07 Method and device for controlling network flow Active CN109151584B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811043061.0A CN109151584B (en) 2018-09-07 2018-09-07 Method and device for controlling network flow

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811043061.0A CN109151584B (en) 2018-09-07 2018-09-07 Method and device for controlling network flow

Publications (2)

Publication Number Publication Date
CN109151584A CN109151584A (en) 2019-01-04
CN109151584B true CN109151584B (en) 2020-10-27

Family

ID=64823813

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811043061.0A Active CN109151584B (en) 2018-09-07 2018-09-07 Method and device for controlling network flow

Country Status (1)

Country Link
CN (1) CN109151584B (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1468001A (en) * 2002-06-27 2004-01-14 上海汉唐科技有限公司 Media flow self-adapting transmission method based on internet
CN101340571A (en) * 2008-08-15 2009-01-07 北京中星微电子有限公司 Code rate control method and control apparatus
CN102571526A (en) * 2010-12-08 2012-07-11 华为终端有限公司 Regulating method of conference site bandwidth, device, conference terminal and media control server
CN103686167A (en) * 2013-12-24 2014-03-26 广东威创视讯科技股份有限公司 Multi-stream broadcast method and device
CN103929684A (en) * 2013-01-14 2014-07-16 华为技术有限公司 Method for selecting code stream segmentation based on streaming media, player and terminal
CN105827633A (en) * 2016-05-06 2016-08-03 浙江大华技术股份有限公司 Video transmission method and device
CN107172428A (en) * 2017-06-06 2017-09-15 西安万像电子科技有限公司 The transmission method of image, device and system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101391601B1 (en) * 2007-10-15 2014-05-07 삼성전자주식회사 Method and apparatus for image encoding by exponential-Golomb code using optimal thresholds, and method and apparatus for image decoding by exponential-Golomb code using optimal threshold

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1468001A (en) * 2002-06-27 2004-01-14 上海汉唐科技有限公司 Media flow self-adapting transmission method based on internet
CN101340571A (en) * 2008-08-15 2009-01-07 北京中星微电子有限公司 Code rate control method and control apparatus
CN102571526A (en) * 2010-12-08 2012-07-11 华为终端有限公司 Regulating method of conference site bandwidth, device, conference terminal and media control server
CN103929684A (en) * 2013-01-14 2014-07-16 华为技术有限公司 Method for selecting code stream segmentation based on streaming media, player and terminal
CN103686167A (en) * 2013-12-24 2014-03-26 广东威创视讯科技股份有限公司 Multi-stream broadcast method and device
CN105827633A (en) * 2016-05-06 2016-08-03 浙江大华技术股份有限公司 Video transmission method and device
CN107172428A (en) * 2017-06-06 2017-09-15 西安万像电子科技有限公司 The transmission method of image, device and system

Also Published As

Publication number Publication date
CN109151584A (en) 2019-01-04

Similar Documents

Publication Publication Date Title
AU2014311265B2 (en) Quality controller for video image
EP2364190B1 (en) Centralized streaming game server
CN109792562B (en) Content-based stream segmentation of video data
US7439982B2 (en) Optimized scene graph change-based mixed media rendering
US8264493B2 (en) Method and system for optimized streaming game server
US8154553B2 (en) Centralized streaming game server
CN104096362B (en) The Rate Control bit distribution of video flowing is improved based on player's region-of-interest
EP3410302B1 (en) Graphic instruction data processing method, apparatus
CA2411852A1 (en) Streaming panoramic video
CN110493600B (en) Image encoding method, apparatus, computer device and storage medium
WO2017066346A1 (en) Method and apparatus for optimizing video streaming for virtual reality
EP3595304A1 (en) Code rate allocation method, device, and storage medium
US11368692B2 (en) Content adaptive quantization strength and bitrate modeling
US11924442B2 (en) Generating and displaying a video stream by omitting or replacing an occluded part
WO2013030166A2 (en) Method for transmitting video signals from an application on a server over an ip network to a client device
JP5941000B2 (en) Video distribution apparatus and video distribution method
CN109151584B (en) Method and device for controlling network flow
JP7362903B2 (en) Image data transfer device, image display system, and image data transfer method
US11290735B1 (en) Visual element encoding parameter tuning
Hewage et al. Prioritized 3D video distribution over IEEE 802.11 e
US20230260191A1 (en) Improved Split Rendering for Extended Reality (XR) Applications
CN114007137A (en) ROI-based video hierarchical coding method, device and medium
GB2569791A (en) Display system with defect correction
JP7441936B2 (en) Image data transfer device, image generation method and computer program
Hadic et al. A Simple Desktop Compression and Streaming System

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
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20220208

Address after: 550025 Huawei cloud data center, jiaoxinggong Road, Qianzhong Avenue, Gui'an New District, Guiyang City, Guizhou Province

Patentee after: Huawei Cloud Computing Technology Co.,Ltd.

Address before: 518129 Bantian HUAWEI headquarters office building, Longgang District, Guangdong, Shenzhen

Patentee before: HUAWEI TECHNOLOGIES Co.,Ltd.