CN102625091A - Inter prediction method based on AVS - Google Patents

Inter prediction method based on AVS Download PDF

Info

Publication number
CN102625091A
CN102625091A CN2011100297300A CN201110029730A CN102625091A CN 102625091 A CN102625091 A CN 102625091A CN 2011100297300 A CN2011100297300 A CN 2011100297300A CN 201110029730 A CN201110029730 A CN 201110029730A CN 102625091 A CN102625091 A CN 102625091A
Authority
CN
China
Prior art keywords
motion vector
data
reference picture
block
avs
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
Application number
CN2011100297300A
Other languages
Chinese (zh)
Other versions
CN102625091B (en
Inventor
邓磊
呼大明
宋益波
郑海鸥
陈淼
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
National Source Coding Center Digital Audio And Video Frequency Technology (beijing) Co Ltd
Original Assignee
National Source Coding Center Digital Audio And Video Frequency Technology (beijing) Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by National Source Coding Center Digital Audio And Video Frequency Technology (beijing) Co Ltd filed Critical National Source Coding Center Digital Audio And Video Frequency Technology (beijing) Co Ltd
Priority to CN201110029730.0A priority Critical patent/CN102625091B/en
Publication of CN102625091A publication Critical patent/CN102625091A/en
Application granted granted Critical
Publication of CN102625091B publication Critical patent/CN102625091B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention provides an inter prediction method based on the AVS, comprising dividing a frame which requires an inter prediction into several macro blocks, and carrying out an inter prediction on every macro block successively. For each macro block, the inter prediction comprises the following steps of: reading the corresponding motion vector of the current macro block, dividing the current macro block into several sub-blocks which are corresponded to the motion vector and carrying out a motion compensation, for each sub-block, when the location directed by the motion vector is beyond a frame boundary, reading the data of a reference image within the frame boundary from an outer memory, and carrying out a data supplement according to the motion vector and the read data within the frame boundary to obtain an integral reference image. Interpolation arithmetic is carried out according to the reference image and the motion vector to restore the current macro block. The inter prediction method of the invention has the advantages of reducing the bandwidth occupied by accessing the outer memory greatly, decreasing the number of accesses to the outer memory, and reducing the outer memory space occupied by storing reference frames.

Description

A kind of inter-frame prediction method based on AVS
Technical field
The present invention relates to the source coding technique field, specifically, the present invention relates to a kind of inter-frame prediction method.
Background technology
Advanced audio/video encoding standard (English is Audio Video Coding Standard, abbreviates the AVS standard among this paper as) is the second generation source encoding standard that China possesses independent intellectual property right." information source " is information " source ", and the emphasis problem that source coding technique solves is the encoding compression problem of digital audio/video mass data (being primary data, information source), so also claim the digital audio/video encoding and decoding technique.Obviously, it is the prerequisite of links such as digital information transmission, storage, broadcast thereafter, so the source encoding standard is the general character basic standard of digital audio/video industry.
In the AVS standard, frame (frame) is the expression of vision signal spatial information, is made up of a luma samples matrix (Y) and two chroma sample matrixes (Cb and Cr).Inter prediction (inter prediction) is to use early decoding image (or field) to generate the process of present image (or field) sample predicted value.
Typical A VS decode structures has adopted motion prediction compensation, inverse transformation, inverse quantization and the entropy decoding in time and space.In video code flow to be decoded, include following three kinds of coded images:
In-frame encoding picture (I image): only use the image self-information to encode, when decoding not with reference to other images;
Forward predictive coded image (P image): the P image is to predict one or more I images or P image forward, and therefore if certain of front does not exist with reference to I image or P image, then this P image can not be decoded;
Bidirectionally predictive coded picture (B image): can be simultaneously forward with back forecast one frame or multiframe decoded I image or P image; Therefore when decoding B image, need decoding earlier to obtain on DISPLAY ORDER thereafter I image or P view data, can cause the inconsistent of decoding order and DISPLAY ORDER like this.
Can find out that the encoding-decoding process of P image and B image all need pass through inter prediction and handle.In cataloged procedure; If present image is P image or B image; Need to carry out inter prediction according to corresponding reference picture; Calculate and store the motion vector (motion vector be by present image point to reference picture, its value be the skew of current block and reference block in image coordinate) of present image with respect to reference picture.When decoding, only need just can recover said present image like this according to said motion vector and reference picture.The inter prediction technology can effectively reduce time redundancy; And in the AVS standard; Also further introduced new technological means such as becoming piece size, multi-reference frame, direct and symmetrical predictive mode, unrestricted motion vector, picture element interpolation, thereby obtained higher code efficiency to motion compensation.Yet above-mentioned new technological means has also increased amount of calculation and memory bandwidth when improving code efficiency.
At present, high performance AVS decoder generally uses hardware to realize, decoded frame can be deposited in the reference data of external memory as other frame of decoding, when inter prediction, just from external memory, reads these reference datas.
In the AVS standard, decoder is divided into several macro blocks with a two field picture, successively each macro block is carried out inter prediction.Each macro block has four kinds of partition modes.As shown in Figure 1, four kinds of partition modes are respectively: 1 16 * 16 luminance block and corresponding chrominance block, 2 16 * 8 luminance block and corresponding chrominance block, 28 * 16 luminance block and corresponding chrominance block, 48 * 8 luminance block and corresponding chrominance block.The all corresponding motion vector separately of each luminance block and chrominance block is for use in motion compensation.The AVS standard adopts four kinds of macro-block partition modes, can improve code efficiency.But because the macro block of different patterns, the location of pixels of the required reference picture that reads and number have nothing in common with each other when carrying out inter prediction, and therefore, this change piece size is also brought to inter prediction can more challenges.
In the prior art, no matter what form is current macro be, all fixing pattern according to 48 * 8 of decoder reads reference picture, promptly is unified into 8 * 8 and carries out motion compensation.Defectives such as this mode is easy to realize, visits external memory often but exist, and the data total amount that from external memory, reads is big.Its reason is: when motion vector is 1/2 pixel or 1/4 pixel, need carry out the interpolation of 1/2nd samples and 1/4th samples to brightness (colourity), and the required reference picture of the interpolation of 1/2nd samples and 1/4th samples is more; In some location of interpolation; What need reads 12 * 12 individual reference pixel, therefore, and when bi-directional predicted; A macro block is carried out inter prediction need read 12 * 12 * 4 * 2=1152 pixel, the i.e. data of 1152bytes.That is to say, a macro block is carried out inter prediction, just need from external memory, read the data of 1152bytes, and in fact have some redundant datas in the data of this 1152bytes, cause the memory access waste of bandwidth, hardware spending increases.On the other hand and since at every turn all the mode reads of 48 * 8 of cases fetch data, make the increased frequency of decoder accesses external memory, this can cause the increase of the total time-delay of memory access.
In addition; In the AVS standard, use unconfined motion vector; That is to say that motion vector reference data pointed can exceed the border of reference picture, in this case the integral sample in should this integer reference data indication position of the service range nearest image of the integral sample that exceeds reference image border is carried out border extension.In the existing AVS decoder, the reference frame after in advance the reference frame border being expanded and will be expanded deposits external memory in.This way bandwidth availability ratio is low, the extra external space that the reference frame after data are augmented simultaneously need take.
At present, the memory access amount of inter prediction accounts for 50% of the total memory access amount of decoder, and wherein the processing time of sub-pixel interpolation computing then accounts for 25% of total decode time.Can find out that inter prediction has become one of the most intensive part of data volume in the AVS codec, also be simultaneously the bottleneck place of whole system.
In sum, currently press for a kind ofly under the prerequisite of the code efficiency that guarantees the AVS standard, can avoid the inter-frame prediction method that reads redundant data, reduces visit external memory number of times based on AVS.
Summary of the invention
The purpose of this invention is to provide a kind ofly under the prerequisite of the code efficiency that guarantees the AVS standard, can avoid the inter-frame prediction method that reads redundant data, reduces visit external memory number of times based on AVS.
For realizing the foregoing invention purpose; The invention provides a kind of inter-frame prediction method based on AVS, this method comprises that the frame that needs are carried out inter prediction is divided into several macro blocks, carries out inter prediction to each macro block successively; For each macro block, inter prediction comprises the following steps:
1) reads the corresponding motion vector of current macro;
2) read reference picture according to motion vector; Comprise following substep:
21) current macro be divided into the corresponding plurality of sub piece of motion vector carry out motion compensation,
22) for every sub-block; When motion vector position pointed exceeds frame boundaries; From external memory, read the data that are positioned at frame boundaries in the reference picture, carry out data according to motion vector with the data that are positioned at frame boundaries that read then and augment, thereby obtain complete reference picture.
3) carry out interpolation arithmetic according to reference picture and motion vector, recover current macro.
Wherein, in the said step 1), also comprise the sub-piece partition mode that from the AVS code stream, reads current macro;
Said step 21) in, divides sub-piece according to the sub-piece partition mode of the current macro that is read.
Wherein, said step 22) in, when motion vector reference data pointed exceeds the reference picture left margin, carries out data with the numerical value of reference picture Far Left one row pixel and augment.
Wherein, said step 22) in, when motion vector reference data pointed exceeds the reference picture right margin, carries out data with the numerical value of reference picture rightmost one row pixel and augment.
Wherein, said step 22) in, when motion vector reference data pointed exceeds the reference picture coboundary, with reference picture topmost the numerical value of delegation carry out data and augment.
Wherein, said step 22) in, when motion vector reference data pointed exceeds the reference picture lower boundary, with reference picture bottom the numerical value of delegation carry out data and augment.
Wherein, Said step 22) in; That the position that motion vector reference data pointed exceeds reference picture is positioned at is upper left, a left side is following, upper right, during the bottom right, carry out data with the value of the upper left angle point of reference picture, lower left corner point, upper right angle point, bottom right corner pixels respectively and augment.
Compared with prior art, the present invention has following technique effect:
1, significantly reduced the shared bandwidth of visit external memory.
2, can reduce the number of times of visit external memory.
3, reduced the shared external space of storage of reference frames.
Description of drawings
Fig. 1 shows the sub-piece partition mode of a macro block in the AVS standard;
Fig. 2 shows the overlapping data of the repetition that occurs when every sub-block reads reference picture; Solid line boxes representes to carry out the sub-piece of motion compensation, and dashed rectangle is represented the pairing reference picture of sub-piece, and grey color part is represented the overlapping data of repetition;
Fig. 3 shows the luminance block interpolation sketch map in the AVS standard;
Fig. 4 shows the chrominance block interpolation sketch map in the AVS standard;
Fig. 5 shows the data interlacing structural representation in the embodiment of the invention 5;
The data that Fig. 6 shows in the embodiment of the invention 6 are augmented structural representation.
Embodiment
Below, in conjunction with accompanying drawing and embodiment the present invention is done description further.
Embodiment 1
According to one embodiment of present invention, a kind of inter-frame prediction method based on AVS is provided.In this method, decoder is divided into several macro blocks with the frame that needs carry out inter prediction, successively each macro block is carried out inter prediction.For each macro block, the inter prediction process comprises the following steps:
The first step: the pattern and corresponding motion vector that from the AVS code stream, read current macro;
Second step: read from external memory according to the pattern of current macro and motion vector and to carry out the required reference picture of inter prediction;
The 3rd step: carry out interpolation arithmetic according to reference picture and motion vector, recover current macro.
Introduce above-mentioned steps below respectively in detail.
One, from the AVS code stream, reads the partition mode and the corresponding motion vector of current macro
In the AVS standard, single macro block can be divided into: 1 16 * 16 luminance block and corresponding chrominance block, 2 16 * 8 luminance block and corresponding chrominance block, 28 * 16 luminance block and corresponding chrominance block, perhaps 48 * 8 luminance block and corresponding chrominance block.Its partition mode can be read from the AVS code stream.Also read all corresponding motion vector separately of each luminance block and chrominance block simultaneously, for use in motion compensation (being inter prediction).
Two, read from external memory according to the pattern of current macro and motion vector and carry out the required reference picture of inter prediction
Present embodiment has adopted the mode of interblock data reusing from external memory, to read reference picture, can avoid like this in a macro block, repeating the reference data that reading section overlaps, and can reduce the bandwidth (memory access bandwidth) of visit external memory effectively.
In the AVS standard, a macro block comprises luminance block (Y) and chrominance block (Cb and Cr), and luminance block (Y) and chrominance block (Cb and Cr) all need be carried out motion compensation to draw the inter prediction result.
Adopt the motion compensation of tree-shaped change piece size in the AVS standard, minimum block size is 8 * 8, need read 12 * 12 reference data.Carry out motion compensation if be unified into 8 * 8, carrying out when bi-directional predicted, need read the data volume of 12 * 12 * 4 * 2=1152bytes.And in fact, all there is the part (as shown in Figure 2) that overlaps in any two 8 * 8 pairing 12 * 12 reference data, and promptly has the data that repeat to read, and has so just consumed more memory access bandwidth.Therefore, present embodiment has designed data reusing mechanism, makes when carrying out interpolation arithmetic, can reuse the overlapping part between two 8 * 8 the reference data.
The buffer memory mem of present embodiment 40 * 96 (40 row, 96 row) size, mem is shared when sub-pixel interpolation brightness and colourity.For luminance block, the address space of buffer memory mem distributes as follows:
1) .0~11 row are used to store forward direction block 0 or block 2, and the partial data of the row that overlap;
2) .12~23 row are used for the storage back to block 0 or block 2, and the partial data of the row that overlap;
3) .24~27 row are used to store the capable partial data of overlapping of forward direction block 1;
4) .28~31 row are used to store the back to the capable partial data of the overlapping of block 1.
Like this, during first 8 * 8 luminance block interpolation, still from external memory, read its reference data of corresponding 12 * 12, during other 8 * 8 luminance block interpolation, reading section reference data from the appropriate address of buffer memory mem then, and from external memory, read all the other reference datas.So just saved the memory access bandwidth of decoder greatly.
For chrominance block Cb, the address space of buffer memory mem distributes as follows:
1) data of the block 0 of .0~4 row storage chrominance C b forward directions;
2) behind the .5~9 row storage chrominance C b to the data of block 0;
3) data of the block 1 of .10~14 row storage chrominance C b forward directions;
4) behind the .15~19 row storage chrominance C b to the data of block 1;
5) data of the block 2 of .20~24 row storage chrominance C b forward directions;
6) behind the .25~29 row storage chrominance C b to the data of block 2;
7) data of the block 3 of .30~34 row storage chrominance C b forward directions;
8) behind the .35~39 row storage chrominance C b to the data of block 3.
For chrominance block Cr, the address space of buffer memory mem distributes as follows:
1) data of the block 0 of .0~4 row storage chrominance C r forward directions;
2) behind the .5~9 row storage chrominance C r to the data of block 0;
3) data of the block 1 of .10~14 row storage chrominance C r forward directions;
4) behind the .15~19 row storage chrominance C r to the data of block 1;
5) data of the block 2 of .20~24 row storage chrominance C r forward directions;
6) behind the .25~29 row storage chrominance C r to the data of block 2;
7) data of the block 3 of .30~34 row storage chrominance C r forward directions;
8) behind the .35~39 row storage chrominance C r to the data of block 3.
Interpolation in luminance block is similar, during to first chrominance block interpolation, from external memory, reads required whole reference datas.During to other chrominance block interpolation, reading section reference data from the appropriate address of buffer memory mem then, and from external memory, read all the other reference datas, thus save the memory access bandwidth of decoder.
Three, carry out interpolation arithmetic according to reference picture and motion vector, recover current macro.
After reading whole reference datas and motion vector, can carry out interpolation arithmetic according to the description of AVS standard 9.9.2.1 part, recover each luminance block and the chrominance block of current macro successively, thereby recover whole current macro.At this moment, the inter prediction of current macro is accomplished.
Embodiment 2
According to embodiments of the invention 2, a kind of inter-frame prediction method based on AVS is provided.In this method, decoder is divided into several macro blocks with the frame that needs carry out inter prediction, successively each macro block is carried out inter prediction.For each macro block, the inter prediction process comprises the following steps:
The first step: the pattern and corresponding motion vector that from the AVS code stream, read current macro;
Second step: read from external memory according to the pattern of current macro and motion vector and to carry out the required reference picture of inter prediction;
The 3rd step: carry out interpolation arithmetic according to reference picture and motion vector, recover current macro.
Wherein, the first step, the 3rd goes on foot all consistent with embodiment 1, repeats no more.
In second step, the mode that present embodiment adopts change piece size to read reads reference data from external memory.From AVS standard 9.9.2.1 part, can find out that when carrying out sub-pixel interpolation, for different motion vectors and different sub-pixel interpolation positions, the number of the reference data that needs is distinct.For example:, only need 8 * 8 reference data, and interpolation 1/4 pixel samples then needs 11 * 11 reference data in the whole pixel samples of interpolation.
Present embodiment is divided into 6 kinds of different types with location of interpolation, and the reference data amount of every type of needs is different, but in decode procedure, has only wherein one type to be performed at synchronization.Which kind of therefore can judge this time belong to interpolation type, thereby determine this memory access amount, to reach the purpose that reduces bandwidth according to the value of motion vector.
The change piece size of luminance block reads
As shown in Figure 3, the required reference pixel number of each interpolation point in the AVS standard (being location of interpolation) is following:
For the interpolation that D is ordered, the reference pixel that needs is (0,0), and the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 8 * 8;
For the interpolation that b is ordered, the reference pixel that needs is (1,0), (0,0), and (1,0), (2,0), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 11 * 8;
For the interpolation that h is ordered, the reference pixel that needs is (0 ,-1), (0,0), and (0,1), (0,2), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 8 * 11;
For the interpolation that j is ordered, the reference pixel that needs is (1 ,-1), (0 ,-1), (1 ,-1), (2 ,-1); (1,0), (0,0), (1,0), (2,0), (1; 1), (0,1), (1,1), (2,1), (1; 2), (0,2), (1,2), (2,2), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 11 * 11;
For the interpolation that a is ordered, the reference pixel that needs is (2,0), (1,0), and (0,0), (1,0), (2,0), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 12 * 8;
For the interpolation that c is ordered, the reference pixel that needs is (1,0), (0,0), and (1,0), (2,0), (3,0), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 12 * 8;
For the interpolation that d is ordered, the reference pixel that needs is (0 ,-2), (0 ,-1), and (0,0), (0,1), (0,2), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 8 * 12;
For the interpolation that n is ordered, the reference pixel that needs is (0 ,-1), (0,0), and (0,1), (0,2), (0,3), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 8 * 12;
For e, g, the interpolation that p, r are ordered, the reference pixel that needs is identical with the j point, and the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 11 * 11;
For the interpolation that f is ordered, the reference pixel that needs is (1 ,-2), (0 ,-2), (1 ,-2), (2 ,-2), (1 ,-1); (0 ,-1), (1 ,-1), (2 ,-1), (1,0), (0,0), (1; 0), (2,0), (1,1), (0,1), (1,1), (2; 1), (1,2), (0,2), (1,2), (2,2), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 11 * 12;
For the interpolation that i is ordered, the reference pixel that needs is (2 ,-1), (2,0), (2,1), (2,2), (1 ,-1); (1,0), (1,1), (1,2), (0 ,-1), (0,0), (0; 1), (0,2), (1 ,-1), (1,0), (1,1), (1; 2), (2 ,-1), (2,0), (2,1), (2,2), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 12 * 11;
For the interpolation that k is ordered, the reference pixel that needs is (1 ,-1), (1,0), (1,1), (1,2), (0 ,-1); (0,0), (0,1), (0,2), (1 ,-1), (1,0), (1; 1), (1,2), (2 ,-1), (2,0), (2,1), (2; 2), (3 ,-1), (3,0), (3,1), (3,2), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 12 * 11;
For the interpolation that q is ordered, the reference pixel that needs is (1 ,-1), (0 ,-1), (1 ,-1), (2 ,-1), (1,0); (0,0), (1,0), (2,0), (1,1), (0,1), (1; 1), (2,1), (1,2), (0,2), (1,2), (2; 2), (1,3), (0,3), (1,3), (2,3), the reference pixel matrix size that corresponding 8 * 8 interpolation needs is 11 * 12.
In reading the process of external memory, in order to reduce the visit capacity to external memory, present embodiment is made certain optimization to the size that reads.In brightness interpolating, the required number of pixels of different location of interpolation is different, if adopt the maximum pixel number, natural energy meets the demands, but has increased the visit capacity of external memory like this.
Present embodiment is in order to save the bandwidth of external memory, draws the location of interpolation of current block according to motion vector, to different location of interpolation, and the line (OK) of the external memory applied for of adjustment and the size of size (size represents and is listed as among the present invention) respectively.Table 3 has provided under brightness application external memory situation, and setting each base block size to the external memory application is 8 * 8, simultaneously the different motion vector is set row, the row increment of corresponding different application external memory respectively.Add row, the column information that corresponding increment is capable, row just can obtain this application by basic blocks row, row.Through further investigation, present embodiment sums up following rule formula:
1). the columns increment-req_plus_wid of request external memory
Figure BDA0000045712050000091
2). the line number increment-req_plus_hei of request external memory
Figure BDA0000045712050000092
In the formula, x is a horizontal level, i.e. interpolation point numbering in the horizontal direction; Y is the upright position, i.e. interpolation point numbering in vertical direction.
The luminance block that following table 1 has provided present embodiment more intuitively becomes piece size read schemes.
Table 1
Figure BDA0000045712050000093
Figure BDA0000045712050000101
The change piece size of chrominance block reads
Similar with luminance block, in the change piece size read schemes of chrominance block, the size of applying for when at every turn reading external memory also adds that by basic blocks row, row corresponding increment is capable, row obtain.Basic blocks is of a size of 4 * 4, and its increment is capable, row draw by following formula:
1). the columns increment (req_plus_wid) of request external memory
req _ plus _ wid = 0 ; x = 0 1 ; other
2). the line number increment (req_plus_hei) of request external memory
req _ plus _ hei = 0 ; y = 0 1 ; other
In the formula, x is a horizontal level, i.e. interpolation point numbering in the horizontal direction; Y is the upright position, i.e. interpolation point numbering in vertical direction.
In conjunction with reference to figure 4 and table 2, can draw the chrominance block change piece size read schemes of present embodiment more intuitively.
Table 2
Figure BDA0000045712050000111
Embodiment 3
According to embodiments of the invention 3, a kind of inter-frame prediction method based on AVS is provided.In this method, decoder is divided into several macro blocks with the frame that needs carry out inter prediction, successively each macro block is carried out inter prediction.For each macro block, the inter prediction process comprises the following steps:
The first step: the pattern and corresponding motion vector that from the AVS code stream, read current macro;
Second step: read from external memory according to the pattern of current macro and motion vector and to carry out the required reference picture of inter prediction;
The 3rd step: carry out interpolation arithmetic according to reference picture and motion vector, recover current macro.
Wherein, the first step, the 3rd goes on foot consistent with embodiment 1,2, repeats no more.
In second step, when from external memory, reading reference data, present embodiment adopts interblock data reusing and change piece size to read two kinds of mechanism simultaneously, thereby has farthest avoided redundant data, has saved the memory access bandwidth.
Becoming aspect the piece size reads, present embodiment draws location of interpolation according to motion vector, and applies for corresponding external memory size, and this is consistent with embodiment 2, repeats no more.
Aspect the interblock data reusing, present embodiment is provided with buffer memory mem, and its size is consistent with embodiment 1.For luminance block and chrominance block, the address space of buffer memory mem distributes also all consistent with embodiment 1, repeats no more here.In a macro block, during first piece interpolation, still from external memory, read its corresponding reference data, during to other piece interpolation, then reading section reference data from the appropriate address of buffer memory mem reads all the other reference datas from external memory.So just saved the memory access bandwidth of decoder greatly.
Embodiment 4
According to embodiments of the invention 4, a kind of inter-frame prediction method based on AVS is provided.In this method, decoder is divided into several macro blocks with the frame that needs carry out inter prediction, successively each macro block is carried out inter prediction.For each macro block, the inter prediction process comprises the following steps:
The first step: the pattern and corresponding motion vector that from the AVS code stream, read current macro;
Second step: read from external memory according to the pattern of current macro and motion vector and to carry out the required reference picture of inter prediction;
The 3rd step: carry out interpolation arithmetic according to reference picture and motion vector, recover current macro.
Wherein, the first step, the 3rd goes on foot consistent with embodiment 2, repeats no more.
In second step, read in the change piece size of embodiment 2 on the basis of mechanism, present embodiment is that unit carries out inter prediction with 8 * 8 no longer, but according to the macro-block partition mode that the first step draws, respectively corresponding sub-piece is carried out inter prediction.Promptly when macroblock partitions is 1 16 * 16 luminance block, promptly directly from internal memory, reads this 16 * 16 luminance block and carry out the required reference data of motion compensation; When macroblock partitions is 2 16 * 8 luminance block or 28 * 16 luminance block, then reads at twice and carry out the required reference data of motion compensation; When macroblock partitions is 48 * 8 luminance block, then divides to read for four times and carry out the required reference data of motion compensation.It also is to realize through the basic blocks of setting visit external memory and the mode of corresponding ranks increment that this change piece size reads.To those skilled in the art, reference implementation example 2 draws and becomes the concrete implementation that the piece size reads mechanism in the present embodiment easily, repeats no more here.
Embodiment 5
On any basis of the foregoing description 1~4, present embodiment has further been optimized the mechanism that reads of chroma data, thereby a kind of inter-frame prediction method based on AVS that has advantage more is provided.
In the AVS standard, chrominance block comprises Cb chrominance block and Cr chrominance block, and Cb chrominance block and Cr chrominance block occur in pairs.In the prior art, in the AVS code stream, the data separate storage of the every couple of Cb and Cr chrominance block is promptly stored the data of storing corresponding C b chrominance block after the data of a Cb chrominance block more continuously.Like this, when a pair of Cb and Cr chrominance block are carried out motion compensation, need read Cb chrominance block and Cr chrominance block corresponding reference data respectively.
In the present embodiment, the Cb colourity in the AVS code stream and Cr chroma data interweaved store external memory into.Fig. 5 shows the pilotaxitic texture of Cb and Cr.In the AVS standard, the every couple of Cb and the shared identical motion vector of Cr chrominance block, the sub-pixel interpolation mode of Cb and Cr also is identical.If deposit the reference data of Cb and Cr in external memory with a kind of mode that interweaves, just can read together with the reference data of the same mode that interweaves with Cb and Cr.The number of times of visit external memory has just reduced half like this, also further improves bandwidth utilization.And,, therefore, when reducing visit external memory number of times, also mean and reduced the total data volume that is read because more or less can there be some redundant datas in the restriction of DDR width when visiting external memory at every turn.
The interweave scheme of storage of chroma data in the present embodiment promptly can independently be implemented, and also can on any basis of the foregoing description 1~4, implement, and this is that those skilled in the art are understandable.
Embodiment 6
Present embodiment has been optimized data and has been augmented (padding) mechanism on the basis of existing technology, thereby a kind of inter-frame prediction method based on AVS that has advantage more is provided.
In the AVS standard; Use unconfined motion vector; That is to say that motion vector reference data pointed can exceed the border of reference picture, in this case the integral sample in should this integer reference data indication position of the service range nearest image of the integral sample that exceeds reference image border is carried out border extension.In the existing AVS decoder, the reference frame after in advance the reference frame border being expanded and will be expanded deposits external memory in.This way bandwidth availability ratio is low, the extra external space that the reference frame after data are augmented simultaneously need take.
Present embodiment is not then done in advance expansion to reference frame, carries out but the process that data are augmented is placed in the motion compensation, promptly reads real reference data according to motion vector to external memory, accomplishes data in this locality and augments.Can further improve bandwidth utilization like this, save the shared external space of each reference frame simultaneously.
Fig. 6 shows the structure that the data of present embodiment are augmented.According to the value of motion vector, present embodiment has designed 4 kinds of data and has augmented (padding) type, and data are augmented configuration information and are:
1) type of .pad_type:padding, 0 type is represented upper left padding among Fig. 6; 1 type is represented left side padding down; 2 types are represented upper right padding; 3 types are represented bottom right padding.
2) columns of .pad_size:padding, size are 0~11.When pad_type representes the columns of padding left upper left and left following time, otherwise when pad_type be upper right columns that do not need to represent padding during with the bottom right.
3) line number of .pad_line:padding, size are 0~11.When pad_type representes the upwards line number of padding when being upper left and upper right, otherwise descend and do not need to represent during the bottom right line number of padding for a left side as pad_type.
When predicting between conducting frame, after from external memory, reading real reference data, can augment configuration information (pad_type, pad_size and pad_line), augment at the basic enterprising line data of real reference data according to data.On diverse location, the concrete numeric reference AVS standard of being augmented.
Wherein, when motion vector reference data pointed exceeds the reference picture left margin, carry out data with the numerical value of reference picture Far Left one row pixel and augment; When exceeding the reference picture right margin, carry out data with the numerical value of rightmost one row pixel and augment; Exceed the reference picture coboundary, the numerical value of usefulness the top delegation carries out data and augments; Exceed the reference picture lower boundary, carry out data with the numerical value of delegation bottom and augment.That the position that exceeds image is positioned at is upper left, a left side is following, upper right, during the bottom right, carry out data with the value of upper left angle point, lower left corner point, upper right angle point, bottom right corner pixels respectively and augment.
What be worth explanation is, the data of present embodiment are augmented scheme and both can independently be implemented, and also can on any basis of the foregoing description 1~5, implement.
It should be noted last that; Above embodiment is only unrestricted in order to technical scheme of the present invention to be described; Although with reference to preferred embodiment the present invention is specified, those of ordinary skill in the art should be appreciated that and can make amendment or be equal to replacement technical scheme of the present invention; And not breaking away from the spirit and the scope of technical scheme of the present invention, it all should be encompassed in the middle of the claim scope of the present invention.

Claims (7)

1. inter-frame prediction method based on AVS, this method comprise that the frame that needs are carried out inter prediction is divided into several macro blocks, successively each macro block are carried out inter prediction, and for each macro block, inter prediction comprises the following steps:
1) reads the corresponding motion vector of current macro;
2) current macro be divided into the corresponding plurality of sub piece of motion vector carry out motion compensation,
3) for every sub-block; When motion vector position pointed exceeds frame boundaries; From external memory, read the data that are positioned at frame boundaries in the reference picture, carry out data according to motion vector with the data that are positioned at frame boundaries that read then and augment, thereby obtain complete reference picture.
4) carry out interpolation arithmetic according to reference picture and motion vector, recover current macro.
2. the inter-frame prediction method based on AVS according to claim 1 is characterized in that, in the said step 1), also comprises the sub-piece partition mode that from the AVS code stream, reads current macro;
Said step 2) in, divides sub-piece according to the sub-piece partition mode of the current macro that is read.
3. the inter-frame prediction method based on AVS according to claim 1 is characterized in that, in the said step 3), when motion vector reference data pointed exceeds the reference picture left margin, carries out data with the numerical value of reference picture Far Left one row pixel and augments.
4. the inter-frame prediction method based on AVS according to claim 1 is characterized in that, in the said step 3), when motion vector reference data pointed exceeds the reference picture right margin, carries out data with the numerical value of reference picture rightmost one row pixel and augments.
5. the inter-frame prediction method based on AVS according to claim 1 is characterized in that, in the said step 3), when motion vector reference data pointed exceeds the reference picture coboundary, with reference picture topmost the numerical value of delegation carry out data and augment.
6. the inter-frame prediction method based on AVS according to claim 1 is characterized in that, in the said step 3), when motion vector reference data pointed exceeds the reference picture lower boundary, with reference picture bottom the numerical value of delegation carry out data and augment.
7. the inter-frame prediction method based on AVS according to claim 1; It is characterized in that; In the said step 3); That the position that motion vector reference data pointed exceeds reference picture is positioned at is upper left, a left side is following, upper right, during the bottom right, carry out data with the value of the upper left angle point of reference picture, lower left corner point, upper right angle point, bottom right corner pixels respectively and augment.
CN201110029730.0A 2011-01-27 2011-01-27 Inter prediction method based on AVS Expired - Fee Related CN102625091B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110029730.0A CN102625091B (en) 2011-01-27 2011-01-27 Inter prediction method based on AVS

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110029730.0A CN102625091B (en) 2011-01-27 2011-01-27 Inter prediction method based on AVS

Publications (2)

Publication Number Publication Date
CN102625091A true CN102625091A (en) 2012-08-01
CN102625091B CN102625091B (en) 2015-01-07

Family

ID=46564753

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110029730.0A Expired - Fee Related CN102625091B (en) 2011-01-27 2011-01-27 Inter prediction method based on AVS

Country Status (1)

Country Link
CN (1) CN102625091B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103384326A (en) * 2013-03-20 2013-11-06 张新安 Quick intra-frame prediction mode selection method for AVS-M video coding

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1874518A (en) * 2006-06-22 2006-12-06 上海交通大学 Hardware implementation method of motion vector calculation device for compensating movement based on AVS
JP2007507183A (en) * 2003-09-24 2007-03-22 テキサス インスツルメンツ インコーポレイテッド 8x8 transform and quantization
CN101022551A (en) * 2007-03-15 2007-08-22 上海交通大学 Motion compensating module pixel prefetching device in AVS video hardware decoder
CN101790093A (en) * 2010-03-16 2010-07-28 山东大学 Device and method for implementation of AVS video decoding by using SOPC

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007507183A (en) * 2003-09-24 2007-03-22 テキサス インスツルメンツ インコーポレイテッド 8x8 transform and quantization
CN1874518A (en) * 2006-06-22 2006-12-06 上海交通大学 Hardware implementation method of motion vector calculation device for compensating movement based on AVS
CN101022551A (en) * 2007-03-15 2007-08-22 上海交通大学 Motion compensating module pixel prefetching device in AVS video hardware decoder
CN101790093A (en) * 2010-03-16 2010-07-28 山东大学 Device and method for implementation of AVS video decoding by using SOPC

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
JUN-HAO ZHENG,LEI DENG,PENG ZHANG,DON XIE: "An Efficient VLSI Architecture for Motion Compensation of AVS HDTV Decoder", 《J.COMPUT.SCI.& TECHNOL. 》, 31 May 2006 (2006-05-31) *
RONGGANG WANG, CHAO HUANG, JINTAO LI,YANFEI SHEN: "Sub-pixel Motion Compensation Interpolation Filter in AVS", 《MULTIMEDIA AND EXPO, 2004. ICME "04. 2004 IEEE INTERNATIONAL CONFERENCE ON》, 30 June 2004 (2004-06-30) *
常丽娜: "AVS-M视频编码技术研究与流媒体应用", 《中国优秀硕士学位论文全文数据库 信息科技辑》, 4 October 2005 (2005-10-04) *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103384326A (en) * 2013-03-20 2013-11-06 张新安 Quick intra-frame prediction mode selection method for AVS-M video coding

Also Published As

Publication number Publication date
CN102625091B (en) 2015-01-07

Similar Documents

Publication Publication Date Title
CN103004210B (en) For the Low-complexity intra prediction of Video coding
KR100695141B1 (en) Memory access apparatus and method, data write/read apparatus and method for use in image processing system
CN101710986B (en) H.264 parallel decoding method and system based on isostructural multicore processor
CN105578190B (en) Lossless compression method and system applied to video hard decoder
CN102547296B (en) Motion estimation accelerating circuit and motion estimation method as well as loop filtering accelerating circuit
US20050190976A1 (en) Moving image encoding apparatus and moving image processing apparatus
CN102647594B (en) Integer pixel precision motion estimation method and system for same
CN102088603B (en) Entropy coder for video coder and implementation method thereof
CN101563927A (en) Method for decoding a block of a video image
JPH08123953A (en) Picture processor
KR20060010474A (en) Memory mapping apparatus and method for video decoer/encoder
US8565312B2 (en) Image processing method and image information coding apparatus using the same
CN1589028B (en) Predicting device and method based on pixel flowing frame
WO2023000695A1 (en) Video encoding reference block compression method, encoding method, and apparatuses
CN100568920C (en) The method and apparatus of the video image brightness interpolating of serial input and line output
CN102625091B (en) Inter prediction method based on AVS
CN102625093B (en) Interframe prediction method base on AVS
CN102625095B (en) AVS-based interframe prediction method
CN102625094B (en) AVS-based interframe prediction method
CN102665080A (en) Electronic device for motion compensation and motion compensation method
CN101494789B (en) Video encoding/decoding method
JP2006166308A (en) Decoding apparatus and decoding method
KR100708183B1 (en) Image storing device for motion prediction, and method for storing data of the same
CN101847394A (en) Storage mapping method and device for encoding and displaying video files
JP5265984B2 (en) Image encoding apparatus and decoding apparatus

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20150107

Termination date: 20220127