CN106101703A - A kind of screen video compression method towards numeral KVM switcher - Google Patents
A kind of screen video compression method towards numeral KVM switcher Download PDFInfo
- Publication number
- CN106101703A CN106101703A CN201610447078.7A CN201610447078A CN106101703A CN 106101703 A CN106101703 A CN 106101703A CN 201610447078 A CN201610447078 A CN 201610447078A CN 106101703 A CN106101703 A CN 106101703A
- Authority
- CN
- China
- Prior art keywords
- current block
- mode
- code stream
- data
- formula
- 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.)
- Granted
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/134—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
- H04N19/154—Measured or subjectively estimated visual quality after decoding, e.g. measurement of distortion
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/102—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
- H04N19/103—Selection of coding mode or of prediction mode
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/102—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
- H04N19/124—Quantisation
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/169—Methods 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/17—Methods 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 an image region, e.g. an object
- H04N19/176—Methods 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 an image region, e.g. an object the region being a block, e.g. a macroblock
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/169—Methods 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/186—Methods 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
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/50—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
- H04N19/59—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving spatial sub-sampling or interpolation, e.g. alteration of picture size or resolution
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
The invention discloses a kind of screen video compression method towards numeral KVM switcher, comprise the following steps: (1) inputs frame screen video data;(2) frame originating point information of current video frame is write code stream;(3) from current video frame, a uncoded chromatic component subframe is obtained;(4) from current chroma component sub-frame, a uncoded data block is obtained;(5) calculate current block coding information under each candidate coding pattern and rebuild data, and choosing final coding mode;(6) the coding information of current block is write code stream;(7) step (4) to (6) is repeated;(8) to current video frame written into code stream carry out byte-aligned process;(9) step (3) to (8) is repeated;(10) code stream producing current video frame carries out frame synchronization head escape process.The present invention effectively reduces entirety and the peak-data amount of screen video code stream under limited computation complexity, keeps good reconstruction video quality simultaneously.
Description
Technical field
The present invention relates to digital video signal processing field, be specifically related to a kind of screen towards numeral KVM switcher and regard
Frequently compression method.
Background technology
Numeral kvm system is the multicomputer handover management system of IP based network, it is possible to realize using a set of keyboard
(Keyboard), display (Video), mouse (Mouse) remotely control multiple stage computer, mainly include numeral KVM switching
Device and main control platform.The output signal of computer display is digitized and network transmission by numeral KVM switcher, in order to
Display screen video in the client of main control platform.Additionally, numeral KVM switcher also receives the keyboard from main control platform and Mus
Mark information, and it is converted into the input signal of local computer, to realize the main control platform long-range control to local computer.
Keyboard and mouse are relatively low due to operation frequency, and the data volume after its signal is digitized into is the least, can be without compression directly biography
Sending, the network bandwidth taken is less.Display is the highest due to resolution and the frame per second of the screen video of output, causes through numeral
The video data volume after change is huge, it is impossible to directly transmit.Therefore, the screen of display output is only regarded by numeral KVM switcher
Frequency compresses efficiently, could is real-time transmitted to long-range by network by screen video data under the limited network bandwidth
Main control platform.The screen video scene of numeral KVM switcher collection mainly includes operating system scene, application software scene and net
Page scenes etc., the resolution of screen video includes the typical resolution from 640 × 350 to 1920 × 1200.In computer system
In, the display video of output use RGB color degree space, i.e. each pixel in image comprise a R component, a G component and
One B component, each component generally represents with 8 bits, and span is 0~255.The screen video of numeral kvm system output
Although abundant in content various, but there is the strongest temporal correlation, can use the method for video compress that it is compressed place
Reason.There is again notable difference with the common natural video frequency of video camera shooting in the screen video of KVM simultaneously, and it comprises some by calculating
The graph image that machine generates, the definition of these pictures is required the highest by people, it is easy to discover the loss of picture.Therefore,
Numeral KVM switcher should carry out Efficient Compression to screen video, the most also to keep preferable video image quality.
Since the nineties in last century, International Telecommunication Union (ITU) and International Organization for Standardization (ISO) are proposed a series of
Video compression standard, including H.261, MPEG-1, H.262/MPEG-2, H.263, MPEG-4, H.264/AVC and H.265/
HEVC.The video encoding standard of main flow is that H.264/AVC ITU and ISO issued in 2003 at present, up-to-date Video coding mark
Standard is that H.265/HEVC ITU and ISO issued in 2013.Above-mentioned video encoding standard is mainly for the nature of camera acquisition
Video scene is compressed, and is mainly used in the fields such as video monitoring, video conference, DTV and digital camera, and all adopts
Use YUV chrominance space.YUV chrominance space include luminance signal Y and two carrier chrominance signals U, V, RGB color degree can be passed through
Space is converted to (see video field classics English books " Video Demystified:A Handbook for the
Digital Engineer, FifthEdition ", Keith Jack, 2007).In the video of YUV444 form, Y, U and V tri-
The sampling rate of individual component is identical, and each pixel comprises three component datas, after 8 bit quantizations, and uncompressed every
Individual pixel takies 3 bytes.In the video of YUV420 form, each pixel has Y-component data, every 2 × 2 pixel sides
Battle array has a U component data and V component data, i.e. U, V component in the horizontal direction with all carry out two on vertical direction/
One extraction.In order to improve video compression efficiency, and consider the feature that human eye is low to the resolution of U, V component, these video pressures
YUV420 form is mainly compressed by contracting standard.Screen video, after the color space convert of RGB to YUV, can be adopted
Carry out compression coding with these compression standards, but add the mixing volume of entropy code owing to these compression standards use prediction to add conversion
Code framework, overall calculation complexity is very big, and can dramatically increase numeral KVM switcher realizes cost and computation delay, reduces aobvious
Show the response speed of picture.Additionally, these compression standards do not consider the feature of screen video, directly application will introduce easily quilt
The video quality loss that user discovers.
The video compression technology of numeral KVM switcher does not require nothing more than and reduces the data volume of video code flow, holding output video
Code stream steady, to improve the response speed of main control platform display picture, also requires the computation complexity of compression algorithm itself not
Can be too high, realize cost reducing algorithm.Chinese patent (proprietary term: the video compression system) profit of Patent No. 03816346.2
Video compress is carried out with the loss of the redundancy on computer screen and user acceptable video.Though the compression method of this patent
So computation complexity is relatively low, but it carries out the data compression of Pixel-level based on RGB color degree space, uses the fixed code of byte-aligned
Flow structure, overall compression efficiency is the highest, especially overall to the screen video scene compression efficiency of gradual change texture and complex texture
Relatively low.It addition, the compression method of this patent at video scene during simple textures picture is switched to complex texture picture
The video code flow transient data amount produced is excessive, network transmission can be caused to block up, have a strong impact on the sound of main control platform display picture
Answer speed.Chinese patent (the proprietary term: computor-keyboard, mouse and the transmission side of VGA screen signal of Patent No. 98120137.7
Method) utilize three kinds of video signals of VGA screen and additional transmission signal line, VGA screen signal is transmitted main control computer afield,
User is made can normally to operate object computer.This patent uses specific transmission line and host-host protocol to transmit screen video letter
Number, it is impossible to being transmitted on general digital network, it uses distance to be restricted.Patent No. 200610080828.8
Chinese patent (proprietary term: a kind of video-frequency compression method) realizes the flat of KVM video code flow by controlling the change of quantization parameter
Steady output, improves the response speed of KVM display picture.But the enforcement of this patent needs enterprising on existing video standard basis
OK, overall calculation complexity is higher, can substantially increase the process time delay of video compress and realize cost.Additionally, this patent
Video-frequency compression method, owing to needs carry out picture change detection to every frame and each macro block will be calculated quantization parameter, enters one
Step adds its computation complexity.
Summary of the invention
In order to overcome the overall transfer data volume of screen video data in numeral kvm system huge and complicated video scene
The problem that lower peak transmission data volume is excessive, the invention provides a kind of screen video compression method towards numeral KVM device,
Under limited computation complexity, screen video data are compressed, be effectively reduced screen video code stream overall data amount and
Peak-data amount, and keep good reconstruction video quality.
A kind of screen video compression method towards numeral KVM switcher, comprises the following steps:
(1) frame screen video data are inputted;
(2) frame originating point information of current video frame is write code stream;
(3) from current video frame, one uncoded chromatic component subframe of acquisition is as current chroma component sub-frame, to this
Subframe carries out data block division, and calculates total number of data block;
(4) from current chroma component sub-frame, a uncoded data block is obtained as current block;
(5) calculate current block coding information under each candidate coding pattern and rebuild data, and choosing final coding
Pattern and reconstruction data;
(6) according to the final coding mode of current block, the coding information of current block is write code stream;
(7) repeat step (4) to (6), complete coding and the reconstruction of all data blocks in current chroma component sub-frame;
(8) to current video frame written into code stream carry out bit padding to realize byte-aligned;
(9) repeat step (3) to (8), complete coding and the reconstruction of all chromatic component subframes in current video frame;
(10) code stream producing current video frame carries out frame synchronization head escape process, exports final compressed bit stream.
In step (1), described frame screen video data refer to that the frame that KVM switcher gathers uses YUV colourity
The screen video image in space, for the video compress of subsequent step.The pixel resolution of this two field picture is H0×V0, wherein H0
For the pixel number in horizontal resolution, i.e. horizontal direction, V0For the pixel in vertical resolution, i.e. vertical direction
Number.The concrete chrominance space form of the screen video data of support of the present invention is the one in YUV420, YUV422 and YUV444,
The each component data of Y, U and V represents with 8 bits, and each screen video frame is divided into three chromatic component subframes: all Y divide
Amount data composition H1×V1Two-dimensional data array, be designated as Y-component subframe, wherein H1Represent Y-component subframe in the horizontal direction
Data amount check, V1Represent the data amount check of Y-component subframe in the vertical direction;All U component datas composition H2×V2Two-dimemsional number
According to array, it is designated as U component sub-frame, wherein H2Represent U component sub-frame data amount check in the horizontal direction, V2Represent U component sub-frame
The data amount check of in the vertical direction;All V component data composition H3×V3Two-dimensional data array, be designated as V component subframe, its
Middle H3Represent V component subframe data amount check in the horizontal direction, V3Represent the data amount check of V component subframe in the vertical direction.
In these three YUV chrominance space form, the horizontal direction data amount check H of Y-component subframe1Divide equal to the level of current frame image
Resolution H0, the vertical direction data amount check V of Y-component subframe1Vertical resolution V equal to current frame image0;The water of U component sub-frame
Square to data amount check H2With vertical direction data amount check V2, the horizontal direction data amount check H of V component subframe3With vertical direction number
According to number V3, with H0、V0Between numerical relation be shown in Table 1.
Table 1
In step (2), described frame originating point information includes:
1) the frame synchronization leader of 4 byte representations knows SyncF, and first three byte value is 0xFF, and the 4th byte value is
0xFE, for the beginning of mark one frame code stream.SyncF must write code stream at byte-aligned, and must press byte order transmission
To decoding end, the higher bit position of each byte is first transmitted, and forms the bit stream of 4 byte representations (32 bits).SyncF writes
The value (being 0xFF) of first three byte of code stream is different from the value of last byte (0xFE), and this makes to write code stream prior to SyncF
Byte (belonging to former frame code stream) to be any numerical value form SyncF all without first three byte with SyncF, can avoid solving
The code end Wrong localization to frame head original position.
2) the resolution mark PicR of the present frame screen video image that 6 bits represent, its span is 1 to 24,
Represent 24 kinds of typical resolution in numeral kvm system, screen video image horizontal resolution H that each value is corresponding respectively0
With vertical resolution V0It is shown in Table 2, reserved 0,25 to 63 totally 40 numerical value.The PicR occurrence of write code stream is by actually entering screen
The resolution synopsis 2 of video image obtains.
Table 2
PicR | Horizontal resolution H<sub>0</sub> | Vertically resolution V<sub>0</sub> |
1 | 640 | 350 |
2 | 640 | 400 |
3 | 640 | 480 |
4 | 720 | 400 |
5 | 768 | 576 |
6 | 800 | 600 |
7 | 848 | 480 |
8 | 1024 | 768 |
9 | 1152 | 864 |
10 | 1280 | 720 |
11 | 1280 | 768 |
12 | 1280 | 800 |
13 | 1280 | 960 |
14 | 1280 | 1024 |
15 | 1360 | 768 |
16 | 1366 | 768 |
17 | 1440 | 900 |
18 | 1400 | 1050 |
19 | 1600 | 900 |
20 | 1600 | 1024 |
21 | 1600 | 1200 |
22 | 1680 | 1050 |
23 | 1920 | 1080 |
24 | 1920 | 1200 |
3) the chrominance space format identification (FID) ColorF that 3 bits represent, characterizes the colourity sky that current video frame specifically uses
Between form, be worth for 0b000 represent employing YUV420 form, be worth for 0b001 represent employing YUV422 form, be worth and represent for 0b010
Use YUV444 form, reserved 0b011 to 0b111.U and the V component data amount check of present frame employing YUV422 form are
The half of YUV444 form;Use the U of YUV420 form and half that V component data amount check is YUV422 form, be only
/ 4th of YUV444 form.Owing to human eye is relatively low to the resolution of U and V component data, YUV420 form is selected to have non-
Very close to the colourity well as subjective video quality of YUV422 and YUV444 form, YUV422 form is selected to have closer to YUV444 lattice
The colourity well as subjective video quality of formula.Therefore, the concrete value of ColorF can be according to numeral kvm system to colourity video quality and pressure
The demand of contracting ratio is chosen flexibly, the highest to colourity video quality demands, may select YUV444 form, requires compression ratio
Height then may select YUV420 form, is desirable that higher to colourity video quality and compression ratio, then may select YUV422 form.
4) the data block partition mode mark BP that 4 bits representMODE, characterize and each chromatic component subframe carried out data
The ultimate unit h that block dividesp×vp, i.e. horizontal direction master data number hpWith vertical direction master data number vp, BPMODEValue
Represent employing 4 × 4 partition mode for 0b0000, be worth and represent employing 8 × 4 partition mode for 0b0001, be worth and represent for 0b0010 and adopt
With 4 × 8 partition modes, it is worth and represents employing 8 × 8 partition mode for 0b0011, reserved 12 numerical value from 0b0100 to 0b1111.
The h of 4 × 4 partition modespEqual to 4, vpEqual to 4;The h of 8 × 4 partition modespEqual to 8, vpEqual to 4;The h of 4 × 8 partition modespDeng
In 4, vpEqual to 8;The h of 8 × 8 partition modespEqual to 8, vpEqual to 8.Use less block dividing mode can improve compression effect
Rate, but owing to block number increases, extra amount of calculation also can be increased.Therefore, numeral kvm system can be according to amount of calculation and pressure
The demand of contracting ratio selects BPMODEOccurrence, if requiring that amount of calculation is the least, then can be by BPMODEValue be set to 0b0011,
If requiring that compression ratio is the biggest, then can be by BPMODEValue be set to 0b0000, due to BP in the case of otherMODEBe set to 0b0001 or
0b0010 has the amount of calculation of same levels, can select occurrence according to the compression ratio size under typical case's application scenarios.
5) the inter prediction enable mark TP that 1 bit representsEN, its value is that 0b0 represents that the coding of present frame does not allows to make
With inter prediction, the reconstruction data of previous coded frame i.e. can not be used to predict current frame data, its value is that 0b1 represents present frame
Coding allow use inter prediction, i.e. allow use previous coded frame reconstruction data predict current frame data.TPENValue is
0b1 can be effectively improved the compression efficiency of present frame, but also makes the encoding code stream of present frame have time domain dependency.If present frame
Code stream lose or error code occur during transmitting, it will make reconstruction errors diffuse up in time domain side, until TP occursENValue
Till the frame of 0b0.TP in the present inventionENSetting there is following restriction: (a) present frame is the 1st coded frame, then TPENCan only
It is set to 0b0.B the resolution mark PicR of () current frame video image is different from former frame, then TPENIt may be only configured to 0b0.
C the chrominance space format identification (FID) ColorF of () present frame is different from former frame, then TPENIt may be only configured to 0b0.In other situation
Under, TP in present frameENValue can according to numeral kvm system application demand and the bit error rate situation of compression ratio are arranged.
It addition, regardless of TPENValue how to arrange, the present invention allows present frame to carry out spatial prediction, i.e. uses in present frame encoded
The reconstruction data of data predict the data to be encoded in present frame.
6) the frame level image quality mode PicQ that 2 bits represent, characterizes the subjective quality of present frame coding and rebuilding image
Grade, its value is that 0b00 represents lossless mode, is worth and represents for 0b01 and damage clear pattern, is worth and represents for 0b10 and damage equilibrium model
Formula, reserved 0b11;If present frame uses lossless mode, then its frame level quantization step QStep value is 1;If present frame uses and damages
Clear pattern, then its frame level quantization step QStep value is 2;If present frame uses and damages balanced mode, then its frame level quantization step
It is 4 for QStep value.The value of QStep is the biggest, and quantization error is the biggest, and the QStep damaging balanced mode is damage clear pattern two
Times, rebuild image definition just poorer than damaging clear pattern.QStep will be used in subsequent step the prediction residual amount of carrying out
Changing and inverse quantization, quantify and the computational efficiency of inverse quantization to promote prediction residual, the QStep value of the present invention is all the power of 2,
So quantify all to be converted to shift operation with the division in de-quantization process and multiplying.In the present invention, present frame frame level quantifies
Shift amount shift takes the logarithm by 2 the integer obtained equal to QStep.When QStep value is 1, then shift value is 0;When QStep value
Be 2, then shift value is 1;When QStep value is 4, then shift value is 2;By the present invention in that and carry out shifting realizing with shift
Prediction residual is quantified and inverse quantization.In order to ensure the gross of video image, in the present invention, the maximum of QStep is only
To 4.
7) the FrameN value of FrameN: the first coded frame of frame number that 16 bits represent is set to 0, follow-up every frame
FrameN adds 1 equal to the FrameN of its former frame, when FrameN value is more than 65535, then it is set to 0 again.
For the ease of number of bits and the description of numerical value, in the present invention, 0b is the prefix of binary mode numeric representation, its
After numeral be binary numeral, write code stream coding information value can use other system mode to represent equally, such as ten enter
System and hexadecimal, it is impossible to limit protection scope of the present invention to represent only with binary mode.
In step (2), frame originating point information writes code stream in the following order:
(2-1) at byte-aligned, write frame sync identifications SyncF of 4 bytes;
(2-2) the resolution mark PicR of write present frame screen video image;
(2-3) write chrominance space format identification (FID) ColorF;
(2-4) writing data blocks partition mode mark BPMODE;
(2-5) write inter prediction enables mark TPEN;
(2-6) write frame level image quality mode PicQ;
(2-7) the frame number FrameN of present frame is write.
Further, in step (2), each numerical value be its higher bit position first write code stream (i.e. first pass through network pass
Deliver to decoding end), write code stream behind low bit position;All reserved numerical value, in an encoding process all without use, both can improve
The decoding end error detecing capability to preamble bitstream, the most also the follow-up semantic extension for the present invention provides space.
In step (3), specifically comprise the following steps that
(3-1) first obtain a uncoded colourity by the order of Y-component subframe, U component sub-frame, V component subframe to divide
Quantum frame is as current chroma component sub-frame, HkAnd VkBe respectively current chroma component sub-frame in the horizontal direction with on vertical direction
Data amount check, k is the index of current chroma component sub-frame, and k value is 1 expression Y-component subframe, and k value is 2 expression U component sub-frame,
K value is 3 expression V component subframes;
(3-2) then according to the BP in step (2)MODEObtain data block and divide ultimate unit hP×vP, hPFor horizontal direction
The data amount check divided, vPThe data amount check divided for vertical direction;
(3-3) then ultimate unit h is divided according to data blockP×vPBy the order of raster scanning by current chroma component
Frame is divided into the two-dimensional rectangle data block to be encoded of multiple h × v size, and h is data block data amount check in the horizontal direction,
V is the data amount check of data block in the vertical direction;For not comprising the data block of right margin, h value is BP in step (2)MODE
Corresponding hp;For not comprising the data block of lower boundary, v is BP in step (2)MODECorresponding vp;For comprising the number of right margin
According to block, if the horizontal direction data amount check H of current chroma component sub-framekCan be by hpDivide exactly, then h value is hp, otherwise h value is HkExcept hp
The remainder obtained;For comprising the data block of lower boundary, if the vertical direction data amount check V of current chroma component sub-framekCan be by vp
Divide exactly, then v value is vp, otherwise v value is VkExcept vpThe remainder obtained;
(3-4) data block number H of current chroma component sub-frame horizontal direction finally it is calculated by formula (1)blk, press
Formula (2) is calculated data block number V of current chroma component sub-frame vertical directionblk, it is calculated currently by formula (3)
Total number N of data block of chromatic component subframeblk。
Nblk=Hblk×Vblk (3)
In step (3), the order of described raster scanning is conventional the starting from a left side from the upper left corner of field of video compression
The order traveled through is carried out from top to bottom to the right side.
In step (4), from current chroma component sub-frame, obtain h × v size not by the order of raster scanning
Coding two-dimensional rectangle data block is as current block.
In step (5), described candidate coding pattern includes:
1) interframe associative mode (IC_MODE):
In the present invention, current block selects IC_MODE to have two conditions as its effective candidate coding pattern, wherein first
Condition is: present frame enables mark TP written into the inter prediction of code streamENValue is 0b1, i.e. allows to use the weight of previous coded frame
Build data prediction current frame data.
Using this pattern to encode, the coding information of current block and reconstruction data are calculated as follows obtaining:
For each initial data P in current block, its predictive value PredICFor identical chromatic component in previous coded frame
The reconstruction data of frame and same spatial location, its prediction residual DICBe calculated by formula (4), prediction residual symbol SignICPress
Formula (5) is calculated, quantifies residual error QDICIt is calculated by formula (6), formula (7) and formula (8), is rebuild data RICBy public affairs
Formula (9) is calculated.
DIC=P-PredIC (4)
In formula (5), SignICValue be the symbol of 0 expression prediction residual for just, value is the symbol of 1 expression prediction residual
It is negative.In formula (6), QDIC TmpQuantify residual error for IC_MODE temporarily, > > symbol represents shift right operation, | DIC| represent DIC
Take absolute value, | DIC| the half (i.e. QStep2 > > 1) plus QStep2 is to round up final quantization result;For
Improving the quantified precision of IC_MODE prediction residual amplitude, what the present invention used in formula (6) halves quantization step QStep2
Being calculated by formula (8), if QStep is more than 1, then QStep2 value is the half of frame level quantization step QStep, if QStep etc.
In 1, then QStep2 value is 1;Halve shift amount shift2 to be taken the logarithm by 2 by QStep2 and be calculated, be i.e. 1 when QStep2 value
Time, the value of shift2 is 0, and when QStep2 value is 2, the value of shift2 is 1.In formula (7), in order to improve frame level figure picture element
Amount, for damaging the compression efficiency of static scene in the case of balanced mode, works as QDICValue is 1 and QStep2 value when being 2, by QDICBy force
System is set to 0, is the number of zero to increase quantization residual error in current block, improves subsequent compression efficiency, QD in the case of otherICKeep not
Become.In formula (9), < < symbol represents that shift left operation, min () are to take the smaller value function of two input data, and max () is for taking
Two input data higher value functions, with guarantee rebuild data between 0 to 255, i.e. in the range of 8 bits represent.For
Avoid quantifying and the division in de-quantization process and multiplying, the present invention in the quantization operations of formula (6) with moving right
Position replaces division, replaces multiplication by shifted left in the inverse quantization computing of formula (9).
In order to enable decoding end to rebuild each data of current block by formula (9), first the present invention would indicate that IC_MODE
Coding mode mark ModeIDICEnrolling code stream, represent with 2 bits, its value is 0b00, enables decoding end according to coding mode
Mark obtains the coding mode of current block, and then obtains PredICTo realize rebuilding.
Then according to all QD of current blockICIn maximum QDIC maxEach QD is calculated by formula (10)ICEnroll code stream
Number of bits QDBitsIC.In formula (10), work as QDIC maxValue is 0, shows all QD of current blockICValue is all 0, then without disappearing
The each QD of loss-rate spy's actual codingIC, the present invention is by QDBitsICValue be set to 0;Work as QDIC maxMore than 0, then all QD of current blockIC
Value is in the range of [0, QDIC max], each QDICAt least useIndividual bit represents, in order to reduce QD as far as possibleIC's
Number of coded bits, the present invention is by QDBitsICValue be set to minimum
Then according to calculated QDBitsICThe stand growth model mark AZFlag that 1 bit is representedICEnroll code stream: when
QDBitsICValue is equal to 0, then by AZFlagICValue is set to 0b1, represents the QD of current blockICIt is all zero, need not be by QDBitsICEnroll
Code stream;Work as QDBitsICValue is more than 0, then by AZFlagICValue is set to 0b0, represents that current block exists non-zero QDIC, must be by QDBitsIC
Enroll code stream.In order to reduce number of coded bits and in view of QDBitsICTypical ranges, the unified restriction of the present invention only uses 3 bits
By QDBitsICEnroll code stream, QDBitsICAllow in the range of [0,7].
Therefore, in the present invention, current block selects the IC_MODE as second condition of its effective candidate coding pattern to be
QDBitsICIt is not more than 7.Work as QDBitsICMore than 7, then cannot be enrolled code stream with 3 bits, IC_MODE in this case
The final coding mode of current block cannot be become, be not the most effective candidate coding pattern of current block, after this pattern must being terminated
Continuous calculating.It is in the case of 1 (shift2 value is 0, does not shifts) that this situation only appears in QStep2 value, and owing to regarding
Frequency evidence has the strongest dependency, major part QD in time domainICValue be both less than 128, can be in the range of the expression of 7 bits.
Finally according to QDBitsICSign to each data in two kinds of situationICAnd QDICEncode:
A () works as QDBitsICValue is more than 0, and current block exists non-zero QDIC, then by all of for current block QDICAnd SignICAll compile
Enter code stream, the most each SignICRepresent with 1 bit, each QDICUse QDBitsICIndividual bit represents.
B () works as QDBitsICValue is equal to 0, the QD of current blockICBe all zero, i.e. current block is that IC_MODE quantifies residual error complete zero
Block, then SignICDo not affect the reconstructed results of formula (9), all Sign in current blockICAnd QDICAll need not enroll code stream.For
Improving the code efficiency of still frame scene, support of the present invention is to multiple continuous print QDICStand growth model carries out Unified coding.Therefore
The present invention is then written to the consecutive identical monodrome block identification ContiFlag that 1 bit representsIC, its value is 0b0, represents only complete to 1
Zero piece encodes, and terminates the coding of current block;Its value is that 0b1 represents the continuous QD started from current blockICStand growth model (its
Number is designated as ContiCntIC, its value is more than 1) and carry out Unified coding.The present invention is by ContiCntICValue after subtracting 1 is used
ContiCntBitsICIndividual bit represents and enrolls code stream.In order to reduce ContiCntICNumber of coded bits, the present invention presses formula
(11) four kinds of situations are divided to be calculated ContiCntBitsIC, ContiCntBits in the case of first threeICIt is all ContiCntIC
Corresponding higher limit is taken the logarithm by 2 and is obtained, and last a kind of situation is NblkRound up after taking the logarithm by 2 and obtain.In formula (11)
In, NblkFor the data block number of current chroma component sub-frame, it is calculated by step (3).In order to enable decoding end correct
Resolve ContiCntIC, enrolling ContiCntICBefore must be first by ContiCntBitsICIdentification information enroll code stream.In order to
Reduce ContiCntBitsICNumber of coded bits, and in view of ContiCntBitsICValue only have four kinds of situations, the present invention is only
With 2 bits by ContiCntBitsICCode identification (be designated as ContiCntBitsIdxIC) enroll code stream,
ContiCntBitsIdxICWith ContiCntBitsICCorresponding relation such as formula (12) shown in.
According to encoding information above, the continuous blocks using IC_MODE to start current block or current block carry out coding and consume
Number of coded bits CBitsICIt is calculated by formula (13).
2) monodrome raw mode (SO_MODE):
In the present invention, current block selects SO_MODE as its effective candidate coding pattern only one of which condition: current block is
The all data of monodrome block, i.e. current block are the most equal, are all monodrome P of current blockS。
Using this pattern to encode, coding side must be by the pattern information of SO_MODE and PSInformation enrolls code stream.In order to carry
High this pattern of employing carries out the picture quality encoded, and this pattern is not to PSQuantifying, coding mode is the data block of SO_MODE
Reconstruction data be all PS.Using this pattern to carry out the compression efficiency encoded to improve, this pattern is by PSEnroll the mode of code stream
Have two kinds: (a) directly with 8 bits by PSEnroll code stream;B () is also SO_MODE when the coding mode of the adjacent upper block in space
And its PSP with current blockSEqual, then need not PSEnrolling code stream, decoding end can obtain P from decoded upper blockS。
In order to improve the compression efficiency using this pattern, support of the present invention consecutive identical monodrome block (its number to starting from current block
It is designated as ContiCntSO, its value is more than 1) and carry out Unified coding.
In order to make decoding end be obtained in that the reconstruction data of the continuous blocks headed by the reconstruction data of current block or current block, this
It is as follows that the code stream that invention uses SO_MODE to carry out encoding enrolls mode: first the coding mode of SO_MODE is identified by (a)
ModeIDSOEnrolling code stream, 2 bits represent, are worth for 0b01.B monodrome coded system that then 1 bit is represented by ()
CodPsFlagSOEnrolling code stream, its value is monodrome P that coding mode is SO_MODE and top that 0b0 represents upper blockSWith currently
Monodrome P of blockSEqual, monodrome P of current blockSNot enrolling code stream, decoding end is by obtaining P from upper blockSRealize current block
Data reconstruction, its value is that 0b1 represents monodrome P represented by 8 bitsSEnrolling code stream, decoding end obtains P by resolving code streamSCome real
The data reconstruction of existing current block.C consecutive identical monodrome block identification ContiFlag that 1 bit is represented by () againSOEnroll code stream, when
ContiFlagSOValue be 0b0, represent that only current block enrolls code stream, terminates the coding of current block;Work as ContiFlagSOValue
For 0b1, represent the continuous ContiCnt headed by current blockSOIndividual block uses SO_MODE to carry out encoding and P between each blockS
Equal, then by ContiCntSOValue ContiCntBits after subtracting 1SOIndividual bit represents and enrolls code stream.In order to reduce
ContiCntSOThe number of coded bits subtracting 1, the present invention is according to ContiCntSOCalculate by four kinds of situations of formula (14) point
ContiCntBitsSO, ContiCntBits in the case of first threeSOIt is all ContiCntSOCorresponding higher limit is taken the logarithm by 2
Obtaining, last a kind of situation is NblkRound up after taking the logarithm by 2 and obtain.In order to enable decoding end correctly to resolve
ContiCntSO, enrolling ContiCntSOMust be first by ContiCntBits before subtracting 1SOCoding information enroll code stream.In order to subtract
Little ContiCntBitsSONumber of coded bits, and in view of ContiCntBitsSOValue only have four kinds of situations, the present invention only uses
2 bits are by ContiCntBitsSOCode identification (be designated as ContiCntBitsIdxSO) enroll code stream,
ContiCntBitsIdxSOWith ContiCntBitsSOCorresponding relation such as formula (15) shown in.
According to encoding information above, the continuous blocks using SO_MODE to start current block or current block carry out coding and consume
Number of coded bits CBitsSOIt is calculated by formula (16).
CBitsSO=2+1+8 × CodPsFlagSO+1+ContiFlagSO×(2+ContiCntBitsSO) (16)
3) horizontal pointwise pattern (HP_MODE):
HP_MODE uses the reconstruction data of adjacent position on the left of horizontal direction to carry out prediction point-by point, and enters prediction residual
Row shift quantization, displacement inverse quantization and reconstruction: to each initial data P in current block, when P is in current chroma component sub-frame
Left margin, then the predictive value Pred of PHPIt is set to 128, otherwise PredHPIt is all reconstruction data R of adjacent left-hand position, P spaceL;P
Prediction residual DHPBe calculated by formula (17), prediction residual symbol SignHPIt is calculated by formula (18), is quantified residual error
QDHPIt is calculated by formula (19), is rebuild data RHPIt is calculated by formula (20).
DHP=P-PredHP (17)
QDHP=(| DHP|+(QStep > > 1)) > > shift (19)
In order to allow decoding end can rebuild each data of current block by formula (20), coding side first must be by HP_MODE
Coding mode mark ModeIDHPEnroll code stream, ModeID in the present inventionHPRepresent with 3 bits, be worth for 0b100.Decoding end exists
After resolving the coding mode mark ModeID that code stream obtains current block, when ModeID value is ModeIDHP, then explanation current block uses
HP_MODE encodes, and then obtains each Pred of current blockHP。
Maximum quantization residual error QD then according to current blockHP maxEach QD is calculated by formula (21)HPEnroll the bit of code stream
Number QDBitsHP.In formula (21), work as QDHP maxEqual to 0, show all QD of current blockHPBe all 0, i.e. current block is HP_MODE
Quantify residual error stand growth model, then without consuming each QD of bits of encodedHP, the present invention is by QDBitsHPIt is set to 0;Work as QDHP maxMore than 0,
The then all QD of current blockHPIn the range of [0, QDHP max], each QDHPAt least useIndividual bit represents, this
Bright by QDBitsHPIt is set toIn order to reduce code stream bit number and in view of QDBitsHPTypical ranges,
The QDBits that the present invention will only represent with 3 bitsHPEnroll code stream, QDBitsHPAllow in the range of [0,7].
Therefore, in the present invention, current block selects the HP_MODE as the unique conditional of its effective candidate coding pattern to be:
QDBitsHPIt is not more than 7.Work as QDBitsHPMore than 7, then cannot be enrolled code stream with 3 bits, HP_MODE in this case
The final coding mode of current block cannot be become, be not the most effective candidate coding pattern of current block, after this pattern must being terminated
Continuous calculating.
Finally according to QDBitsHPSign by each dataHPAnd QDHPEnroll code stream: work as QDBitsHPEqual to 0, show to work as
The QD of front pieceHPIt is all 0, SignHPDo not affect the reconstructed results of formula (20), therefore all Sign in current blockHPAnd QDHPThe most not
Need to enroll code stream;Work as QDBitsHPMore than 0, show that current block exists certain QDHPMore than 0, the present invention is all of by current block
QDHPAnd SignHPAll enroll code stream, the most each SignHPAll with 1 bit represent, each QDHPAll use QDBitsHPIndividual bit table
Show.
According to encoding information above, use HP_MODE that current block carries out number of coded bits CBits that coding consumesHPPress
Formula (22) is calculated.
4) vertical pointwise pattern (VP_MODE):
VP_MODE uses the reconstruction data of adjacent position above vertical direction to carry out prediction point-by point, and enters prediction residual
Row shift quantization, displacement inverse quantization and reconstruction: to each initial data P in current block, when P is in current chroma component sub-frame
Coboundary, then the predictive value Pred of PVPIt is set to 128, otherwise PredVPIt is all reconstruction data R of position adjacent and above, P spaceU;P
Prediction residual DVPBe calculated by formula (23), prediction residual symbol SignVPIt is calculated by formula (24), is quantified residual error
QDVPIt is calculated by formula (25), is rebuild data RVPIt is calculated by formula (26).
DVP=P-PredVP (23)
QDVP=(| DVP|+(QStep > > 1)) > > shift (25)
In order to allow decoding end can rebuild each data of current block by formula (26), coding side first must be by VP_MODE
Coding mode mark ModeIDVPEnroll code stream, ModeID in the present inventionVPRepresent with 3 bits, be worth for 0b101.Decoding end exists
After resolving the coding mode mark ModeID that code stream obtains current block, when ModeID value is ModeIDVP, then explanation current block uses
VP_MODE encodes, and then obtains each Pred of current blockVP。
Maximum quantization residual error QD then according to current blockVP maxEach QD is calculated by formula (27)VPEnroll the bit of code stream
Number QDBitsVP.In formula (27), work as QDVP maxEqual to 0, show all QD of current blockVPValue is all 0, i.e. current block is VP_
MODE quantifies residual error stand growth model, then without consuming each QD of bits of encodedVP, the present invention is by QDBitsVPIt is set to 0;Work as QDVP maxGreatly
In 0, then all QD of current blockVPIn the range of [0, QDVP max], each QDVPAt least useIndividual bit represents,
The present invention is by QDBitsVPIt is set toIn order to reduce code stream bit number and in view of QDBitsVPCommon model
Enclose, the QDBits that the present invention will only represent with 3 bitsVPEnroll code stream, QDBitsVPAllow in the range of [0,7].
Therefore, in the present invention, current block selects the VP_MODE as the unique conditional of its effective candidate coding pattern to be:
QDBitsVPIt is not more than 7.Work as QDBitsVPMore than 7, then cannot be enrolled code stream with 3 bits, VP_MODE in this case
The final coding mode of current block cannot be become, be not the most effective candidate coding pattern of current block, after this pattern must being terminated
Continuous calculating.
Finally according to QDBitsVPSign by each dataVPAnd QDVPEnroll code stream: work as QDBitsVPEqual to 0, show to work as
The QD of front pieceVPIt is all 0, SignVPDo not affect the reconstructed results of formula (26), now all Sign in current blockVPAnd QDVPThe most not
Need to enroll code stream;Work as QDBitsVPMore than 0, show that current block exists certain QDVPMore than 0, therefore the present invention is by current block institute
Some QDVPAnd SignVPAll enroll code stream, the most each SignVPAll with 1 bit represent, each QDVPAll use QDBitsVPIndividual ratio
Special expression.
According to encoding information above, use VP_MODE that current block carries out number of coded bits CBits that coding consumesVPPress
Formula (28) is calculated.
5) level of complexity pattern (CH_MODE):
Using this pattern to encode, each row of data of current block has two kinds of optional coded systems: horizontal forecast quantization side
Formula and direct quantification manner.
In all data row using horizontal forecast quantification manner, use the reconstruction number of adjacent position on the left of horizontal direction
According to carrying out prediction point-by point, and prediction residual is carried out shift quantization, displacement inverse quantization and reconstruction: each original in current line
Data P, when P is in the left margin of current chroma component sub-frame, then the predictive value Pred of PCHIt is set to 128, otherwise PredCHIt is all P
Reconstruction data R of adjacent left-hand position, spaceL;Prediction residual D of PCHBe calculated by formula (29), prediction residual symbol
SignCHIt is calculated by formula (30), is quantified residual error QDCHIt is calculated by formula (31), is rebuild data RCHBased on formula (32)
Obtain.
DCH=P-PredCH (29)
QDCH=(| DCH|+(QStep > > 1)) > > shift (31)
In all data row using direct quantification manner, do not carry out any prediction, each original number to current line
According to P, directly press formula (33) and calculate quantized data QPCH, and press reconstruction data R of formula (34) calculating PCH。
QPCH=(P+ (QStep > > 1)) > > shift (33)
RCH=QPCH< < shift (34)
In order to enable decoding end to rebuild all data row of current block by formula (32) or (34), first the present invention will
The coding mode mark ModeID of CH_MODECHEnroll code stream, represent with 4 bits, be worth for 0b1100.Then press from top to bottom
Coded system RowMode that order will often be goneCHEnroll code stream, each RowModeCHRepresenting with 1 bit, (v is for working as v bit altogether
The data amount check of front piece of in the vertical direction, is the number of data lines of current block).The RowMode of current lineCHValue represents for 0b0
Current line uses the coded system that horizontal forecast quantifies, and its value is that 0b1 represents that current line uses the coded system directly quantified.
Then the data row of the data row and direct quantification manner that use horizontal forecast quantification manner is encoded respectively:
In all data row using horizontal forecast quantification manner, in order to enable decoding end to rebuild number by formula (32)
According to, coding side must be by QD all in current blockCHAnd SignCHInformation enroll code stream: the present invention is first from all QD of current blockCHIn
Select maximum QDCH max, then calculate each QD by formula (35)CHEnroll the bit number QDBits of code streamCH.In formula (35),
Work as QDCH maxEqual to 0, show all of QD of current blockCHBe all 0, i.e. current block be CH_MODE quantify residual error stand growth model, then without
Consume bit and encode QDCH, the present invention is by QDBitsCHIt is set to 0;Work as QDCH maxMore than 0, then all QD of current blockCHScope district
Between be [0, QDCH max], each QDCHAt least useIndividual bit represents, the present invention is by QDBitsCHIt is set toIn order to reduce QDBitsCHEncoding code stream bit number, the present invention will only represent with 3 bits
QDBitsCHEnroll code stream, QDBitsCHAllowed band be [0,7], corresponding QDCHAllowed band be [0,127].
Therefore, in the present invention, current block selects the CH_MODE as the unique conditional of its effective candidate coding pattern to be:
QDBitsCHIt is not more than 7.Work as QDBitsCH(QD is i.e. there is more than 7CHMore than 127), then cannot be enrolled code stream with 3 bits,
In this case CH_MODE cannot become the final coding mode of current block, is not the most effective candidate coding pattern of current block,
The subsequent calculations of this pattern must be terminated.To often going, when it exists QD of employing horizontal forecast quantification mannerCHMore than 127, then this row
Using horizontal forecast quantification manner is not effective candidate coding pattern of current block by causing CH_MODE.In this case, when
The coded system of current line can be changed into another kind of directly quantification manner by front piece, it is to avoid calculated by formula (35)
QDBitsCHScope beyond [0,7].
In all data row using direct quantification manner, in order to enable decoding end to rebuild data by formula (34),
Coding side must be by all for current block QPCHEnrolling code stream, the present invention is by each QPCHAll use QPBitsCHIndividual bit represents and enrolls code
Stream.Owing to P is to represent with 8 bits, the QP that P obtains after formula (33) shift quantizationCHOnly need to subtract shift bit table with 8
Show and get final product (shift is that frame level quantifies shift amount), therefore QPBits in the present inventionCHIt is calculated by formula (36).At formula
(36) in, QPBitsCHCalculating only the most relevant with shift, all of QPBits of present frameCHThe most equal.Decoding end can first pass through
Frame level image quality mode PicQ in frame originating point information obtains shift, then is calculated QPBits by formula (36)CH.Therefore, for
Minimizing number of coded bits, the present invention is by the QPBits of current blockCHEnroll code stream.
QPBitsCH=8-shift (36)
The present invention is with specific reference to RowMode in current blockCHValue is line number n and the QDBits of 0b1CHThree kinds of situations are divided to incite somebody to action
Coding information (the QP of each dataCH、QDCHAnd SignCH) enroll code stream:
I. when n value is equal to line number v of current block, then all data of current block all use direct quantification manner, only need by
Each QPCHAll use QPBitsCHIndividual bit enrolls code stream, it is not necessary to by QDBitsCH、QDCHAnd SignCHEnroll code stream.
Ii. it is less than line number v and the QDBits of current block when n valueCHDuring equal to 0, all of QD of current blockCHIt is all 0, SignCH
Do not affect R in formula (32)CHCalculating, therefore without by SignCHAnd QDCHEnroll code stream.In this case, the present invention is first
The QDBits that 3 bits are representedCHEnroll code stream, then by each QPCHAll use QPBitsCHIndividual bit enrolls code stream.
Iii., in the case of other, n value is less than line number v of current block, QDBitsCHMore than 0 and less than or equal to 7, need institute
Some SignCHAnd QDCHEnroll code stream.In this case, the QDBits that 3 bits are first represented by the present inventionCHEnroll code stream, then will
Each SignCHAll enroll code stream, by each QD with 1 bitCHAll use QDBitsCHIndividual bit enrolls code stream, finally by each
QPCHAll use QPBitsCHIndividual bit enrolls code stream.
According to encoding information above, use CH_MODE that current block carries out number of coded bits CBits that coding consumesCHPress
Formula (37) is calculated:
6) complicated vertically pattern (CV_MODE):
Using this pattern to encode, every column data of current block has two kinds of optional coded systems: vertically predict quantization side
Formula and direct quantification manner.
In all data row using vertically prediction quantification manner, which uses adjacent position above vertical direction
Rebuild data and carry out prediction point-by point, and prediction residual is carried out shift quantization, displacement inverse quantization and reconstruction: every to when in prostatitis
Individual initial data P, when P is in the coboundary of current chroma component sub-frame, then the predictive value Pred of PCVIt is 128, otherwise PredCV
It is all reconstruction data R of position adjacent and above, P spaceU;Prediction residual D of PCVBe calculated by formula (38), prediction residual accords with
Number SignCVIt is calculated by formula (39), is quantified residual error QDCVIt is calculated by formula (40), is rebuild data RCVBy formula (41)
It is calculated.
DCV=P-PredCV (38)
QDCV=(| DCV|+(QStep > > 1)) > > shift (40)
In all data row using direct quantification manner, do not carry out any prediction, to when each original number in prostatitis
According to P, directly press formula (42) and calculate quantized data QPCV, and press reconstruction data R of formula (43) calculating PCV。
QPCV=(P+ (QStep > > 1)) > > shift (42)
RCV=QPCV< < shift (43)
In order to enable decoding end to rebuild all data row of current block by formula (41) or (43), the present invention is first by table
Show the coding mode mark ModeID of CV_MODECVEnroll code stream, represent with 4 bits, be worth for 0b1101.Press again from left to right
Order is by coded system ColMode of each columnCVEnroll code stream, each ColModeCVRepresenting with 1 bit, (h is for working as h bit altogether
Front piece of data amount check in the horizontal direction, is the data columns of current block).ColModeCVValue represents when prostatitis is adopted for 0b0
By the coded system that vertically prediction quantifies, its value is that 0b1 represents when prostatitis uses the coded system directly quantified.
Then the data row of the data row and direct quantification manner that use vertical prediction quantification manner are encoded respectively:
In all data row using vertically prediction quantification manner, in order to enable decoding end to rebuild number by formula (41)
According to, coding side must be by all for current block QDCVAnd SignCVInformation enroll code stream: the present invention is first from all QD of current blockCVMiddle choosing
Go out maximum QDCV max, then calculate each QD by formula (44)CVEnroll the bit number QDBits of code streamCV.In formula (44), when
QDCV maxEqual to 0, show all of QD of current blockCVBe all 0, i.e. current block is that CV_MODE quantifies residual error stand growth model, then without disappearing
Loss-rate spy encodes QDCV, the present invention is by QDBitsCVIt is set to 0;Work as QDCV maxMore than 0, then all QD of current blockCVRange intervals
For [0, QDCV max], each QDCVAt least useIndividual bit represents, the present invention is by QDBitsCVIt is set toIn order to reduce QDBitsCVEncoding code stream bit number, the present invention will only represent with 3 bits
QDBitsCVEnroll code stream, QDBitsCVAllowed band be [0,7], corresponding QDCVAllowed band be [0,127].
Therefore, in the present invention, current block selects the CV_MODE as the unique conditional of its effective candidate coding pattern to be:
QDBitsCVIt is not more than 7.Work as QDBitsCV(QD is i.e. there is more than 7CVMore than 127), then cannot be enrolled code stream with 3 bits,
In this case CV_MODE cannot become the final coding mode of current block, is not the most effective candidate coding pattern of current block,
The subsequent calculations of this pattern must be terminated.Each column to the vertical prediction quantification manner of employing, when it exists QDCVMore than 127, then these row
Using vertical prediction quantification manner is not effective candidate coding pattern of current block by causing CV_MODE.In this case, when
Front piece can will change another kind of directly quantification manner into when the coded system in prostatitis, it is to avoid calculated by formula (44)
QDBitsCVScope beyond [0,7].
In all data row using direct quantification manner, in order to enable decoding end to rebuild data by formula (43),
Coding side must be by all for current block QPCVEnrolling code stream, the present invention is by each QPCVAll use QPBitsCVIndividual bit represents.Owing to P is
Represent with 8 bits, the QP that P obtains after formula (42) shift quantizationCVOnly need to subtract shift bit with 8 to represent
(shift is that frame level quantifies shift amount), therefore QPBits in the present inventionCVIt is calculated by formula (45).In formula (45),
QPBitsCVCalculating only the most relevant with shift, all of QPBits of present frameCVThe most equal.Decoding end can first pass through frame head letter
Frame level image quality mode PicQ in breath obtains shift, then is calculated QPBits by formula (45)CV.Therefore, in order to reduce
Number of coded bits, the present invention is not by the QPBits of current blockCVEnroll code stream.
QPBitsCV=8-shift (45)
Then according to ColMode in current blockCVValue is columns m and QDBits of 0b1CVDivide three kinds of situations by every number
According to coding information (QPCV、QDCVAnd SignCV) enroll code stream, specific as follows:
I., when m value is equal to the columns h of current block, all data of current block all use direct quantification manner, do not have
QDBitsCV、QDCVAnd SignCV, only need to be by each QPCVAll use QPBitsCVIndividual bit enrolls code stream.
Ii. when m value is less than columns h and QDBits of current blockCVDuring equal to 0, due to all of QD of current blockCVIt is all 0,
SignCVDo not affect R in formula (41)CVCalculating, therefore without by SignCVAnd QDCVEnroll code stream.In this case, this
The bright QDBits first 3 bits representedCVEnroll code stream, then by each QPCVAll use QPBitsCVIndividual bit enrolls code stream.
Iii., in the case of other, m value is less than columns h, QDBits of current blockCVMore than 0 and less than or equal to 7, need by
SignCVAnd QDCVActual enroll code stream.In this case, the QDBits that 3 bits are first represented by the present inventionCVEnroll code stream, then
By each SignCVAll enroll code stream, by each QD with 1 bitCVAll use QDBitsCVIndividual bit enrolls code stream, finally by each
QPCVAll use QPBitsCVIndividual bit enrolls code stream.
According to encoding information above, use CH_MODE that current block carries out number of coded bits CBits that coding consumesCVPress
Formula (46) is calculated:
7) self adaptation pointwise pattern (AP_MODE):
In the present invention, current block selects AP_MODE to have two conditions as its effective candidate coding pattern, wherein first
Condition is: current block does not comprise coboundary data and the left margin data of current chroma component sub-frame.
This pattern is used to encode, to each initial data P in current block, its predictive value PredAPBy formula (47)
It is calculated.In formula (47), RLThe reconstruction data of adjacent left-hand position, space, R for PUSpace for P weighs adjacent and above
Build data, RULReconstruction data for the adjacent top-left position in space of P.Work as RULWith RUDifference amplitude less than or equal to RULWith RLDifference
Different amplitude, then show that the horizontal direction dependency rebuilding data is more than vertical direction dependency, and the present invention is by RLPrediction as P
Value, otherwise shows that the vertical direction dependency rebuilding data is more than horizontal direction dependency, and the present invention is by RUPrediction as P
Value.Prediction residual D of PAPBe calculated by formula (48), prediction residual symbol is calculated by formula (49), is quantified residual error
QDAPIt is calculated by formula (50), is rebuild data RAPIt is calculated by formula (51).
DAP=P-PredAP (48)
QDAP=(| DAP|+(QStep > > 1)) > > shift (50)
In order to enable decoding end to rebuild each data of current block by formula (51), first must be by the coding of AP_MODE
Pattern identification ModeIDAPEnroll code stream, ModeID in the present inventionAPRepresent with 4 bits, be worth for 0b1110.Decoding end is resolving code
After stream obtains the coding mode mark ModeID of current block, when ModeID value is ModeIDAP, then explanation current block uses AP_
MODE encodes, and then obtains each Pred of current blockAP。
Maximum quantization residual error QD then according to current blockAP maxEach QD is calculated by formula (52)APEnroll the bit of code stream
Number QDBitsAP.In formula (52), work as QDAP maxEqual to 0, show all QD of current blockAPBe all 0, i.e. current block is AP_MODE
Quantify residual error stand growth model, then without consuming each QD of bits of encodedAP, the present invention is by QDBitsAPIt is set to 0;Work as QDAP maxMore than 0,
The then all QD of current blockAPIn the range of [0, QDAP max], each QDAPAt least useIndividual bit represents, this
Bright by QDBitsAPIt is set toIn order to reduce code stream bit number and in view of QDBitsAPTypical ranges,
The QDBits that the present invention will only represent with 3 bitsAPEnroll code stream, QDBitsAPAllowed band be [0,7].
Therefore, in the present invention, current block selects the AP_MODE as second condition of its effective candidate coding pattern to be:
QDBitsAPIt is not more than 7.Work as QDBitsAPMore than 7, then cannot be enrolled code stream with 3 bits, AP_MODE in this case
The final coding mode of current block cannot be become, be not the most effective candidate coding pattern of current block, after this pattern must being terminated
Continuous calculating.
Finally according to QDBitsAPSign by each dataAPAnd QDAPEnroll code stream: work as QDBitsAPEqual to 0, show to work as
The QD of front pieceAPIt is all 0, SignAPDo not affect the reconstructed results of formula (51), therefore all Sign in current blockAPAnd QDAPThe most not
Need to enroll code stream;Work as QDBitsAPMore than 0, show that current block exists QDAPMore than 0, therefore the present invention is all of by current block
SignAPAnd QDAPAll enroll code stream, wherein SignAPWith 1 bit represent, QDAPUse QDBitsAPIndividual bit represents.
According to encoding information above, use AP_MODE that current block carries out number of coded bits CBits that coding consumesAPPress
Formula (53) is calculated.
8) direct quantitative mode (DQ_MODE):
All data blocks can select this pattern as its effective candidate coding pattern.This pattern is compiled according to present frame
Enter the frame level image quality mode PicQ in the frame originating point information of code stream, be divided into following two implementation:
(a) all quantification manners:
In following three kinds of situations, DQ_MODE uses whole quantification manners to realize: (a-1) frame level image quality mode is nothing
Damage pattern (the PicQ value of write code stream is 0);(a-2) frame level image quality mode (writes code stream for damaging clear pattern
PicQ value is 1);(a-3) frame level image quality mode is to damage balanced mode (the PicQ value of write code stream is 2) and current chroma
Component sub-frame is U or V component subframe.The concrete methods of realizing of the DQ_MODE whole quantification manners of employing is as follows:
To initial data P each in current block, the present invention is not predicted, and directly uses quantization, the side rebuilding and encoding
Formula: first press formula (54) and calculate the quantized data QP of PDQ1, then press formula (55) calculating reconstruction data RDQ1, finally press formula (56)
Calculate quantization tables of data and show bit number QPBitsDQ1.In order to enable decoding end to rebuild the data of current block by formula (55), this
First invention would indicate that the coding mode mark ModeID of DQ_MODEDQEnroll code stream, represent with 4 bits, be worth for 0b1111;Connect
Each QPDQ1Use QPBitsDQ1Individual bit number enrolls code stream.In the present invention, P represents with 8 bits, and P shifts through formula (54)
After quantization, QPDQ1Only need to 8 subtract shift bit represent can (shift is frame level quantization shift amount), therefore QPBitsDQ1
It is calculated by formula (56).According to formula (56), all QPBits in present frameDQ1The most equal, the most relevant with shift, and
Shift can be obtained by the frame level image quality mode PicQ of encoded code stream, therefore QPBitsDQ1Need not enroll code stream.
QPDQ1=(P+ (QStep > > 1)) > > shift (54)
RDQ1=QPDQ1< < shift (55)
QPBitsDQ1=8-shift (56)
According to encoding information above, use whole quantification manners of DQ_MODE that current block carries out the coding that coding consumes
Bit number CBitsDQ1It is calculated by formula (57).
CBitsDQ1=4+h × v × QPBitsDQ1 (57)
B () level halves quantification manner:
When frame level image quality mode is to damage balanced mode (the PicQ value of write code stream is 2) and current chroma component
Frame is Y-component subframe, then DQ_MODE employing level halves quantification manner and encodes, and concrete methods of realizing is as follows:
Current block first often takes adjacent two data P by order from left to right in the horizontal direction(2*i,j)And P(2*i+1,j),
Calculate their average as a new data P '(i,j), as shown in formula (58), i and j is respectively the horizontal level of new data block
Index and vertical position index;For being in the data block of chromatic component subframe right margin, if its h is odd number, the most often row is last
One P(2*i,j)There is no paired P(2*i+1,j), the present invention is directly by P '(i,j)It is set to P(2*i,j).Current block is through level side
To resolution halve after obtain all P ' form new data block, to data P ' each in new data block, first press formula (59)
Calculate its quantized data QPDQ2, then calculate its reconstruction data R ' by formula (60), finally press formula (61) and calculate corresponding with P '
P(2*i,j)And P(2*i+1,j)Two reconstruction data RDQ2 (2*i,j)And RDQ2 (2*i+1,j)。
P'(i,j)=(P(2*i,j)+P(2*i+1,j)) > > 1 (58)
QPDQ2=(P'+ (QStep > > 1)) > > shift (59)
R'=QPDQ2< < shift (60)
In order to enable decoding end to rebuild the data of current block by formula (60) and (61), the present invention is first by DQ_MODE
Coding mode mark ModeIDDQEnroll code stream, represent with 4 bits, be worth for 0b1111;Then by each QPDQ2Use QPBitsDQ2
Individual bit number enrolls code stream.In the present invention, P represents with 8 bits, and P ' also represents with 8 bits, after formula (59) shift quantization,
QPDQ2Only need to subtract shift bit with 8 to represent, therefore QPBitsDQ2It is calculated by formula (62).According to formula (62),
The all of QPBits of present frameDQ2The most equal, the most relevant with shift, therefore QPBitsDQ2Need not enroll code stream.
QPBitsDQ2=8-shift (62)
According to encoding information above, use the level of DQ_MODE to halve quantification manner and current block is carried out what coding consumed
Number of coded bits CBitsDQ2It is calculated by formula (63).
CBitsDQ2=4+ ((h+1) > > 1) × v × QPBitsDQ2 (63)
For the ease of unified presentation, the present invention carries out, by using DQ_MODE, the number of coded bits that coding consumes to current block
It is designated as CBitsDQ, according to specific implementation, its value is CBitsDQ1Or CBitsDQ2。
Formula (63) is compared with formula (57), although QPBitsDQ2With QPBitsDQ1Equal, but due to quantized data
Number decreases half, significantly reduces number of coded bits.In order to obtain preferable video quality while improving compression ratio, this
Invention is all that horizontal resolution is more than vertical resolution in view of typical screen video, therefore DQ_MODE halve quantization side
Formula only selects horizontal direction data carry out 1/2nd extractions, and uses the mode taking average in extraction process, reduces
The loss of well as subjective video quality.Owing to decoding end can obtain the reality of DQ_MODE according to PicQ and chromatic component subframe type
Existing mode, therefore the DQ_MODE implementation of each piece is not enrolled code stream by the present invention, decreases number of coded bits.Multiple
Under the switching of miscellaneous screen video scene, the temporal correlation between video data reduces, the candidate coding pattern in addition to DQ_MODE
Predictive efficiency significantly reduces, and number of coded bits is more, and DQ_MODE is owing to can use level to halve quantification manner, only to half
Video data be compressed, significantly reduce the peak-data amount of video code flow.
In step (5), described effective candidate coding pattern refers to allow the candidate directly as final coding mode
Coding mode, for individual data block, the effective candidate coding pattern between data block there are differences.Described continuous blocks
Require that the coded sequence of data block is adjacent in current chroma component sub-frame.
Due in step (5), the quantization residual error number of bits (QDBits of all candidate patternXX, its subscript XX be IC,
Each candidate pattern corresponding is distinguished when HP, VP, CH, CV or AP) to unify to represent with 3 bits, it is simple to decoding end analytic uniform, it is permitted
The maximum permitted is 7.In the case of the inter frame image quality of present frame is lossless mode, quantization step is all 1, candidate code
There is the QDBits situation more than 7 in pattern IC_MODE, HP_MODE, VP_MODE, CH_MODE, CV_MODE and AP_MODE,
Cause them to cannot function as effective candidate coding pattern of current block, i.e. cannot become final coding mode.And DQ_MODE due to
Its QPBitsDQ1Or QPBitsDQ2Without enrolling code stream, do not have effective candidate to limit, it is ensured that each piece at least one have
Effect candidate coding pattern, it is to avoid occur not having coding mode can situation.
In step (5), candidate coding pattern HP_MODE, VP_MODE, CH_MODE, CV_MODE and AP_MODE are at meter
When calculating coding information, all each data in current block are employed to rebuild the mode predicted, i.e. space adjacent
Rebuild data using the predictive value as current data.
In step (5), the binary value of each coding mode mark is not mutually equal for prefix, decimal value, and
And under exemplary screen video scene, final coding mode adds up the ratio less number of bits table of higher pattern identification
Show, effectively reduce the total bit number of coding, as shown in table 3.
Table 3
Coding mode identifies | Decimal value | Number of bits | Binary value |
ModeID<sup>IC</sup> | 0 | 2 | 0b00 |
ModeID<sup>SO</sup> | 1 | 2 | 0b01 |
ModeID<sup>HP</sup> | 4 | 3 | 0b100 |
ModeID<sup>VP</sup> | 5 | 3 | 0b101 |
ModeID<sup>CH</sup> | 12 | 4 | 0b1100 |
ModeID<sup>CV</sup> | 13 | 4 | 0b1101 |
ModeID<sup>AP</sup> | 14 | 4 | 0b1110 |
ModeID<sup>DQ</sup> | 15 | 4 | 0b1111 |
In step (5), current block can from its effective candidate coding pattern an optional pattern directly as finally
Coding mode.In order to improve video compress ratio, reduce the computation complexity of model selection and obtain good video image quality,
Can coding mode preferably final with sub-step by the following method:
If (5-1) SO_MODE is effective candidate coding pattern of current block or is the consecutive identical list started from current block
Effective candidate coding pattern of value block, then directly finally encode mould as current block or the continuous blocks that start from current block
Formula, and the data set of rebuilding under this pattern is become the final reconstructed block of correspondence position, and termination pattern selects in advance;Otherwise hold
Go next step.
If (5-2) IC_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then count
Calculate the bit number CBits that current block uses this pattern-coding to consumeIC, and perform next step;If IC_MODE is having of current block
The quantization residual error of effect candidate coding pattern and current block is zero, then detecting subsequent block from next BOB(beginning of block) is the most also IC_
MODE quantifies residual error stand growth model, until quantization residual error non-full zero block or last block being detected, and directly by IC_MODE
As current block or the final coding mode of continuous blocks that starts from current block, the reconstruction data set under this pattern is become corresponding position
Put final reconstructed block, and in advance termination pattern select;Other situation performs next step.
(5-3) the coding information using HP_MODE that current block is predicted quantization is calculated;If HP_MODE is current block
Effective candidate coding pattern and current block there is non-zero quantised residual error, then calculate current block and use this pattern-coding to consume
Bit number CBitsHP, and perform next step;If the quantization of effective candidate coding pattern that HP_MODE is current block and current block is residual
Difference is zero, then directly as the final coding mode of current block, and the reconstruction data under this pattern are formed current block
Final reconstructed block, and in advance terminate current block model selection;Other situation performs next step.
(5-4) the coding information using VP_MODE that current block is predicted quantization is calculated;If VP_MODE is current block
Effective candidate coding pattern and current block there is non-zero quantised residual error, then calculate current block and use this pattern-coding to consume
Bit number CBitsVP, and perform next step;If the quantization of effective candidate coding pattern that VP_MODE is current block and current block is residual
Difference is zero, then directly as the final coding mode of current block, and the reconstruction data under this pattern are formed current block
Final reconstructed block, and in advance terminate current block model selection;Other situation performs next step.
(5-5) the coding information using AP_MODE that current block is predicted quantization is calculated;If AP_MODE is current block
Effective candidate coding pattern and current block there is non-zero quantised residual error, then calculate current block and use this pattern-coding to consume
Bit number CBitsAP, and perform next step;If the quantization of effective candidate coding pattern that AP_MODE is current block and current block is residual
Difference is zero, then directly as the final coding mode of current block, and the reconstruction data under this pattern are formed current block
Final reconstructed block, and in advance terminate current block model selection;Other situation performs next step.
(5-6) it is unsatisfactory for becoming condition or its CBits of the effective candidate coding pattern of current block as HP_MODEHPMore than threshold
Value TH1, first calculates and uses CH_MODE current block to be predicted the coding information quantified, if then CH_MODE meets into
For the condition of the effective candidate coding pattern of current block, then calculate and use CH_MODE that current block carries out the ratio that coding needs to consume
Special number CBitsCH.The span of TH1 is [6, h × v × QPBitsCH], TH1 is the biggest, and CH_MODE becomes final coding mode
Probability the least.Coded system RowMode that current block is often gone under CH_MODECHDetermine according to formula (64), its intermediate value
Being that 1 expression current line uses direct quantification manner, value is that 0 expression current line uses horizontal forecast quantification manner,Represent current line maximum quantization residual error QDCH row-maxThe minimum number of coded bits needed, threshold value THCH
In the range of [0,7], its value is the least, is more about to select direct quantification manner.
(5-7) it is unsatisfactory for becoming condition or its CBits of the effective candidate coding pattern of current block as VP_MODEVPMore than threshold
Value TH2, first calculates and uses CV_MODE current block to be predicted the coding information quantified, if then CV_MODE meets into
For the condition of the effective candidate coding pattern of current block, then calculate and use CV_MODE that current block carries out the ratio that coding needs to consume
Special number CBitsCV.The span of TH2 is [6, h × v × QPBitsCV], TH2 is the biggest, and CV_MODE becomes final coding mode
Probability the least.Current block is coded system ColMode of each column under CV_MODECVDetermining according to formula (65), its value is
1 represents when prostatitis uses direct quantification manner, and value is that 0 expression vertically predicts quantification manner when prostatitis uses,Represent when prostatitis maximum quantization residual error QDCV col-maxThe minimum number of coded bits needed, threshold value THCV
In the range of [0,7], the least then more row of value will select direct quantification manner.
If (5-8) DQ_MODE of current chroma component sub-frame uses whole quantification manners, then determine to work as according to formula (66)
Whether front piece calculate the quantization of DQ_MODE and rebuild data, ENDQ1Value is quantization and the weight that 1 expression current block calculates DQ_MODE
Building data, value is that 0 expression current block does not calculate the quantization of DQ_MODE and rebuilds data, CBitsMINRepresent calculated each pattern
Middle coding need to consume the minima of bit number, and shift is that take the logarithm by 2 frame level that obtains of frame level quantization step QStep quantifies to move
Position figure place.
If the DQ_MODE use level of current chroma component sub-frame halves quantification manner, i.e. when frame level image quality mode
It is Y-component subframe for damaging balanced mode and current chroma component sub-frame, then determines whether current block calculates DQ_ by formula (67)
The quantization of MODE and reconstruction data, ENDQ2Value is that 1 expression current block calculates the quantization of DQ_MODE and rebuilds data, and value is 0 expression
Current block does not calculate the quantization of DQ_MODE and rebuilds data;TotalBitsYRepresent the encoding ratio that current Y-component subframe has consumed
Special number, η is coefficient of comparisons, and less than 1.0, typical value scope is [0.2,0.8], H1For the horizontal resolution of Y-component subframe, V1
Vertical resolution for Y-component subframe.
Current block is after formula (66) or formula (67) judge, if ENDQ1Or ENDQ2Value is 1, then calculate current block and use
The quantization of DQ_MODE and reconstruction data, and calculate the bit number CBits using DQ_MODE to carry out coding needs consumptionDQ, its value
For CBitsDQ1Or CBitsDQ2。
(5-9) from the effective candidate coding pattern estimated, final volume is selected by the principle that consumption number of coded bits is minimum
Pattern, in the case of number of coded bits is identical, selects the coding mode ident value final coding mode of less conduct;Will be current
Block data set of rebuilding under final coding mode becomes the final reconstructed block of correspondence position, and the coding for subsequent block provides prediction ginseng
Examine.
Coding information is write code stream according to the final coding mode of current block by described step (6) in order, specifically divides
Eight kinds of situations below:
(6-1) the final coding mode of current block is IC_MODE, the most as follows by coding information write code stream:
A coding mode mark ModeID that () write code stream 2 bit representsIC, its value is 0b00.
B stand growth model mark AZBFlag that () write code stream 1 bit representsIC。
If (c) AZBFlagICValue is 0b1, then show that current block is that IC_MODE quantifies residual error stand growth model, jump to step (f),
Otherwise show that current block exists non-zero quantised residual error, perform next step.
D quantization residual error number of bits QDBits that 3 bits are represented by ()ICWrite code stream.
E () first presses the order of raster scanning by all of for current block prediction residual symbol SignICWrite code stream, each
SignICRepresent with 1 bit;The most in the same order by all of for current block quantization residual error QDICWrite code stream, each QDICWith
QDBitsICIndividual bit represents;At all of SignICAnd QDICAfter all writing code stream, terminate the code stream write of current block.
F consecutive identical monodrome block identification ContiFlag that () write code stream 1 bit representsICIf: only to single quantization residual error
Stand growth model encodes, then ContiFlagICValue is 0b0, and terminates the code stream write of current block;If to start from current block
ContiCnt continuouslyICIndividual quantization residual error stand growth model encodes, then ContiFlagICValue is 0b1, and performs next step.
G () is first by ContiCntICNumber of coded bits mark ContiCntBitsIdxICUse 2 bit write code streams, then
By ContiCntICThe use ContiCntBits that subtracts 1ICIndividual bit write code stream, finally terminates the code stream write of current block.Decoding
End can pass through ContiCntBitsIdxICObtain ContiCntBitsICIf: ContiCntBitsIdxICValue is 0b00, the most right
Answer ContiCntBitsICValue is 2;Work as ContiCntBitsIdxICValue is 0b01, then corresponding ContiCntBitsICValue is 6;If
ContiCntBitsIdxICValue is 0b10, corresponding ContiCntBitsICValue is 11;If ContiCntBitsIdxICValue is 0b11,
Then corresponding ContiCntBitsICValue is
(6-2) the final coding mode of current block is monodrome raw mode SO_MODE, will encode information the most as follows
Write code stream:
A () writes the coding mode mark ModeID that 2 bits representSO, its binary value is 0b01.
B () writes monodrome coded system CodPsFlag that 1 bit representsSO。
If (c) CodPsFlagSOValue is equal to 0b1, then the single-value data P represented by 8 bitssWrite code stream;If
CodPsFlagSOValue equal to 0b0, show the final coding mode of the adjacent top coded block in current block space be SO_MODE and
Its single-value data and the single-value data P of current blocksEqual, the most not by PsWrite code stream.
D () writes the consecutive identical monodrome block identification ContiFlag that 1 bit representsSO。
If (e) ContiFlagSOValue, equal to 0b0, represents and only encodes current block, then the code stream terminating current block is write
Enter;If ContiFlagSOValue, equal to 0b1, represents the ContiCnt started from current blockSOThe coding mode of individual consecutive data block is all
The most equal for SO_MODE and their monodrome, the most first write the ContiCnt that 2 bits representSONumber of coded bits identifies
ContiCntBitsIdxSO, then by ContiCntSOSubtract 1 and use ContiCntBitsSOIndividual bit represents write code stream.Decoding end can
To pass through ContiCntBitsIdxSOObtain ContiCntBitsSO: work as ContiCntBitsIdxSOValue is 0b00, then corresponding
ContiCntBitsSOValue is 2;Work as ContiCntBitsIdxSOValue is 0b01, then corresponding ContiCntBitsSOValue is 6;Then when
ContiCntBitsIdxSOValue is 0b10, corresponding ContiCntBitsSOValue is 11;Work as ContiCntBitsIdxSOValue is 0b11,
Then corresponding ContiCntBitsSOValue is
(6-3) the final coding mode of current block is horizontal pointwise pattern HP_MODE, will encode information the most as follows
Write code stream:
A coding mode mark ModeID that () write code stream 3 bit representsHP, its binary value is 0b100.
B quantization residual error number of bits QDBits that () write code stream 3 bit representsHP。
If (c) QDBitsHPValue is 0, then terminate the code stream write of current block;If QDBitsHPValue, more than 0, the most first presses grating
The order of scanning is by all of for current block prediction residual symbol SignHPWrite code stream, each SignHPRepresent with 1 bit, then press
Identical order is by all of for current block quantization residual error QDHPWrite code stream, each QDHPUse QDBitsHPIndividual bit represents.
(6-4) the final coding mode of current block is vertical pointwise pattern VP_MODE, the most as follows by current block
Coding information write code stream:
A coding mode mark ModeID that () write code stream 3 bit representsVP, its binary value is 0b101.
B quantization residual error number of bits QDBits that () write code stream 3 bit representsVP。
If (c) QDBitsVPValue is 0, then terminate the code stream write of current block;If QDBitsVPValue, more than 0, the most first presses grating
The order of scanning is by all of for current block prediction residual symbol SignVPWrite code stream, each SignVPRepresent with 1 bit, then press
Identical order is by all of for current block quantization residual error QDVPWrite code stream, each QDVPUse QDBitsVPIndividual bit represents.
(6-5) the final coding mode of current block is level of complexity pattern CH_MODE, the most as follows by current block
Coding information write code stream:
A () writes the coding mode mark ModeID that 4 bits representCH, its binary value is 0b1100.
B () presses order from top to bottom by coded system RowMode of each row of dataCHWrite code stream, often goes
RowModeCHRepresent with 1 bit.
C () is according to RowModeCHThe distribution of value divides following three kinds of situations to encode:
(c-1) if the RowMode of all write code streamsCHValue is all 0b1, and the data of the most all row all use and directly quantify to compile
Code mode, then press the order of raster scanning by all of for current block quantized data QPCHWrite code stream, each QPCHUse QPBitsCH
Individual bit represents.
(c-2) if writing the RowMode of code streamCHValue is all 0b0, and the data of the most all row all use horizontal forecast to quantify to compile
Code mode, first writes quantization residual error number of bits QDBits represented with 3 bitsCH;If then QDBitsCHMore than 0, then
First press the order of raster scanning by all of for current block prediction residual symbol SignCHWrite code stream, each SignCHWith 1 bit table
Show, more in the same order by all of for current block quantization residual error QDCHWrite code stream, each QDCHUse QDBitsCHIndividual bit table
Show.
(c-3) if writing the RowMode of code streamCHValue is 0b0 and all existing for 0b1, first writes and to represent with 3 bits
Quantify residual error number of bits QDBitsCH;If then QDBitsCHMore than 0, the most first by the order of raster scanning, current block is owned
Prediction residual symbol SignCHWrite code stream, each SignCHRepresent with 1 bit, more in the same order current block is owned
Quantization residual error QDCHWrite code stream, each QDCHUse QDBitsCHIndividual bit represents;The order finally pressing raster scanning will be current
Block all of quantized data QPCHWrite code stream, each QPCHUse QPBitsCHIndividual bit represents.
(6-6) the final coding mode of current block is complicated vertically pattern CV_MODE, the most as follows by current block
Coding information write code stream:
A () writes the coding mode mark ModeID that 4 bits representCV, its binary value is 0b1101.
B () presses order from left to right by each column coded system ColModeCVWrite code stream, the ColMode of each columnCVAt code
Stream represents with 1 bit.
C () is according to ColModeCVThe distribution of value divides following three kinds of situations to encode:
(c-1) if the ColMode of all write code streamsCVValue is all 0b1, and the data of the most all row all use the directly side of quantization
Formula, then press the order of raster scanning by all of quantized data QPCVWrite code stream, each QPCVUse QPBitsCVIndividual bit represents.
(c-2) if the ColMode of all write code streamsCVValue is all 0b0, and the data of the most all row all use vertical premeasuring
Change mode, first writes quantization residual error number of bits QDBits represented with 3 bitsCV;If then QDBitsCVMore than 0, then
First press the order of raster scanning by all of for current block prediction residual symbol SignCVWrite code stream, each SignCVWith 1 bit table
Show, more in the same order by all of for current block quantization residual error QDCVWrite code stream, each QDCVUse QDBitsCVIndividual bit table
Show.
(c-3) if writing the ColMode of code streamCVValue is 0b0 and all existing for 0b1, first writes and to represent with 3 bits
Quantify residual error number of bits QDBitsCV;If then QDBitsCVMore than 0, the most first by the order of raster scanning, current block is owned
Prediction residual symbol SignCVWrite code stream, each SignCVRepresent with 1 bit, more in the same order current block is owned
Quantization residual error QDCVWrite code stream, each QDCVUse QDBitsCVIndividual bit represents;The order finally pressing raster scanning will be current
Block all of quantized data QPCVWrite code stream, each QPCVUse QPBitsCVIndividual bit represents.
(6-7) the final coding mode of current data block is self adaptation pointwise Mode A P_MODE, the most as follows ought
The coding information write code stream of front piece:
A coding mode mark ModeID that () write code stream 4 bit representsAP, its binary value is 0b1110.
B quantization residual error number of bits QDBits that () write code stream 3 bit representsAP。
If (c) QDBitsAPValue is 0, then terminate the code stream write of current block;If QDBitsAPValue, more than 0, the most first presses grating
The order of scanning is by all of for current block prediction residual symbol SignAPWrite code stream, each SignAPRepresent with 1 bit, then press
Identical order is by all of for current block quantization residual error QDAPWrite code stream, each QDAPUse QDBitsAPIndividual bit represents.
(6-8) the final coding mode of current data block is direct quantitative mode DQ_MODE, the most as follows will coding
Information write code stream:
A () writes the coding mode mark ModeID that 4 bits representDQ, its binary value is 0b1111.
If b () DQ_MODE uses the coded system all quantified, then press the order of raster scanning by all quantized datas
QPDQ1Write code stream, each QPDQ1Use QPBitsDQ1Individual bit represents;If DQ_MODE employing level halves the coding staff of quantization
Formula, then press the order of raster scanning by all quantized data QPDQ2Write code stream, each QPDQ2Use QPBitsDQ2Individual bit represents.
Described step (8) to present frame written into code stream carry out byte-aligned process, concrete grammar is as follows: if current
Frame written into the multiple that total bit number TotalBits of code stream is not 8, then fills, toward code stream afterbody, the bit that several values are zero
Data, filling number is 8 to deduct rem (rem is the remainder that TotalBits is obtained) by 8 remainders, and code stream becomes word after filling
Joint alignment;If the encoded code stream of present frame total bit number TotalBits has been the multiple of 8, it is not filled with.
Described step (8) carries out code stream byte after last data block of each chromatic component subframe has encoded
Registration process, it is ensured that the multiple that encoding code stream bit number is 8 of each chromatic component subframe, makes the present invention be embodied as
Time support to carry out sub-frame level parallel encoding by three chromatic component subframes, and in order the code stream of three subframes is connected directly between
Together, without code stream being carried out integral shift process when code stream connects, improve processing speed.
Described step (10) carries out frame sync identifications escape process to the code stream after present frame frame sync identifications, specifically
Method is as follows: to each byte after the frame sync identifications of present frame code stream, reads this byte and 3 bytes thereafter in order
Data, form 4 byte datas FourBytes (byte first read is in higher bit position), when FourBytes value is 0xFFFFFFFD,
In code stream, then after 0xFD, insert a byte data, be worth for 0x00;When FourBytes value is 0xFFFFFFFE, then by code
0xFE in stream replaces with 0xFD, and inserts a byte data after 0xFD, is worth for 0x01.Decoding end is at present frame code stream
First must be last in 0xFFFFFFFD00 by continuous five byte values all in present frame code stream before resolving and rebuilding
Individual byte 0x00 is deleted, and is that in 0xFFFFFFFD01, the 4th byte 0xFD replaces with 0xFE by all continuous five byte values, and
Last byte 0x01 is deleted.
Numeral KVM switcher carries out compression coding to the screen video of computer export, with under the limited network bandwidth
Realize the quick transmission of screen video.The present invention designs candidate coding pattern under the feature taking into full account screen video, is having
The compression efficiency of screen video is improved under the computation complexity of limit.For the complete phase of the pixel value of split screen in the middle part of screen video
With, the present invention devises monodrome raw mode, supports that monodrome block identical to continuous print carries out Unified coding;In order to improve picture gradually
The compression efficiency become, the present invention devises horizontal pointwise pattern and vertical pointwise pattern;In order to improve the pressure of complex texture picture
Contracting efficiency, the present invention devises adaptive prediction pattern, level of complexity pattern and the vertical pattern of complexity;In order to improve sudden change picture
Compression efficiency, the present invention devises direct quantitative mode;In order to improve the compression efficiency of still frame, the present invention devises frame
Between associative mode, support to quantify residual error force zero setting, and to continuous print quantify residual error stand growth model carry out Unified coding.
The video-frequency compression method of the present invention is applicable to the screen video of numeral KVM switcher collection is carried out data compression.
Compared with prior art, the present invention has a following beneficial effect:
1) supporting that the classification rebuilding video quality can configure, user can select flexibly according to application demand.
2) each exemplary screen video scene is had preferable compression efficiency, keep good reconstruction video quality simultaneously.
3) the peak-data amount of the lower video code flow of complex screen video scene switching is significantly reduced.
4) overall calculation complexity is low, is suitable on flush bonding processor realizing, effectively reduces the reality of numeral KVM switcher
Ready-made and process time delay.
Accompanying drawing explanation
Fig. 1 is the basic flow sheet of the inventive method;
Fig. 2 is the code flow structure figure of frame originating point information, and current code stream represents that the image resolution ratio of present frame is 1366 × 768,
Chrominance space form is YUV420, and block divides employing 8 × 4 partition mode, and inter prediction enables closes, and uses and damages balanced mode
Compression, is the 1st coded frame;
Fig. 3 is the data block division figure of chromatic component subframe.
Detailed description of the invention
The detailed description of the invention of the present invention is described below in conjunction with the accompanying drawings, it is noted that below for resolution with example
Be 1366 × 768 screen video carry out data compression, in the concrete ablation process of compressed bit stream, the present embodiment is deposited by big end
Storage pattern writes, and the high-bit data of data to be compressed preferentially writes the higher bit position of code stream byte, the mode of description
Simply one of numeral typical application mode of KVM switcher.Within the scope of the invention, those skilled in the art can also root
Some other alternate embodiments is used according to demand.
A kind of screen video compression method towards numeral KVM switcher, as it is shown in figure 1, comprise the following steps:
(1) frame screen video data are inputted:
A described frame screen video data from digital KVM switcher collects, and in the present embodiment, the screen of input regards
Frequency is according to using YUV chrominance space, and image resolution ratio is 1366 × 768 (i.e. horizontal resolutions H of image0It is 1366, vertically divides
Resolution is V0It is 768), comprise 1049088 pixels altogether.In order to reduce the compressed code fluxion of high-resolution screen video as far as possible
According to amount, the chrominance space form that the present embodiment is selected is YUV420, and its relatively YUV422 and YUV444 has less U component data
With V component data.Current video frame is divided into three chromatic component subframes, all Y-component data composition H1×V12-D data
Array, is designated as Y-component subframe, its horizontal resolution H1Equal to 1366, vertical resolution V1Equal to 768;All U component data groups
Become H2×V2Two-dimensional data array, be designated as U component sub-frame, according to table 1, its horizontal resolution H2Equal to 683, vertical resolution
V2Equal to 384;All V component data composition H3×V3Two-dimensional data array, be designated as V component subframe, according to table 1, its level is divided
Resolution H3Equal to 683, vertical resolution V3Equal to 384.
(2) frame originating point information of current video frame is write in the following order code stream:
(2-1) writing frame sync identifications SyncF of 4 bytes at byte-aligned, first three byte value is 0xFF, the 4th
Individual byte value is 0xFE.
(2-2) the resolution mark PicR of the current screen video image that write represents with 6 bits.The screen of the present embodiment
Video resolution is 1366 × 768, and according to table 2 in summary of the invention, PicR value is 0b001111.
(2-3) the chrominance space format identification (FID) ColorF represented with 3 bits is write.The chrominance space form of the present embodiment is
YUV420 form, ColorF value is 0b000.
(2-4) the data block partition mode mark BP that write represents with 4 bitsMODE.In order at Current high resolution screen
Obtaining preferable compression efficiency under video, the present embodiment selects 8 × 4 partition modes, BPMODEValue is 0b0001.
(2-5) the write inter prediction that 1 bit represents enables mark TPEN.Present frame is first coded frame, does not permits
Being permitted to use time domain prediction, the present embodiment is by TPENIt is set to 0b0;Present frame is not first coded frame, then allow to use time domain pre-
Surveying, in order to improve the compression efficiency of screen video, the present embodiment all allows to use inter prediction, TPENValue is 0b1.
(2-6) the frame level image quality mode PicQ represented with 2 bits is write.Regard to reduce high-resolution screen as far as possible
The bit stream data amount of frequency, the present embodiment selection frame level image quality mode is for damaging balanced mode, and PicQ value is 0b10.
(2-7) the frame number FrameN of the present frame that write represents with 16 bits.Present frame is the first frame, then FrameN value
It is 0.The follow-up frame that often encodes, FrameN value adds 1, when FrameN is equal to 65536, FrameN the most first resets to 0, then will
FrameN writes code stream.
In step (2), each numerical value be its high order bit first write code stream (first pass through network and be sent to decoding end),
Code stream is write after low-order bit.Each bit priority, during write code stream, is write a storage byte by the present embodiment
Higher bit position.Fig. 2 show the present embodiment and uses the preamble information bitstream structure chart under big end memory module.
(3) from current video frame, a uncoded color is obtained by Y-component subframe, U component sub-frame, the order of V component subframe
Degree component sub-frame as current chroma component sub-frame, 8 × 4 partition modes selected according to step (2) to present sub-frame by grating
The order of scanning carries out data block division, calculates data block number H in present sub-frame horizontal direction by formula (1)blk, by public affairs
Formula (2) calculates data block number V on present sub-frame vertical directionblk, calculate data to be encoded block in this subframe by formula (3)
Total number Nblk.In the present embodiment, the concrete data block of three chromatic component subframes divides as it is shown on figure 3, the resolution of Y-component subframe
Rate is 1366 × 768,171 blocks of horizontal direction, 192 blocks of vertical direction, totally 32832 blocks;U component sub-frame and V component
The resolution of frame is all 683 × 384, and horizontal direction has 86 blocks, and vertical direction has 96 blocks, and whole subframe is respectively arranged with 8256
Individual block.
(4) from current chroma component sub-frame, a uncoded data block is obtained as current block:
From current chroma component sub-frame, the two-dimemsional number to be encoded of h × v size is obtained by the order of raster scanning
According to block.According to the BP of write code stream in step (2)MODEObtain data block dividing unit, BP in the present embodimentMODEValue is 0b0001,
Data block dividing unit is 8 × 4, the data amount check h that corresponding horizontal direction dividesPIt is 8, the number that corresponding vertical direction divides
According to number vPIt is 4.In Y-component subframe, the block size comprising right margin be 6 × 4 (h equal to 6, v equal to 4), other block big
Little is all basic to divide size 8 × 4 (h equal to 8, v equal to 4);In U component sub-frame, the block size comprising right margin is 3 × 4
(h equal to 3, v equal to 4), the size of other block be all basic division size 8 × 4;In V component subframe, comprise the block of right margin
Size be 3 × 4 (h equal to 3, v equal to 4), the size of other block be all basic division size 8 × 4.
(5) calculate current block coding information under each effective candidate coding pattern and rebuild data, and choosing final
Coding mode and reconstruction data.In order to improve video compress ratio, reduce the computation complexity of model selection and obtain good regarding
Frequently picture quality, the present embodiment carries out model selection with method according to the following steps, with the most final coding mode, and obtains final
Reconstruction data:
If (5-1) SO_MODE is effective candidate coding pattern of current block or is the consecutive identical list started from current block
Effective candidate coding pattern of value block, then directly finally encode mould as current block or the continuous blocks that start from current block
Formula, and the data set of rebuilding under this pattern is become the final reconstructed block of correspondence position, and termination pattern selects in advance.
If (5-2) IC_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then press
Formula (13) calculates the bit number CBits that current block uses this pattern-coding to consumeIC;If IC_MODE is the effective of current block
The quantization residual error of candidate coding pattern and current block is zero, then detecting subsequent block from next BOB(beginning of block) is the most also IC_
MODE quantifies residual error stand growth model, until quantization residual error non-full zero block or last block being detected, and directly by IC_MODE
As current block or the final coding mode of continuous blocks that starts from current block, the reconstruction data set under this pattern is become corresponding position
Put final reconstructed block, and in advance termination pattern select;
If (5-3) HP_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then press
Formula (22) calculates the bit number CBits that current block uses this pattern-coding to consumeHP;If HP_MODE is the effective of current block
The quantization residual error of candidate coding pattern and current block is zero, then directly as the final coding mode of current block, and will
The reconstructed block of the reconstruction data composition current block under this pattern, and termination pattern selects in advance.
If (5-4) VP_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then press
Formula (28) calculates the bit number CBits that current block uses this pattern-coding to consumeVP;If VP_MODE is the effective of current block
The quantization residual error of candidate coding pattern and current block is zero, then directly as the final coding mode of current block, and will
The reconstructed block of the reconstruction data composition current block under this pattern, and termination pattern selects in advance.
If (5-5) AP_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then press
Formula (53) calculates the bit number CBits that current block uses this pattern-coding to consumeAP;If AP_MODE is the effective of current block
The quantization residual error of candidate coding pattern and current block is zero, then directly as the final coding mode of current block, and will
The reconstructed block of the reconstruction data composition current block under this pattern, and termination pattern selects in advance.
If (5-6) HP_MODE is unsatisfactory for becoming requirement or its CBits of the effective candidate coding pattern of current blockHPIt is more than
TH1, first calculates and uses CH_MODE that current block is predicted the coding information quantified, and becomes if then CH_MODE is satisfied
The condition of the effective candidate coding pattern of current block, then use CH_MODE to carry out current block encoding needs by formula (37) calculating
The bit number CBits consumedCH.In the present embodiment, TH1 takes h × v × QPBitsCH/2;The volume that current block is often gone under CH_MODE
Code mode RowModeCHDetermine according to formula (64), the TH of formula (64) in the present embodimentCHTake 4.
If (5-7) VP_MODE is unsatisfactory for becoming requirement or its CBits of the effective candidate coding pattern of current blockVPIt is more than
TH2, first calculates and uses VP_MODE that current block is predicted the coding information quantified, and becomes if then VP_MODE is satisfied
The condition of the effective candidate coding pattern of current block, then use CV_MODE to carry out current block encoding needs by formula (46) calculating
The bit number CBits consumedCV.In the present embodiment, TH2 takes h × v × QPBitsCV/2;Current block is the volume of each column under CV_MODE
Code mode ColModeCVDetermine according to formula (65), the TH of formula (65) in the present embodimentCVTake 6.
If (5-8) DQ_MODE uses whole quantification manners, then determine whether current block calculates DQ_MODE by formula (66)
Quantization and rebuild data, the present embodiment takes coefficient of comparisons η in formula (66) and is taken as 0.5;If the DQ_MODE use level amount of halving
By formula (67), change mode, then determine whether current block calculates the quantization of DQ_MODE and rebuild data.Current block is through formula
(66) or formula (67) judge after, if ENDQ1Or ENDQ2Value is 1, then need calculate the quantization of DQ_MODE and rebuild data, and press
Formula (57) or (63) calculate and use DQ_MODE that current block carries out the bit number CBits that coding needs to consumeDQ, its value is
CBitsDQ1Or CBitsDQ2。
(5-9) from the effective candidate coding pattern estimated, final volume is selected by the principle that consumption number of coded bits is minimum
Pattern, in the case of number of coded bits is identical, selects the coding mode ident value final coding mode of less conduct;Will be final
Data set of rebuilding under coding mode becomes the final reconstructed block of correspondence position, and the coding for subsequent block provides prediction reference.
(6) according to the final coding mode of current block, the coding information of current block is write code stream, specifically divide following eight kinds
Situation:
If (6-1) the final coding mode of current block is IC_MODE, the most as follows by coding information write code stream:
A coding mode mark ModeID that () write code stream 2 bit representsIC, its value is 0b00.
B stand growth model mark AZBFlag that () write code stream 1 bit representsIC。
If (c) AZBFlagICValue is 0b1, then show that current block is to quantify residual error stand growth model, jump to step (f), otherwise table
There is quantization residual error non-zero in bright current block, performs next step.
D quantization residual error number of bits QDBits that 3 bits are represented by ()ICWrite code stream.
E () first presses the order of raster scanning by all of for current block prediction residual symbol SignICWrite code stream, each
SignICRepresent with 1 bit;The most in the same order by all of for current block quantization residual error QDICWrite code stream, each QDICWith
QDBitsICIndividual bit represents;At all of SignICAnd QDICAfter all writing code stream, terminate the code stream write of current block.
F consecutive identical monodrome block identification ContiFlag that () write code stream 1 bit representsIC。
If (g) ContiFlagICValue is 0b0, represents and encodes single quantization residual error stand growth model, then terminates current block
Coding.If ContiFlagICValue is 0b1, represents the ContiCnt started from current blockICThe coding mode of individual consecutive data block
Be all IC_MODE and all be quantify residual error stand growth model, the most first by ContiCntICNumber of coded bits mark
ContiCntBitsIdxICUse 2 bit write code streams, then by ContiCntICThe use ContiCntBits that subtracts 1ICIndividual compare feature
Enter code stream.
If (6-2) the final coding mode of current block is monodrome raw mode SO_MODE, the most as follows coding is believed
Breath write code stream:
A () writes the coding mode mark ModeID that 2 bits representSO。
B () writes monodrome coded system CodPsFlag that 1 bit representsSO。
If (c) CodPsFlagSOValue is equal to 0b1, then the single-value data P represented by 8 bitssWrite code stream;If
CodPsFlagSOValue equal to 0b0, show the final coding mode of the adjacent top coded block in current block space be SO_MODE and
Its single-value data and the single-value data P of current blocksEqual, the most not by PsWrite code stream.
D () writes the consecutive identical monodrome block identification ContiFlag that 1 bit representsSO。
If (e) ContiFlagSOValue, equal to 0b0, represents and only encodes current block, then terminate the coding of current block;If
ContiFlagSOValue, equal to 0b1, represents the ContiCnt started from current blockSOThe coding mode of individual consecutive data block is all SO_
MODE and their monodrome are the most equal, the most first write the ContiCnt that 2 bits representSONumber of coded bits identifies
ContiCntBitsIdxSO, then by ContiCntSOSubtract 1 and use ContiCntBitsSOIndividual bit represents write code stream.
If (6-3) the final coding mode of current block is horizontal pointwise pattern HP_MODE, the most as follows coding is believed
Breath write code stream:
A coding mode mark ModeID that () write code stream 3 bit representsHP。
B quantization residual error number of bits QDBits that () write code stream 3 bit representsHP。
If (c) QDBitsHPValue is 0, then terminate the code stream write of current block;If QDBitsHPValue, more than 0, the most first presses grating
The order of scanning is by all of for current block prediction residual symbol SignHPWrite code stream, each SignHPRepresent with 1 bit, then press
Identical order is by all of for current block quantization residual error QDHPWrite code stream, each QDHPUse QDBitsHPIndividual bit represents.
If (6-4) the final coding mode of current block is vertical pointwise pattern VP_MODE, the most as follows by current block
Coding information write code stream:
A coding mode mark ModeID that () write code stream 3 bit representsVP, its binary value is 0b101.
B quantization residual error number of bits QDBits that () write code stream 3 bit representsVP。
If (c) QDBitsVPValue is 0, then terminate the code stream write of current block;If QDBitsVPValue, more than 0, the most first presses grating
The order of scanning is by all of for current block prediction residual symbol SignVPWrite code stream, each SignVPRepresent with 1 bit, then press
Identical order is by all of for current block quantization residual error QDVPWrite code stream, each QDVPUse QDBitsVPIndividual bit represents.
If (6-5) the final coding mode of current block is level of complexity pattern CH_MODE, the most as follows by current block
Coding information write code stream:
A () writes the coding mode mark ModeID that 4 bits representCH。
B () presses order from top to bottom by coded system RowMode of each row of dataCHWrite code stream, often goes
RowModeCHRepresent with 1 bit.
C () is according to RowModeCHThe distribution of value divides following three kinds of situations to encode:
(c-1) if the RowMode of all write code streamsCHValue is all 0b1, then owned by current block by the order of raster scanning
Quantized data QPCHWrite code stream, each QPCHUse QPBitsCHIndividual bit represents.
(c-2) if writing the RowMode of code streamCHValue is all 0b0, first writes the quantization residual error ratio represented with 3 bits
Special figure place QDBitsCH;If then QDBitsCHMore than 0, the most first press the order of raster scanning by all of for current block prediction residual
Symbol SignCHWrite code stream, each SignCHRepresent with 1 bit, then press the order of raster scanning by all of for current block quantization
Residual error QDCHWrite code stream, each QDCHUse QDBitsCHIndividual bit represents.
(c-3) if writing the RowMode of code streamCHValue is 0b0 and all existing for 0b1, first writes and to represent with 3 bits
Quantify residual error number of bits QDBitsCH;If then QDBitsCHMore than 0, the most first by the order of raster scanning, current block is owned
Prediction residual symbol SignCHWrite code stream, each SignCHRepresent with 1 bit, then press the order of raster scanning by current block
All of quantization residual error QDCHWrite code stream, each QDCHUse QDBitsCHIndividual bit represents;The order finally pressing raster scanning will
Current block all of quantized data QPCHWrite code stream, each QPCHUse QPBitsCHIndividual bit represents.
If (6-6) the final coding mode of current block is complicated vertically pattern CV_MODE, the most as follows by current block
Coding information write code stream:
A () writes the coding mode mark ModeID that 4 bits representCV。
B () presses order from left to right by each column coded system ColModeCVWrite code stream, the ColMode of each columnCVAt code
Stream represents with 1 bit.
C () is according to ColModeCVThe distribution of value divides following three kinds of situations to encode:
(c-1) if the ColMode of all write code streamsCVValue is all 0b1, then press the order of raster scanning by all of quantization
Data QPCVWrite code stream, each QPCVUse QPBitsCVIndividual bit represents.
(c-2) if the ColMode of all write code streamsCVValue is all 0b0, and the quantization that first write represents with 3 bits is residual
Difference number of bits QDBitsCV;If then QDBitsCVMore than 0, the most first press the order of raster scanning by all of for current block prediction
Sign of the residues SignCVWrite code stream, each SignCVRepresent with 1 bit, more in the same order by all of for current block quantization
Residual error QDCVWrite code stream, each QDCVUse QDBitsCVIndividual bit represents.
(c-3) if writing the ColMode of code streamCVValue is 0b0 and all existing for 0b1, first writes and to represent with 3 bits
Quantify residual error number of bits QDBitsCV;If then QDBitsCVMore than 0, the most first by the order of raster scanning, current block is owned
Prediction residual symbol SignCVWrite code stream, each SignCVRepresent with 1 bit, more in the same order current block is owned
Quantization residual error QDCVWrite code stream, each QDCVUse QDBitsCVIndividual bit represents;The order finally pressing raster scanning will be current
Block all of quantized data QPCVWrite code stream, each QPCVUse QPBitsCVIndividual bit represents.
If (6-7) the final coding mode of current data block is self adaptation pointwise Mode A P_MODE, the most as follows will
The coding information write code stream of current block:
A coding mode mark ModeID that () write code stream 4 bit representsAP。
B quantization residual error number of bits QDBits that () write code stream 3 bit representsAP。
If (c) QDBitsAPValue is 0, then terminate the code stream write of current block;If QDBitsAPValue, more than 0, the most first presses grating
The order of scanning is by all of for current block prediction residual symbol SignAPWrite code stream, each SignAPRepresent with 1 bit, then press
Identical order is by all of for current block quantization residual error QDAPWrite code stream, each QDAPUse QDBitsAPIndividual bit represents.
If (6-8) the final coding mode of current data block is direct quantitative mode DQ_MODE, will compile the most as follows
Code information write code stream:
A () writes the coding mode mark ModeID that 4 bits representDQ。
If b () DQ_MODE uses the implementation all quantified, then press the order of raster scanning by all quantized datas
QPDQ1Write code stream, each QPDQ1Use QPBitsDQ1Individual bit represents;If DQ_MODE uses the implementation halving quantization, then
By the order of raster scanning by all quantized data QPDQ2Write code stream, each QPDQ2Use QPBitsDQ2Individual bit represents.
(7) repeat step (4) to (6), complete coding and the reconstruction of all data blocks in current chroma component sub-frame.
(8) to current video frame written into code stream carry out bit padding to realize byte-aligned: if present frame written into
Total bit number TotalBits of code stream is not the multiple of 8, then toward code stream afterbody filling bit 0, filling number is 8 to deduct rem
(rem is the remainder that TotalBits is obtained by 8 remainders), code stream becomes byte-aligned after filling;If the encoded code of present frame
Flowing total bit number TotalBits is the multiple of 8, does not the most carry out bit padding.
(9) repeat step (3) to (8), complete coding and the reconstruction of all chromatic component subframes in current video frame.
(10) code stream producing current video frame carries out frame synchronization head escape process, exports final compressed bit stream: right
Each byte after the frame sync identifications of present frame code stream, reads the data of this byte and 3 bytes thereafter in order, forms 4
(byte first read is placed on the higher bit bit byte of FourBytes to byte data FourBytes, i.e. by big end pattern composition
FourBytes), when FourBytes value is 0xFFFFFFFD, then in code stream, after 0xFD, insert a byte data, be worth and be
0x00;When FourBytes value is 0xFFFFFFFE, then the 0xFE in code stream is replaced with 0xFD, and after 0xFD, inserts one
Individual byte data, is worth for 0x01;The code stream of current video frame exports its final compressed bit stream after escape processes.
Claims (21)
1. the screen video compression method towards numeral KVM switcher, it is characterised in that comprise the following steps:
(1) frame screen video data are inputted:
Described frame screen video data refer to that the frame that KVM switcher gathers uses the screen video figure of YUV chrominance space
Picture, the pixel resolution of this two field picture is H0×V0, it is divided into three chromatic component subframes, all Y-component data composition H1×V1
Y-component subframe, all U component datas composition H2×V2U component sub-frame, all V component data composition H3×V3V component
Subframe;
(2) frame originating point information of current video frame being write code stream, described frame originating point information includes:
The frame synchronization leader of 4 byte representations knows SyncF, and first three byte value is 0xFF, and the 4th byte value is 0xFE;
The resolution mark PicR of the present frame screen video image that 6 bits represent, its span is 1 to 24, Mei Gequ
Digital kvm system screen video image horizontal resolution H that value is corresponding0With vertical resolution V0As follows;
The chrominance space format identification (FID) ColorF that 3 bits represent, characterizes the chrominance space form that current video frame specifically uses,
Value represents employing YUV420 form for 0b000, is worth and represents employing YUV422 form for 0b001, is worth and represents employing for 0b010
YUV444 form, 5 numerical value of reserved 0b011 to 0b111;
The data block partition mode mark BP that 4 bits representMODE, characterize and each chromatic component subframe carried out data block division
Ultimate unit hp×vp, it is worth and represents employing 4 × 4 partition mode for 0b0000, be worth and represent that employing 8 × 4 divides mould for 0b0001
Formula, is worth and represents employing 4 × 8 partition mode for 0b0010, is worth and represents employing 8 × 8 partition mode for 0b0011, reserved from 0b0100
12 numerical value to 0b1111;
The inter prediction enable mark TP that 1 bit representsEN, its value is that 0b0 represents that the coding of present frame does not allow to use interframe
Prediction, its value is that 0b1 represents that the coding of present frame allows to use inter prediction;
The frame level image quality mode PicQ that 2 bits represent, characterizes the subjective quality grade of present frame coding and rebuilding image, its
Value represents lossless mode for 0b00, is worth and represents for 0b01 and damage clear pattern, is worth and represents for 0b10 and damage balanced mode, reserved
0b11;If present frame uses lossless mode, then its frame level quantization step QStep value is 1;If present frame uses and damages clear mould
Formula, then its frame level quantization step QStep value is 2;If present frame uses and damages balanced mode, then its frame level quantization step is
QStep value is 4;It is that QStep takes the logarithm by 2 the integer obtained that the frame level of present frame quantifies shift amount shift;
The frame number FrameN that 16 bits represent;
(3) from current video frame, one uncoded chromatic component subframe of acquisition is as current chroma component sub-frame, by current color
Degree component sub-frame is divided into the two-dimensional rectangle data block to be encoded of multiple h × v size, and calculates total number of its data block
Nblk;
(4) from current chroma component sub-frame, a uncoded two-dimensional rectangle data block work is obtained by from the order of raster scanning
For current block;
(5) calculate current block coding information under each candidate coding pattern and rebuild data, and from effective candidate code mould
Formula is chosen final coding mode and finally rebuilds data;
(6) according to the final coding mode of current block, the coding information of current block is write code stream;
(7) repeat step (4) to (6) and complete coding and the reconstruction of all data blocks in current chroma component sub-frame;
(8) to current video frame written into code stream carry out bit padding to realize byte-aligned;
(9) repeat step (3) to (8) and complete coding and the reconstruction of all chromatic component subframes in current video frame;
(10) code stream producing current video frame carries out frame synchronization head escape process, exports final compressed bit stream.
2. screen video compression method as claimed in claim 1, it is characterised in that in described step (2), frame originating point information is by such as
Under be sequentially written in code stream:
(2-1) at byte-aligned, frame sync identifications SyncF is write;
(2-2) write image resolution ratio mark PicR;
(2-3) write chrominance space format identification (FID) ColorF;
(2-4) writing data blocks partition mode mark BPMODE;
(2-5) write inter prediction enables mark TPEN;
(2-6) write frame level image quality mode PicQ;
(2-7) write frame number FrameN.
3. screen video compression method as claimed in claim 1, it is characterised in that described step (3) comprises the steps of:
(3-1) first uncoded chromatic component is obtained by Y-component subframe, U component sub-frame, the order of V component subframe
Frame, HkAnd VkBe respectively current chroma component sub-frame in the horizontal direction with the data amount check on vertical direction, k is that current chroma divides
The index of quantum frame, k value is 1 expression Y-component subframe, and k value is 2 expression U component sub-frame, and k value is 3 expression V component subframes;
(3-2) then according to BPMODEObtain data block and divide ultimate unit hP×vP, hPThe data amount check divided for horizontal direction,
vPThe data amount check divided for vertical direction;
(3-3) then ultimate unit h is divided according to data blockP×vPBy the order of raster scanning, current chroma component sub-frame is drawn
Being divided into the two-dimensional rectangle data block to be encoded of multiple h × v size, h and v is respectively the data block through dividing in the horizontal direction
Data amount check above and on vertical direction;
(3-4) data block number H of current chroma component sub-frame horizontal direction finally it is calculated by formula (1)blk, by formula
(2) data block number V of current chroma component sub-frame vertical direction it is calculatedblk, it is calculated current chroma by formula (3)
Total number N of data block of component sub-frameblk:
Nblk=Hblk×Vblk (3)。
4. screen video compression method as claimed in claim 1, it is characterised in that the candidate code mould in described step (5)
Formula includes interframe associative mode IC_MODE:
This pattern is used to encode, for each initial data P in current block, its predictive value PredICFor previous coded frame
In identical chromatic component subframe and the reconstruction data of same spatial location, its prediction residual DICIt is calculated by formula (4), is predicted
Sign of the residues SignICIt is calculated by formula (5), is quantified residual error QDICCalculate by formula (6), formula (7) and formula (8)
To, rebuild data RICIt is calculated by formula (9);In formula (5), SignICValue be the symbol of 0 expression prediction residual for just,
Value be the symbol of 1 expression prediction residual be negative;In formula (6), QDIC TmpQuantify residual error for IC_MODE, it calculates process temporarily
The quantization step QStep2 that halves used is calculated by formula (8), halves shift amount shift2 and is taken the logarithm by 2 by QStep2
It is calculated;In formula (7), work as QDICValue is 1 and QStep2 value when being 2, by QDICPressure is set to 0, QD in the case of otherIC
Keep constant;In formula (8), QStep is frame level quantization step;
DIC=P-PredIC (4)
Use this pattern to encode, need further exist for enrolling following coding information code stream:
The IC_MODE coding mode mark ModeID that 2 bits representIC, its value is 0b00;
The stand growth model mark AZFlag that 1 bit representsIC, its value is 0b0, represents that current block exists non-zero QDIC, its value is 0b1,
Represent the QD of current blockICIt is all zero;
The each QD of current block that 3 bits representICNumber of coded bits QDBitsIC, this coding information only need to be at AZFlagICValue
Enrolling code stream during for 0b0, its value is calculated by formula (10), QD in formulaIC maxFor all QD of current blockICIn maximum;
The Sign that 1 bit representsICAnd QDBitsICThe QD that individual bit representsIC, all Sign of current blockICAnd QDICOnly need to be
QDBitsICCode stream is enrolled during more than 0;
The consecutive identical monodrome block identification ContiFlag that 1 bit representsIC, its value is that 0b0 represents and only carries out current stand growth model
Coding, its value is that 0b1 represents the continuous ContiCnt started from current blockICIndividual stand growth model encodes, and this coding information is only
Need to be at AZFlagICCode stream is enrolled when value is for 0b1;
ContiCntBitsICThe ContiCnt that individual bit representsICValue after subtracting 1, wherein ContiCntBitsICBy formula (11)
Being calculated, this coding information only need to be at ContiFlagICCode stream is enrolled when value is for 0b1;
The ContiCntBits that 2 bits representICCode identification ContiCntBitsIdxIC, ContiCntBitsIdxICBy public affairs
Formula (12) is calculated, and this coding information only need to be at ContiFlagICCode stream is enrolled when value is for 0b1;
According to encoding information above, the continuous blocks using IC_MODE to start current block or current block carry out the volume that coding consumes
Code bit number CBitsICIt is calculated by formula (13), and current block selects IC_MODE as its effective candidate coding pattern
Needing to meet two conditions, first condition is the present frame inter prediction enable mark TP written into code streamENValue is 0b1, the
Two conditions are QDBitsICIt is not more than 7;
5. screen video compression method as claimed in claim 1, it is characterised in that the candidate code mould in described step (5)
Formula includes monodrome raw mode SO_MODE:
Using this pattern to encode, current block is not predicted and quantifies, and its all initial datas and all reconstruction data are all
Equal, it is designated as monodrome PS;
Use this pattern to encode, need further exist for enrolling following coding information code stream:
The SO_MODE coding mode mark ModeID that 2 bits representSO, it is worth for 0b01;
Monodrome coded system CodPsFlag that 1 bit representsSO, its value is the upper block that 0b0 represents that current block space is adjacent
Coding mode is monodrome P of SO_MODE and upper blockSMonodrome P with current blockSEqual, monodrome P of current blockSDo not enroll code
Stream, decoding end obtains P from upper blockS, its value is monodrome P that 0b1 represents current blockSTo enroll code stream, decoding end is directly from code stream
Obtain PS;
Monodrome P that 8 bits representS, this coding information is only at CodPsFlagSOCode stream is enrolled when value is for 0b1;
The consecutive identical monodrome block identification ContiFlag that 1 bit representsSOEnrolling code stream, its value is that 0b0 represents only current block
Enrolling code stream, current block end-of-encode, its value is the continuous ContiCnt that 0b1 represents headed by current blockSOIndividual block uses SO_
MODE carries out encoding and P between each blockSEqual, following coding information also to be enrolled code stream by current block;
ContiCntBitsSOThe ContiCnt that individual bit representsSOValue after subtracting 1, ContiCntBitsSOCalculate by formula (14)
Obtaining, this coding information is only at ContiFlagSOValue be to enroll code stream during 0b1;
The ContiCntBits that 2 bits representSOCode identification ContiCntBitsIdxSO, ContiCntBitsIdxSOWith
ContiCntBitsSOCorresponding relation such as formula (15) shown in;
According to encoding information above, the continuous blocks using SO_MODE to start current block or current block carry out the volume that coding consumes
Code bit number CBitsSOBeing calculated by formula (16), current block selects SO_MODE as its effective candidate coding pattern only
One condition, i.e. requires that current block is monodrome block, and its all initial datas are the most equal;
CBitsSO=2+1+8 × CodPsFlagSO+1+ContiFlagSO×(2+ContiCntBitsSO) (16)。
6. screen video compression method as claimed in claim 1, it is characterised in that the candidate code mould in described step (5)
Formula includes horizontal pointwise pattern HP_MODE:
This pattern is used to encode, to each initial data P in current block, when P is in a left side for current chroma component sub-frame
Border, then the predictive value Pred of PHPIt is 128, otherwise PredHPIt is all reconstruction data R of adjacent left-hand position, P spaceL;The prediction of P
Residual error DHPBe calculated by formula (17), prediction residual symbol SignHPIt is calculated by formula (18), is quantified residual error QDHPBy public affairs
Formula (19) is calculated, rebuilds data RHPIt is calculated by formula (20);
DHP=P-PredHP (17)
QDHP=(| DHP|+(QStep > > 1)) > > shift (19)
Use this pattern to encode, need further exist for enrolling following coding information code stream:
The coding mode mark ModeID of the HP_MODE that 3 bits representHP, it is worth for 0b100;
The each QD of current block that 3 bits representHPNumber of coded bits QDBitsHP, its value is calculated by formula (21),
QDHP maxFor all QD of current blockHPIn maximum;
The Sign that 1 bit representsHPAnd QDBitsHPThe QD that individual bit representsHP, all Sign of current blockHPAnd QDHPOnly need to be
QDBitsHPCode stream is enrolled during more than 0;
According to encoding information above, use HP_MODE that current block carries out number of coded bits CBits that coding consumesHPBy formula
(22) being calculated, current block selects HP_MODE as its effective candidate coding pattern only one of which condition, i.e. QDBitsHPNo
More than 7;
7. screen video compression method as claimed in claim 1, it is characterised in that the candidate code mould in described step (5)
Formula includes vertical pointwise pattern VP_MODE:
This pattern is used to encode, to each initial data P in current block, when P is in the upper of current chroma component sub-frame
Border, then the predictive value Pred of PVPIt is set to 128, otherwise PredVPIt is all reconstruction data R of position adjacent and above, P spaceU;P's is pre-
Survey residual error DVPBe calculated by formula (23), prediction residual symbol SignVPIt is calculated by formula (24), is quantified residual error QDVPPress
Formula (25) is calculated, rebuilds data RVPIt is calculated by formula (26);
DVP=P-PredVP (23)
QDVP=(| DVP|+(QStep > > 1)) > > shift (25)
Use this pattern to encode, need further exist for enrolling following coding information code stream:
The coding mode mark ModeID of the VP_MODE that 3 bits representVP;
The each QD of current block that 3 bits representVPNumber of coded bits QDBitsVP, its value is calculated by formula (27),
QDVP maxFor all QD of current blockVPIn maximum;
The Sign that 1 bit representsVPAnd QDBitsVPThe QD that individual bit representsVP, all Sign of current blockVPAnd QDVPOnly need to be
QDBitsVPCode stream is enrolled during more than 0;
According to encoding information above, use VP_MODE that current block carries out number of coded bits CBits that coding consumesVPBy formula
(28) being calculated, current block selects VP_MODE as its effective candidate coding pattern only one of which condition, i.e. QDBitsVPNo
More than 7;
8. screen video compression method as claimed in claim 1, it is characterised in that the candidate code mould in described step (5)
Formula includes level of complexity pattern CH_MODE:
Using this pattern to encode, each row of data of current block can be with selection level prediction quantification manner or direct quantification manner
Encode:
In all data row using horizontal forecast quantification manner, to each initial data P, when P is in current chroma component
The left margin of subframe, then the predictive value Pred of PCHIt is set to 128, otherwise PredCHIt it is all the reconstruction number of adjacent left-hand position, P space
According to RL;Prediction residual D of PCHBe calculated by formula (29), prediction residual symbol SignCHIt is calculated by formula (30), is quantified
Residual error QDCHIt is calculated by formula (31), is rebuild data RCHIt is calculated by formula (32);
In all data row using direct quantification manner, each of which initial data P, directly presses formula (33) and calculates quantization number
According to QPCH, and press reconstruction data R of formula (34) calculating PCH;
DCH=P-PredCH (29)
QDCH=(| DCH|+(QStep > > 1)) > > shift (31)
QPCH=(P+ (QStep > > 1)) > > shift (33)
RCH=QPCH< < shift (34)
Use this pattern to encode, need further exist for enrolling following coding information code stream:
The CH_MODE coding mode mark ModeID that 4 bits representCH, it is worth for 0b1100;
Row coded system RowMode that often 1 bit of row representsCH, it is worth and represents that current line uses horizontal forecast quantification manner for 0b0
Encoding, its value is that 0b1 represents that current line uses direct quantification manner to encode;
The each QD of current block that 3 bits representCHNumber of coded bits QDBitsCH, it is calculated by formula (35), QDCH maxFor
The all QD of current blockCHIn maximum, QDBitsCHThe data row of employing horizontal forecast quantification manner only need to be there is at current block
In the case of enroll code stream;
The Sign that 1 bit representsCHAnd QDBitsCHThe QD that individual bit representsCH, all of SignCHAnd QDBitsCHOnly need
QDBitsCHCode stream is enrolled in the case of more than 0;
QPBitsCHThe QP that individual bit representsCH, wherein QPBitsCHIt is calculated by formula (36), all QPCHOnly need to be at current block
Code stream is enrolled in the case of there is the data row of the direct quantification manner of employing;
According to encoding information above, use CH_MODE that current block carries out number of coded bits CBits that coding consumesCHBy formula
(37) being calculated, in formula, n is the number of data lines that current block selects direct quantification manner;Current block selects CH_MODE as it
Effectively the unique conditional of candidate coding pattern is QDBitsCHIt is not more than 7;
QPBitsCH=8-shift (36)
9. screen video compression method as claimed in claim 1, it is characterised in that the candidate code mould in described step (5)
Formula includes complicated vertically pattern CV_MODE:
Using this pattern to encode, every column data of current block can select vertically to predict quantification manner or direct quantification manner
Encode:
In all data row using vertically prediction quantification manner, to each initial data P, when P is in current chroma component
The coboundary of subframe, then the predictive value Pred of PCVIt is set to 128, otherwise PredCVIt it is all the reconstruction number of position adjacent and above, P space
According to RU;Prediction residual D of PCVBe calculated by formula (38), prediction residual symbol SignCVIt is calculated by formula (39), is quantified
Residual error QDCVIt is calculated by formula (40), is rebuild data RCVIt is calculated by formula (41);
In all data row using direct quantification manner, each of which initial data P, directly presses formula (42) and calculates quantization number
According to QPCV, and press reconstruction data R of formula (43) calculating PCV;
DCV=P-PredCV (38)
QDCV=(| DCV|+(QStep > > 1)) > > shift (40)
QPCV=(P+ (QStep > > 1)) > > shift (42)
RCV=QPCV< < shift (43)
Use this pattern to encode, need further exist for enrolling following coding information code stream:
The CV_MODE coding mode mark ModeID that 4 bits representCV, it is worth for 0b1101;
Row coded system ColMode that 1 bit of each column representsCV, it is worth and represents that quantification manner is vertically predicted in employing when prostatitis for 0b0
Encoding, its value is that 0b1 represents when prostatitis uses direct quantification manner to encode;
The each QD of current block that 3 bits representCVNumber of coded bits QDBitsCV, it is calculated by formula (44), QDCV maxFor
The all QD of current blockCVIn maximum, QDBitsCVOnly need to exist at current block uses the data of vertically prediction quantification manner to arrange
In the case of enroll code stream;
The Sign that 1 bit representsCVAnd QDBitsCVThe QD that individual bit representsCV, all of SignCVAnd QDBitsCVOnly need
QDBitsCVCode stream is enrolled in the case of more than 0;
QPBitsCVThe QP that individual bit representsCV, wherein QPBitsCVIt is calculated by formula (45), all QPCVOnly need to be at current block
Exist and use the data of direct quantification manner to enroll code stream in the case of arranging;
According to encoding information above, use CV_MODE that current block carries out number of coded bits CBits that coding consumesCVBy formula
(46) being calculated, in formula, m is the data columns that current block selects direct quantification manner;Current block selects CV_MODE as it
Effectively the unique conditional of candidate coding pattern is QDBitsCVIt is not more than 7;
QPBitsCV=8-shift (45)
10. screen video compression method as claimed in claim 1, it is characterised in that the candidate code mould in described step (5)
Formula includes self adaptation pointwise Mode A P_MODE:
This pattern is used to encode, to each initial data P in current block, its predictive value PredAPCalculate by formula (47)
Obtain, prediction residual D of PAPBe calculated by formula (48), prediction residual symbol SignAPIt is calculated by formula (49), is measured
Change residual error QDAPIt is calculated by formula (50), is rebuild data RAPIt is calculated by formula (51);In formula (47), RLEmpty for P
Between the reconstruction data of adjacent left-hand position, RUReconstruction data, R for position adjacent and above, P spaceULFor position, adjacent upper left, P space
The reconstruction data put;
DAP=P-PredAP (48)
QDAP=(| DAP|+(QStep > > 1)) > > shift (50)
Use this pattern to encode, need further exist for enrolling following coding information code stream:
The AP_MODE coding mode mark ModeID that 4 bits representAP, it is worth for 0b1110;
The each QD of current block that 3 bits representAPNumber of coded bits QDBitsAP, its value is calculated by formula (52),
QDAP maxFor all QD of current blockAPIn maximum;
The Sign that 1 bit representsAPAnd QDBitsAPThe QD that individual bit representsAP, all Sign of current blockAPAnd QDAPOnly need to be
QDBitsAPCode stream is enrolled during more than 0;
According to encoding information above, use AP_MODE that current block carries out number of coded bits CBits that coding consumesAPBy formula
(53) being calculated, current block selects AP_MODE to have two conditions as its effective candidate coding pattern, and first condition is for working as
The front piece of coboundary data not comprising current chroma component sub-frame and left margin data, second condition is QDBitsAPIt is not more than
7;
11. screen video compression methods as claimed in claim 1, it is characterised in that the candidate code mould in described step (5)
Formula includes direct quantitative mode DQ_MODE:
Using this pattern to encode, current block is not predicted, if the PicQ value in frame level coding information is 2 and current chroma
Component sub-frame is Y-component subframe, then this pattern employing level halves quantification manner realization, and otherwise this pattern uses all sides of quantization
Formula realizes;
When DQ_MODE uses whole quantification manners, to initial data P each in current block, first press formula (54) and calculate the quantization of P
Data QPDQ1, then press formula (55) calculating reconstruction data RDQ1;
When DQ_MODE uses whole quantification manners, need further exist for enrolling following coding information code stream:
The coding mode mark ModeID of the DQ_MODE that 4 bits representDQ, it is worth for 0b1111;
QPBitsDQ1The QP that individual bit representsDQ1, quantized data number of coded bits QPBitsDQ1It is calculated by formula (56);
According to encoding information above, DQ_MODE uses whole quantification manners that current block carries out the number of coded bits that coding consumes
CBitsDQ1It is calculated by formula (57);
QPDQ1=(P+ (QStep > > 1)) > > shift (54)
RDQ1=QPDQ1< < shift (55)
QPBitsDQ1=8-shift (56)
CBitsDQ1=4+h × v × QPBitsDQ1 (57)
When DQ_MODE employing level halves quantification manner, then current block is first often taken by order from left to right in the horizontal direction
Adjacent two data P(2*i,j)And P(2*i+1,j), calculate their average as a new data P '(i,j), as shown in formula (58),
I and j is respectively horizontal level index and the vertical position index of new data block, for being in the number of chromatic component subframe right margin
According to block, if its h is odd number, often go last P(2*i,j)There is no paired P(2*i+1,j), then directly by P '(i,j)It is set to
P(2*i,j);All P ' that current block obtains after the resolution of horizontal direction halves form new data block, in new data block
Each data P ', first calculates its quantized data QP by formula (59)DQ2, then calculate its reconstruction data R ' by formula (60), finally press
Formula (61) calculates the P corresponding with P '(2*i,j)And P(2*i+1,j)Two reconstruction data RDQ2 (2*i,j)And RDQ2 (2*i+1,j);
P'(i,j)=(P(2*i,j)+P(2*i+1,j)) > > 1 (58)
QPDQ2=(P'+ (QStep > > 1)) > > shift (59)
R'=QPDQ2< < shift (60)
When DQ_MODE employing level halves quantification manner, need further exist for enrolling following coding information code stream:
The coding mode mark ModeID of the DQ_MODE that 4 bits representDQ, it is worth for 0b1111;
QPBitsDQ2The QP that individual bit representsDQ2, quantized data number of coded bits QPBitsDQ2It is calculated by formula (62);
According to encoding information above, DQ_MODE employing level halves quantification manner and current block carries out the encoding ratio that coding consumes
Special number CBitsDQ2It is calculated by formula (63);
QPBitsDQ2=8-shift (62)
CBitsDQ2=4+ ((h+1) > > 1) × v × QPBitsDQ2 (63)。
The 12. such as claim 4 screen video compression methods stated to any one of claim 11, it is characterised in that described step
(5) final coding mode can be chosen according to the following steps:
If (5-1) SO_MODE is effective candidate coding pattern of current block or is the consecutive identical monodrome block started from current block
Effective candidate coding pattern, then directly as current block or the final coding mode of continuous blocks that starts from current block,
And the data set of rebuilding under this pattern is become the final reconstructed block of correspondence position, and termination pattern selects in advance;
If (5-2) IC_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then calculates and work as
Front piece uses the bit number CBits that this pattern-coding need to consumeIC;If effective candidate coding pattern that IC_MODE is current block and
The quantization residual error of current block is zero, then the most also quantify residual error complete zero for IC_MODE from next BOB(beginning of block) detection subsequent block
Block, until quantization residual error non-full zero block or last block being detected, and directly using IC_MODE as current block or from working as
The final coding mode of the continuous blocks of front BOB(beginning of block), by under this pattern rebuild data set become correspondence position final reconstruction
Block, and termination pattern selects in advance;
If (5-3) HP_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then calculates and work as
Front piece uses the bit number CBits that this pattern-coding need to consumeHP;If effective candidate coding pattern that HP_MODE is current block and
The quantization residual error of current block is zero, then directly as the final coding mode of current block, and by the reconstruction under this pattern
The final reconstructed block of data composition current block, and terminate current block model selection in advance;
If (5-4) VP_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then calculates and work as
Front piece uses the bit number CBits that this pattern-coding need to consumeVP;If effective candidate coding pattern that VP_MODE is current block and
The quantization residual error of current block is zero, then directly as the final coding mode of current block, and by the reconstruction under this pattern
The final reconstructed block of data composition current block, and terminate current block model selection in advance;
If (5-5) AP_MODE is effective candidate coding pattern of current block and current block exists non-zero quantised residual error, then calculates and work as
Front piece uses the bit number CBits that this pattern-coding need to consumeAP;If effective candidate coding pattern that AP_MODE is current block and
The quantization residual error of current block is zero, then directly as the final coding mode of current block, and by the reconstruction under this pattern
The final reconstructed block of data composition current block, and terminate current block model selection in advance;
(5-6) it is unsatisfactory for becoming condition or its CBits of the effective candidate coding pattern of current block as HP_MODEHPMore than threshold value
TH1, first calculates and uses CH_MODE that current block is predicted the coding information quantified, and becomes if then CH_MODE is satisfied
The condition of the effective candidate coding pattern of current block, then calculate the bit using CH_MODE that current block carries out coding needs consumption
Number CBitsCH, wherein the span of TH1 is [6, h × v × QPBitsCH];The coding staff that current block is often gone under CH_MODE
Formula RowModeCHDetermining according to formula (64), its intermediate value is that 1 expression current line uses direct quantification manner, and value is that 0 expression is current
Row uses horizontal forecast quantification manner,Represent current line maximum quantization residual error QDCH row-maxNeed
Minimum number of coded bits, threshold value THCHSpan be [0,7];
(5-7) it is unsatisfactory for becoming condition or its CBits of the effective candidate coding pattern of current block as VP_MODEVPMore than threshold value
TH2, first calculates and uses CV_MODE that current block is predicted the coding information quantified, and becomes if then CV_MODE is satisfied
The condition of the effective candidate coding pattern of current block, then calculate the bit using CV_MODE that current block carries out coding needs consumption
Number CBitsCV, wherein the span of TH2 is [6, h × v × QPBitsCV];Current block is the coding staff of each column under CV_MODE
Formula ColModeCVDetermining according to formula (65), its intermediate value is that 1 expression is when prostatitis uses direct quantification manner, and value is that 0 expression is current
Row use and vertically predict quantification manner,Represent when prostatitis maximum quantization residual error QDCV col-maxNeed
Minimum number of coded bits, threshold value THCVSpan be [0,7];
If (5-8) DQ_MODE of current chroma component sub-frame uses whole quantification manners, then determine current block according to formula (66)
Whether calculate the quantization of DQ_MODE and rebuild data, ENDQ1Value is that 1 expression current block calculates the quantization of DQ_MODE and rebuilds number
According to, value is that 0 expression current block does not calculate the quantization of DQ_MODE and rebuilds data, CBitsMINRepresent in calculated each pattern and compile
Code need to consume the minima of bit number;
If the DQ_MODE use level of current chroma component sub-frame halves quantification manner, then determine that current block is by formula (67)
The quantization of no calculating DQ_MODE and reconstruction data, ENDQ2Value is that 1 expression current block calculates the quantization of DQ_MODE and rebuilds data,
Value is that 0 expression current block does not calculate the quantization of DQ_MODE and rebuilds data, TotalBitsYRepresent that current Y-component subframe disappears
The number of coded bits of consumption, η is coefficient of comparisons, and less than 1.0, typical value scope is [0.2,0.8];
Current block is after formula (66) or formula (67) judge, if ENDQ1Or ENDQ2Value is 1, then calculate current block and use DQ_
The quantization of MODE and reconstruction data, and calculate the bit number CBits using DQ_MODE to carry out coding needs consumptionDQ, its value is
CBitsDQ1Or CBitsDQ2;
(5-9) from the effective candidate coding pattern estimated, select finally to encode mould by the principle consuming number of coded bits minimum
Formula, in the case of number of coded bits is identical, selects the coding mode ident value final coding mode of less conduct;Current block is existed
Data set of rebuilding under final coding mode becomes the final reconstructed block of correspondence position.
13. screen video compression methods as claimed in claim 4, it is characterised in that described step (6) if in current block
Final coding mode is interframe associative mode IC_MODE, the most as follows by coding information write code stream:
A coding mode is identified ModeID by ()ICWrite code stream;
B stand growth model is identified AZBFlag by ()ICWrite code stream;
If the AZBFlag of (c) write code streamICValue is 0b1, then jump to step (f);
D () will quantify residual error number of bits QDBitsICWrite code stream;
E () first presses the order of raster scanning by all of prediction residual symbol SignICWrite code stream, more in the same order by institute
Some quantization residual errors QDICWrite code stream, finally terminates the code stream write of current block;
(f) write code stream consecutive identical monodrome block identification ContiFlagICIf, ContiFlagICValue is 0b0, then terminate current block
Code stream write;
G () is first by ContiCntICNumber of coded bits mark ContiCntBitsIdxICWrite code stream, then by ContiCntICSubtract
1 write code stream.
14. screen video compression methods as claimed in claim 5, it is characterised in that described step (6) if in current block
Final coding mode is monodrome raw mode SO_MODE, the most as follows by coding information write code stream:
A coding mode is identified ModeID by ()SOWrite code stream;
B () is by monodrome coded system CodPsFlagSOWrite code stream;
If (c) CodPsFlagSOValue is equal to 0b1, then by single-value data PsWrite code stream;
D () is by consecutive identical monodrome block identification ContiFlagSOWrite code stream;
If (e) ContiFlagSOValue is equal to 0b1, the most first by ContiCntSONumber of coded bits mark ContiCntBitsIdxSO
Write code stream, then by ContiCntSOThe write code stream that subtracts 1.
15. screen video compression methods as claimed in claim 6, it is characterised in that described step (6) if in current block
Final coding mode is horizontal pointwise pattern HP_MODE, the most as follows by coding information write code stream:
A coding mode is identified ModeID by ()HPWrite code stream;
B () will quantify residual error number of bits QDBitsHPWrite code stream;
If (c) QDBitsHPValue, more than 0, the most first presses the order of raster scanning by all of for current block prediction residual symbol SignHPWrite
Enter code stream, more in the same order by all of for current block quantization residual error QDHPWrite code stream.
16. screen video compression methods as claimed in claim 7, it is characterised in that described step (6) if in current block
Final coding mode is vertical pointwise pattern VP_MODE, the most as follows by the coding information write code stream of current block:
A coding mode is identified ModeID by ()VPWrite code stream;
B () will quantify residual error number of bits QDBitsVPWrite code stream;
If (c) QDBitsVPValue, more than 0, the most first presses the order of raster scanning by all of prediction residual symbol SignVPWrite code
Stream, more in the same order by all of quantization residual error QDVPWrite code stream.
17. screen video compression methods as claimed in claim 8, it is characterised in that described step (6) if in current block
Final coding mode is level of complexity pattern CH_MODE, the most as follows by the coding information write code stream of current block:
A coding mode is identified ModeID by ()CHWrite code stream;
B () presses order from top to bottom by coded system RowMode of each row of dataCHWrite code stream;
(c) point following three kinds of situations write code stream:
(c-1) if the RowMode of all write code streamsCHValue is all 0b1, then press the order of raster scanning by all of for current block amount
Change data QPCHWrite code stream;
(c-2) if writing the RowMode of code streamCHValue is all 0b0, first will quantify residual error number of bits QDBitsCHWrite code
Stream;If then QDBitsCHMore than 0, the most first press the order of raster scanning by all of for current block prediction residual symbol SignCHWrite
Enter code stream, more in the same order by all of for current block quantization residual error QDCHWrite code stream;
(c-3) if writing the RowMode of code streamCHValue for 0b0 and all exists for 0b1, first will quantify residual error number of bits
QDBitsCHWrite code stream;If then QDBitsCHMore than 0, the most first press the order of raster scanning by residual for all of for current block prediction
Difference symbol SignCHWrite code stream, more in the same order by all of for current block quantization residual error QDCHWrite code stream;Finally press light
The order of grid scanning is by all of for current block quantized data QPCHWrite code stream.
18. screen video compression methods as claimed in claim 9, it is characterised in that described step (6) if in current block
Final coding mode be complicated vertically pattern CV_MODE, and the information that encoded the most as follows writes code stream:
A coding mode is identified ModeID by ()CVWrite code stream;
B () presses order from left to right by each column coded system ColModeCVWrite code stream;
(c) point following three kinds of situations write code stream:
(c-1) if the ColMode of all write code streamsCVValue is all 0b1, then press the order of raster scanning by all of quantized data
QPCVWrite code stream;
(c-2) if the ColMode of all write code streamsCVValue is all 0b0, first will quantify residual error number of bits QDBitsCVWrite
Enter code stream;If then QDBitsCVMore than 0, the most first press the order of raster scanning by all of for current block prediction residual symbol
SignCVWrite code stream, more in the same order by all of for current block quantization residual error QDCVWrite code stream;
(c-3) if writing the ColMode of code streamCVValue for 0b0 and all exists for 0b1, first will quantify residual error number of bits
QDBitsCVWrite code stream;If then QDBitsCVMore than 0, the most first press the order of raster scanning by residual for all of for current block prediction
Difference symbol SignCVWrite code stream, more in the same order by all of for current block quantization residual error QDCVWrite code stream;Finally press light
The order of grid scanning is by all of for current block quantized data QPCVWrite code stream.
19. screen video compression methods as claimed in claim 10, it is characterised in that described step (6) if in current block
Final coding mode be self adaptation pointwise Mode A P_MODE, encoded the most as follows information write code stream:
A coding mode is identified ModeID by ()APWrite code stream;
B () will quantify residual error number of bits QDBitsAPWrite code stream;
If (c) QDBitsAPValue, more than 0, the most first presses the order of raster scanning by all of prediction residual symbol SignAPWrite code
Stream, more in the same order by all of quantization residual error QDAPWrite code stream.
20. screen video compression methods as claimed in claim 11, it is characterised in that described step (6) if in current block
Final coding mode be direct quantitative mode DQ_MODE, encoded the most as follows information write code stream:
A coding mode is identified ModeID by ()DQWrite code stream;
If b () DQ_MODE uses the implementation all quantified, then press the order of raster scanning by all quantized data QPDQ1Write
Enter code stream;If DQ_MODE employing level halves the implementation of quantization, then press the order of raster scanning by all quantized datas
QPDQ2Write code stream.
21. screen video compression methods as claimed in claim 1, it is characterised in that described step (10) is to present frame code
Stream carries out frame sync identifications escape process, and concrete grammar is as follows:
To each byte after the frame sync identifications of present frame code stream, read the data of this byte and 3 bytes thereafter in order,
Form 4 byte datas FourBytes, the most first read byte and be placed on higher bit position;When FourBytes value is 0xFFFFFFFD, then
In code stream, after 0xFD, insert a byte data, be worth for 0x00, when FourBytes value is 0xFFFFFFFE, then by code stream
In 0xFE replace with 0xFD, and after 0xFD, insert a byte data, be worth for 0x01;Decoding end is entered at present frame code stream
First continuous five byte values all in present frame code stream must be last in 0xFFFFFFFD00 before resolving and rebuilding by row
Byte 0x00 is deleted, and is that in 0xFFFFFFFD01, the 4th byte 0xFD replaces with 0xFE by all continuous five byte values, and will
Last byte 0x01 is deleted.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610447078.7A CN106101703B (en) | 2016-06-20 | 2016-06-20 | A kind of screen video compression method towards digital KVM switcher |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610447078.7A CN106101703B (en) | 2016-06-20 | 2016-06-20 | A kind of screen video compression method towards digital KVM switcher |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106101703A true CN106101703A (en) | 2016-11-09 |
CN106101703B CN106101703B (en) | 2018-11-06 |
Family
ID=57238173
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610447078.7A Active CN106101703B (en) | 2016-06-20 | 2016-06-20 | A kind of screen video compression method towards digital KVM switcher |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106101703B (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107196660A (en) * | 2017-04-24 | 2017-09-22 | 南京数维康信息科技有限公司 | Low power consumption data compression algorithm |
CN107801031A (en) * | 2017-11-09 | 2018-03-13 | 广州物启科技有限公司 | A kind of lossless compression-encoding method to pure three primary colors image data |
CN109510984A (en) * | 2018-10-26 | 2019-03-22 | 西安科锐盛创新科技有限公司 | A kind of compressed encoding quantization method |
CN109561306A (en) * | 2018-10-26 | 2019-04-02 | 西安科锐盛创新科技有限公司 | A kind of bandwidth reduction quantization method |
WO2022217447A1 (en) * | 2021-04-12 | 2022-10-20 | Oppo广东移动通信有限公司 | Video encoding and decoding method and system, and video codec |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1984327A (en) * | 2006-05-16 | 2007-06-20 | 华为技术有限公司 | Video-frequency compression method |
CN101046735A (en) * | 2006-03-30 | 2007-10-03 | 华为技术有限公司 | Video data compression method |
US20100238347A1 (en) * | 2002-10-01 | 2010-09-23 | Avocent Corporation | Video compression system |
CN101976131A (en) * | 2010-10-26 | 2011-02-16 | 深圳市云舒网络技术有限公司 | Dot interlaced sampling algorithm-based keyboard, video and mouse (KVM) system and method |
-
2016
- 2016-06-20 CN CN201610447078.7A patent/CN106101703B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100238347A1 (en) * | 2002-10-01 | 2010-09-23 | Avocent Corporation | Video compression system |
CN101046735A (en) * | 2006-03-30 | 2007-10-03 | 华为技术有限公司 | Video data compression method |
CN1984327A (en) * | 2006-05-16 | 2007-06-20 | 华为技术有限公司 | Video-frequency compression method |
CN101976131A (en) * | 2010-10-26 | 2011-02-16 | 深圳市云舒网络技术有限公司 | Dot interlaced sampling algorithm-based keyboard, video and mouse (KVM) system and method |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107196660A (en) * | 2017-04-24 | 2017-09-22 | 南京数维康信息科技有限公司 | Low power consumption data compression algorithm |
CN107801031A (en) * | 2017-11-09 | 2018-03-13 | 广州物启科技有限公司 | A kind of lossless compression-encoding method to pure three primary colors image data |
CN109510984A (en) * | 2018-10-26 | 2019-03-22 | 西安科锐盛创新科技有限公司 | A kind of compressed encoding quantization method |
CN109561306A (en) * | 2018-10-26 | 2019-04-02 | 西安科锐盛创新科技有限公司 | A kind of bandwidth reduction quantization method |
CN109510984B (en) * | 2018-10-26 | 2021-02-05 | 和宇健康科技股份有限公司 | Compression coding quantization method |
CN109561306B (en) * | 2018-10-26 | 2021-08-06 | 上海九吾尊易信息科技有限公司 | Bandwidth compression quantization method |
WO2022217447A1 (en) * | 2021-04-12 | 2022-10-20 | Oppo广东移动通信有限公司 | Video encoding and decoding method and system, and video codec |
Also Published As
Publication number | Publication date |
---|---|
CN106101703B (en) | 2018-11-06 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106101703B (en) | A kind of screen video compression method towards digital KVM switcher | |
US10805644B2 (en) | Device and method for entropy encoding and decoding | |
CN101132534B (en) | Context-based adaptive variable length coding for adaptive block transforms | |
CN104349171B (en) | The compression of images coding/decoding device and coding and decoding method of a kind of virtually lossless | |
RU2553103C2 (en) | Encoding method, encoder, program product and program application for mobile wireless communication device | |
CN100415002C (en) | Multi-mode multi-viewpoint video signal code compression method | |
CN103596009B (en) | Decoder and coding/decoding method | |
CN101828405A (en) | Image coding device, image decoding device, image coding method, and image decoding method | |
CN103037214A (en) | Video compression method | |
CN106170092A (en) | Fast encoding method for lossless coding | |
CN101095359A (en) | Method for improved entropy coding | |
CN105264888A (en) | Encoding strategies for adaptive switching of color spaces, color sampling rates and/or bit depths | |
CN104853211A (en) | Image compression method and apparatus employing various forms of reference pixel storage spaces | |
CN103220525A (en) | Method and apparatus for encoding and decoding image by using large transformation unit | |
CN101404766B (en) | Multi-view point video signal encoding method | |
JPH10257488A (en) | Image coder and image decoder | |
CN109196866A (en) | For showing the subflow multiplexing of stream compression | |
CN105100814A (en) | Methods and devices for image encoding and decoding | |
CN106165420A (en) | For showing the system and method for the Pingdu detection of stream compression (DSC) | |
CN110365982A (en) | The different transform of intraframe coding selects accelerated method in a kind of multipurpose coding | |
CN101014129A (en) | Video data compression method | |
CN114900691B (en) | Encoding method, encoder, and computer-readable storage medium | |
US9787985B2 (en) | Reduction of spatial predictors in video compression | |
CN102308582A (en) | Method for the segmentation encoding of an image | |
CN1134167C (en) | Data efficient quantization table for digital video signal processor |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |