CN101867818B - Selection method and device of macroblock mode - Google Patents
Selection method and device of macroblock mode Download PDFInfo
- Publication number
- CN101867818B CN101867818B CN 201010184776 CN201010184776A CN101867818B CN 101867818 B CN101867818 B CN 101867818B CN 201010184776 CN201010184776 CN 201010184776 CN 201010184776 A CN201010184776 A CN 201010184776A CN 101867818 B CN101867818 B CN 101867818B
- Authority
- CN
- China
- Prior art keywords
- mode
- coding
- coding cost
- skip
- macroblock
- 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.)
- Expired - Fee Related
Links
- 238000010187 selection method Methods 0.000 title claims abstract description 18
- 238000000034 method Methods 0.000 claims abstract description 22
- 208000037170 Delayed Emergence from Anesthesia Diseases 0.000 claims description 14
- 238000013139 quantization Methods 0.000 claims description 11
- 238000004364 calculation method Methods 0.000 claims description 4
- 230000005540 biological transmission Effects 0.000 description 3
- 238000010586 diagram Methods 0.000 description 3
- 230000002123 temporal effect Effects 0.000 description 3
- 238000005516 engineering process Methods 0.000 description 2
- 101100317378 Mus musculus Wnt3 gene Proteins 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
Images
Landscapes
- Compression Or Coding Systems Of Tv Signals (AREA)
- Compression, Expansion, Code Conversion, And Decoders (AREA)
Abstract
The invention discloses a selection method and a device of a macroblock mode. The method comprises the steps of comparing the coding costs of all coding modes of a current macroblock, determining the optimal macroblock coding mode, and adopting the pixel precision stratified selection method for part of inter-frame modes when calculating the coding costs; and a novel comparison algorithm can also be adopted when comparing the special modes-skip mode and other coding modes of the macroblock. The method can significantly reduce the computational complexity and greatly improve the computational parallelism while keeping the bit rate and the coding quality unchanged basically, thereby being applicable to real-time software and hardware video coding.
Description
Technical Field
The present invention relates to the field of video coding technologies, and in particular, to a method and an apparatus for fast selection of macroblock mode selection for video compression coding.
Background
In Video coding standards such as h.264/avc (advanced Video coding), AVS (audio Video coding Standard) specifies the stream structure and decoding process, but does not describe a specific coding method. Mode selection is a core technology in video coding and is therefore a hotspot of academic research.
Since most of the encoding standards adopt a macroblock as a basic unit, the mode selection is performed based on the encoding mode of the macroblock. In the prior art, mode selection is to compare coding cost functions among modes, and select a mode with the minimum coding cost function as a final mode of a current macroblock. The coding cost function is the Rate-Distortion cost (RDCost: Rate-Distortion cost) corresponding to the coding mode when Rate-Distortion Optimization (RDO) is adopted, and other methods for calculating the cost function are proposed because the Rate-Distortion cost is calculated quite complicated, but the calculation amount is still quite large, and particularly when the motion estimation precision is high, the complexity of motion estimation at high precision at one time is quite high. Moreover, in the fast algorithm for selecting the special mode, such as the SKIP (SKIP) mode, the cost function is not utilized for comparison calculation, so that the accuracy of mode selection is greatly reduced.
Disclosure of Invention
The invention aims to provide a method and a device for quickly selecting a macro block mode, aiming at the defects of the prior art.
The purpose of the invention is realized by the following technical scheme:
a method for selecting macro block mode includes selecting mode with optimal coding cost as selection result of first type of inter mode by comparing coding cost of first type of inter mode under low precision motion estimation, carrying out high precision motion estimation on selected mode to obtain optimal coding cost of mode under high precision motion estimation. The coding cost is compared with the coding cost of the optimal intra mode and the optimal second type inter mode to select the mode with the better coding cost. The first type of inter-frame mode refers to an inter-frame coding mode which needs to perform motion search, the second type of inter-frame mode refers to an inter-frame coding mode which does not need to perform motion search, and the preferred coding mode refers to a coding mode which is selected by a judgment standard with low coding cost or other judgment standards combined with the coding cost.
An apparatus for the selection method of the macroblock mode. It includes: the motion estimation method comprises a low-precision pixel first-class interframe mode selector, a high-precision pixel motion estimator, an intraframe mode selector, a second-class interframe mode selector and a mode decision device. The output end of the low-precision pixel first-class interframe mode selector is connected with the input end of the high-precision pixel motion estimator, and the optimal coding mode in the first-class interframe modes and the coding cost of the macro block in the coding mode are output. The output end of the high-precision pixel motion estimator is connected with the mode decision device, and outputs the corresponding mode and the coding cost of the macro block under the coding mode after the high-precision motion estimation. The output end of the intra-frame mode selector is connected with the mode decision device, and the optimal intra-frame mode and the coding cost of the macro block under the coding mode are output. The output end of the second type interframe mode selector is connected with the mode decision device, and outputs the optimal coding mode and the coding cost of the macro block under the coding mode in the second type interframe mode. One input end of the mode decision device is connected with the high-precision pixel motion estimator, one input end of the mode decision device is connected with the intra-frame mode selector, the other input end of the mode decision device is connected with the second type inter-frame mode selector, and the optimal mode of the three input modes is output.
A macroblock mode selection method, adopt threshold judgement and code cost function comparison of the absolute value of the residual block of prediction to choose to the SKIP mode of the macroblock, namely the absolute value of the residual block of prediction is smaller than a and threshold determined by the quantized parameter size of the macroblock under SKIP mode, and the current macroblock chooses the SKIP mode when the code cost of SKIP is superior to the code cost of the optimum mode in other modes except SKIP mode; otherwise, the current macro block selects the optimal coding mode in other modes except the SKIP mode. The preferred coding mode refers to a coding mode with a smaller coding cost or selected by other judgment criteria combined with the size of the coding cost.
The device for the selection method of the macro block mode comprises a residual absolute value comparator, a first coding cost calculator, a second coding cost calculator and a mode selector. The output end of the residual absolute value comparator is connected with the mode selector, and a signal for judging whether the residual absolute value is greater than a threshold is output. The output end of the first coding cost calculator is connected with the mode selector and outputs the optimal mode in other modes except the SKIP mode and the coding cost of the macro block in the mode. The output end of the second coding cost calculator is connected with the mode selector and outputs the coding cost of the SKIP mode. And three input ends of the mode selector are respectively connected with the residual absolute value comparator, the first coding cost calculator and the second coding cost calculator. And outputting the finally selected coding mode.
The invention has the advantages that the optimal macro block coding mode can be accurately selected under the condition of greatly reducing the calculation complexity, and meanwhile, the accuracy of selection of the SKIP mode is improved by finely judging the SKIP mode.
Drawings
Fig. 1 is a block diagram of a macroblock mode selection apparatus according to embodiment 4 of the present invention;
FIG. 2 is a block diagram showing the structure of a macroblock mode selection apparatus according to embodiment 5 of the present invention;
fig. 3 is a block diagram of a macroblock mode selection apparatus according to embodiment 6 of the present invention.
Detailed Description
The present invention will be described in detail below with reference to the drawings and examples, and the object and effect of the present invention will become more apparent.
The technical scheme of the invention mainly selects the coding mode with the minimum coding cost among the modes according to the coding cost function so as to improve the coding performance of the video coding system.
The following is a specific implementation of the present invention:
example 1:
taking the AVS standard as an example, in the AVS standard, macroblock modes are divided into two major categories, inter-frame coding mode and intra-frame coding mode. The inter-frame coding modes can be divided into 16 × 16, 16 × 8, 8 × 16, 8 × 8 modes according to the size of the sub-blocks, and besides, special coding modes exist between frames, such as SKIP mode in P-stripe, SKIP and DIRECT mode in B. The intra coding modes are predictively coded according to the size of 8 × 8 blocks, and there are 5 intra coding modes in total: horizontal mode, vertical mode, down-right mode, down-left mode, DC mode. For each macroblock, a mode with high coding efficiency needs to be selected from the coding modes for coding. The following describes the macroblock mode selection method of claim 1, taking macroblock mode selection in a B slice in the AVS standard as an example.
The specific implementation steps are as follows:
step 1, the following cost function is adopted to select a mode with the minimum coding cost from the inter modes 16 × 16, 16 × 8, 8 × 16 and 8 × 8. The coding cost of the selected macroblock mode is recorded as minCost _ inter _ int.
Cost_inter_int=SAD_int+λ×(mode_bits+motion_bits)
SAD _ int is the sum of absolute values of residual blocks after integer pixel precision motion search in the current mode, mode _ bits is the number of bits required for mode information transmission in a code stream of the mode, motion _ bits is the number of bits required for motion vector transmission in the code stream, and lambda is 0.67 times QP, wherein QP refers to the quantization parameter of the current macroblock.
Step 2, calculating the coding cost of the mode selected in the step 1 after 1/4 pixel precision motion search
minCost_inter_qua=min_SAD_qua+λ×(mode_bits+motion_bits)
Wherein min _ SAD _ qua is the sum of absolute values of residual blocks after 1/4 pixel motion search of the mode selected in step 1, mode _ bits is the bit number required by the mode to transfer in the code stream, motion _ bits is the bit number required by the motion vector to transfer in the code stream, and λ is 0.67 × QP, where QP refers to the quantization parameter of the current macroblock.
And 3, selecting an intra-frame mode with the minimum coding cost from the five intra-frame modes by using the following cost function. The coding cost of the selected macroblock mode is denoted as minCost _ intra.
Cost_intra=SAD_intra+λ×mode_bits+H
The SAD _ intra is the sum of absolute values of prediction residual blocks after intra-frame prediction in the current mode, and the mode _ bits is the bit number required by the mode information of the mode to be transmitted in a code stream. λ is 0.67 × QP. H is the correction amount of cost in the frame, which is taken to be 18.
And 4, comparing the coding costs of the modes selected in the step 1 and the step 3, namely the sizes of the minCost _ inter _ qua and the minCost _ intra, if the minCost _ inter _ qua is larger, setting the mode selected in the step 2 as a candidate mode, and otherwise, setting the mode in the step 1 as the candidate mode.
And 5, comparing the coding cost of the candidate mode selected in the step 4 with the coding cost of the optimal coding mode in the inter-frame special modes, wherein the special modes refer to a DIRECT mode and a SKIP mode. And selecting the mode with the minimum coding cost as the final coding mode of the current macro block. The coding cost of a special mode is calculated as follows.
Cost_special=SAD_special+λ×mode_bits
The SAD _ special is the sum of absolute values of residual blocks predicted by a special mode, the mode _ bits is the number of bits required by the mode information of the mode to be transmitted in a code stream, and the lambda is 0.67 × QP, wherein the QP refers to the quantization parameter of the current macroblock.
Example 2:
the following describes the macroblock mode selection method of claim 6, taking the macroblock mode selection method in the P slice in the AVS standard as an example.
The specific implementation steps are as follows:
and step 1, selecting a mode with the minimum coding cost from other candidate modes except the SKIP mode by adopting the following cost function. The coding cost of the selected macroblock mode is denoted minCost _ normal.
Cost_normal=η×num_nozero+λ×(mode_bits+motion_bits)+H
Wherein num _ zero is the number of nonzero coefficients in the macroblock prediction residual block in the current mode, mode _ bits is the number of bits required by the mode information of the mode to be transmitted in a code stream, motion _ bits is the number of bits required by the motion vector to be transmitted in the code stream, eta is 10 × QP, and λ is 0.69 × QP, wherein QP refers to the quantization parameter of the current macroblock.
And 2, comparing the candidate mode selected in the step 1 with the coding cost of the SKIP mode, and calculating the coding cost of the SKIP mode according to the following method.
Cost_skip=α×SAD_Skip+β×skipmode_bits
SAD _ Skip is the sum of absolute values of residuals of the macro blocks after SKIP mode compensation, Skip mode _ bits is the number of bits needed for transmitting mode information of the SKIP mode in a code stream, alpha is 0.85, beta is 0.62 × QP, and QP refers to the quantization parameter of the current macro block.
If Cost _ Skip is less than minCost _ normal and SAD _ Skip < Th (QP), the final coding mode of the macroblock is SKIP mode, otherwise the mode selected in step 1 is taken as the final coding mode of the current macroblock.
Example 3:
taking the h.264 standard as an example, in the h.264 standard, macroblock modes are divided into two major types, inter-frame coding mode and intra-frame coding mode. The inter-frame coding modes can be further divided into 16 × 16, 16 × 8, 8 × 16, 8 × 8, 8 × 4, 4 × 8, and 4 × 4 modes according to the size of the sub-blocks, and in addition, special coding modes exist between frames, such as SKIP mode in P slice, SKIP and DIRECT mode in B, and the DIRECT mode is further divided into spatial DIRECT mode and temporal DIRECT mode. Intra coding modes are classified into two categories, 16 × 16 and 4 × 4. There are 4 modes of 16 × 16: vertical mode, horizontal mode, DC mode, planar mode; there are 9 intra coding modes for a 4 × 4 block: horizontal mode, vertical mode, down-right mode, down-left mode, DC mode, down-left diagonal mode, down-right diagonal mode, right vertical mode, down-horizontal mode, left vertical mode, up-horizontal mode. For each macroblock, a mode with high coding efficiency needs to be selected from the coding modes for coding. The following describes the macroblock mode selection method according to claim 9, taking mode selection in B slices in the h.264 standard as an example.
The specific implementation steps are as follows:
step 1, the following cost function is adopted to select a mode with the minimum coding cost from the inter modes 16 × 16, 16 × 8, 8 × 16, 8 × 8, 8 × 4, 4 × 8 and 4 × 4. The coding cost of the selected macroblock mode is recorded as minCost _ inter _ int.
Cost_inter_int4=SATD_int+λ×(mode_bits+motion_bits)
Wherein, SATD _ int4 is the sum of absolute values of residual block after hadamard transform of motion search with 4 times integer pixel precision in the current mode, mode _ bits is the bit number required for the mode to transmit in the code stream, motion _ bits is the bit number required for the motion vector to transmit in the code stream, λ is 0.68 × QP, where QP refers to the quantization parameter of the current macroblock.
Step 2, calculating the coding cost of the mode selected in the step 1 after the integer pixel precision motion search
minCost_inter_int=SATD_int+λ×(mode_bits+motion_bits)
Wherein, SATD _ int is the sum of absolute values of the residual block after hadamard transform of the mode selected in step 1 after motion search with integer pixel precision, mode _ bits is the number of bits required for transferring the mode information of the mode in the code stream, motion _ bits is the number of bits required for transferring the motion vector in the code stream, λ is 0.68 × QP, where QP refers to the quantization parameter of the current macroblock.
And 3, selecting an intra-frame mode with the minimum coding cost from the 9 modes in the frame by using the following cost function. The coding cost of the selected macroblock mode is denoted as minCost _ intra.
Cost_intra=SATD_intra+λ×mode_bits+H
Wherein, SATD _ intra is the sum of absolute values of the residual block after hadamard transform in intra prediction in the current mode, mode _ bits is the number of bits required for the mode information in the code stream transmission in the mode, λ is 0.68 × QP, where QP refers to the quantization parameter of the current macroblock, H is the correction of cost in the frame, and H is 20.
And 4, comparing the coding costs of the modes selected in the step 1 and the step 3, namely the sizes of the minCost _ inter _ int and the minCost _ intra, if the minCost _ inter _ int is larger, setting the mode selected in the step 3 as a candidate mode, otherwise, setting the mode in the step 1 as the candidate mode.
And 5, comparing the candidate mode selected in the step 4 with the optimal coding cost of the DIRECT mode, and selecting the mode with lower coding cost as a new candidate mode. Let the coding cost of the mode selected at this time be minCost _ normal. The DIRECT modes include a temporal DIRECT mode and a spatial DIRECT mode, and their coding costs are calculated as follows.
Cost_direct=SATD_direct+λ×mode_bits
Wherein, SATD _ DIRECT is the sum of absolute values of residual blocks after Hadamard transformation after prediction in a DIRECT mode, mode _ bits is the number of bits of mode information of the DIRECT mode needing to be transmitted in a code stream, and lambda is 0.68 multiplied by QP, wherein the QP refers to the quantization parameter of the current macro block.
And 6, comparing the candidate mode selected in the step 5 with the coding cost of the SKIP mode, and calculating the coding cost of the SKIP mode according to the following method.
Cost_skip=α×SAD_Skip+β×skipmode_bits
SAD _ Skip is the sum of absolute values of residual errors of the macro blocks after the SKIP mode compensation, Skip mode _ bits is the number of bits which need to be transmitted in a code stream of the SKIP mode, alpha is 0.8, beta is 0.63 × QP, and QP refers to the quantization parameter of the current macro block.
If Cost _ Skip is less than minCost _ normal and SAD _ Skip < Th (QP), the final coding mode of the macroblock is SKIP mode, otherwise the mode selected in step 5 is taken as the final coding mode of the current macroblock.
Example 4:
an apparatus for a fast selection method of a macroblock mode is shown in fig. 1. The device is implemented according to the mode selection method described in embodiment 1, and specifically includes: integer pixel precision first-class inter mode selector, 1/4 pixel precision motion estimator, intra mode selector, mode decider, second-class inter mode selector.
1) The output end of the integer pixel precision first type interframe mode selector is connected with 1/4 pixel precision motion estimators, and outputs the optimal coding mode in the first type interframe modes and the coding cost of the macro block under the coding mode. The first type of inter mode herein refers to a 16 × 16, 16 × 8, 8 × 16, 8 × 8 macroblock coding mode.
2) The input end of the 1/4 pixel precision motion estimator is connected with the integer pixel precision first-class inter-frame mode selector, the output end is connected with the mode decision device, and the corresponding mode and the coding cost of the macro block under the coding mode after 1/4 pixel precision motion estimation are output.
3) The output end of the intra-frame mode selector is connected with the mode decision device, and outputs the optimal mode in the five intra-frame modes and the coding cost of the macro block under the coding mode.
4) The output end of the second type interframe mode selector is connected with the mode decision device, and the optimal coding mode in the second type interframe mode and the macro block coding cost under the coding mode are output. The second type of inter-frame mode herein refers to SKIP mode and DIRECT mode.
5) An input of the mode decision device is connected with 1/4 pixel precision motion estimator, an input is connected with the intra-frame mode selector, and an input is connected with the second type inter-frame mode selector to output the optimal mode of three input modes.
Example 5:
an apparatus for a fast selection method of macroblock mode is shown in fig. 2. The device is implemented according to the mode selection method described in embodiment 2, and specifically includes a residual absolute value comparator, a first coding cost calculator, a second coding cost calculator, and a mode selector.
1) The output end of the residual absolute value comparator is connected with the mode selector and outputs a signal whether the residual absolute value SAD _ Skip is larger than the threshold Th (QP).
2) The output end of the first coding cost calculator is connected with the mode selector and outputs the optimal mode in other modes except the SKIP mode and the coding cost of the macro block in the mode.
3) The output end of the second coding cost calculator is connected with the mode selector and outputs the coding cost of the SKIP mode.
4) And three input ends of the mode selector are respectively connected with the three modules, the residual absolute value comparator, the first coding cost calculator and the second coding cost calculator. And outputting the finally determined coding mode.
Example 6:
an apparatus for a fast selection method of macroblock mode is shown in fig. 3. The apparatus is implemented according to the mode selection method described in embodiment 3, and specifically includes: the device comprises a first-class interframe mode selector with 4-time integer pixel precision, an integer pixel precision motion estimator, an intraframe mode selector, a first mode decision device, a second-class interframe mode selector, a second mode decision device and an SKIP mode calculator.
1) The output end of the first-class inter-frame mode selector with 4 times of integer pixel precision is connected with the integer pixel precision motion estimator, and the optimal coding mode in the first-class inter-frame coding mode and the coding cost of the macro block under the coding mode are output. The first type inter mode herein refers to a 16 × 16, 16 × 8, 8 × 16, 8 × 8, 8 × 4, 4 × 8, 4 × 4 macroblock coding mode.
2) The input end of the integer pixel precision motion estimator is connected with a first type interframe mode selector with 4 times of the integer pixel precision, the output end of the integer pixel precision motion estimator is connected with a first mode decision device, and the output end of the integer pixel precision motion estimator outputs a corresponding mode and the coding cost of the macro block under the coding mode after the high-precision motion estimation.
3) The output end of the intra mode selector is connected with the first mode decision device, and outputs the optimal mode of the 16 × 16 and 4 × 4 intra modes and the coding cost of the macro block under the coding mode.
4) The output end of the second type interframe mode selector is connected with the first mode decision device, and outputs the optimal coding mode in the second type interframe mode and the macroblock coding cost under the coding mode. The second class of inter-frame modes herein refers to spatial DIRECT modes and temporal DIRECT modes.
5) One input end of the first mode decision device is connected with the integer pixel precision motion estimator, one input end of the first mode decision device is connected with the intra-frame mode selector, the other input end of the first mode decision device is connected with the second type inter-frame mode selector, the output end of the first mode decision device is connected with the second mode decision device, and the optimal mode of the three input modes and the coding cost of the macro block under the coding mode are output.
6) The output end of the SKIP mode calculator is connected with the second mode decision device and outputs the SKIP mode and the macro block coding cost under the SKIP mode.
7) One input end of the second mode decision device is connected with the first mode decision device, the other input end is connected with the SKIP mode calculator, and the superior coding mode in the two input coding modes is output
Claims (5)
1. A method for selecting a macroblock mode, the method comprising: selecting an SKIP mode of a macro block by adopting a method of combining threshold judgment of the absolute value of a prediction residual block with comparison of a coding cost function, namely selecting the SKIP mode by the current macro block when the absolute value of the prediction residual block in the SKIP mode is smaller than a threshold determined by the quantization parameter of the macro block and the coding cost of the SKIP is superior to the coding cost of the optimal mode in other modes except the SKIP mode; otherwise, the current macro block selects the optimal coding mode in other modes except the SKIP mode; the preferred coding mode refers to a coding mode with a smaller coding cost or selected by other judgment criteria combined with the size of the coding cost.
2. The method of claim 1, wherein the coding cost is obtained by the following calculation method:
the coding cost of other modes except the SKIP mode is calculated by the following method:
Cost=C1+λ×C2+T1;
wherein C1 is a parameter for measuring the similarity between the pixel value of the current macroblock and the predicted pixel value of the macroblock in the current mode, C1 is a non-negative number, C1 is smaller as the similarity is higher, and C1 is equal to zero when the pixel value of the current macroblock is completely the same as the pixel value of the predicted macroblock in the current mode; λ is a non-negative number; c2 is a parameter describing the size of the number of coded bits of the current macroblock excluding the quantized coefficients; t1 is a non-negative constant;
the coding cost of the SKIP mode is calculated by adopting the following method:
Cost=α×C3+β×C4+T2;
wherein, C3 is a parameter for measuring the similarity between the pixel value of the current macroblock and the predicted pixel value of the SKIP mode reference macroblock, C3 is a non-negative number, the higher the similarity is, the smaller C3 is, and when the pixel value of the current macroblock is completely the same as the predicted pixel of the macroblock in the SKIP mode, C1 is equal to zero; α, β are non-negative numbers; c4 is a parameter describing the size of the number of coded bits of the current macroblock excluding the quantized coefficients; t2 is a non-negative constant.
3. An apparatus for the macroblock mode selection method of claim 1, comprising a residual absolute value comparator, a first coding cost calculator, a second coding cost calculator, a mode selector; wherein,
the output end of the residual absolute value comparator is connected with the mode selector and outputs a signal indicating whether the residual absolute value is greater than a threshold;
the output end of the first coding cost calculator is connected with the mode selector and outputs the optimal mode in other modes except the SKIP mode and the coding cost of the macro block in the mode;
the output end of the second coding cost calculator is connected with the mode selector and outputs the coding cost of the SKIP mode;
three input ends of the mode selector are respectively connected with the residual absolute value comparator, the first coding cost calculator and the second coding cost calculator; and outputting the finally selected coding mode.
4. A method for selecting a macro block mode is characterized in that the method for selecting the macro block mode comprises the following steps:
1) selecting an optimal first type interframe mode by adopting a pixel precision hierarchical selection method for the first type interframe mode, and then comparing the optimal first type interframe mode with the coding cost of the optimal intraframe mode and the optimal second type interframe mode to select a mode with better coding cost;
2) comparing the mode in the step 1) with the SKIP mode, and selecting an optimal coding mode; when selecting, a method of combining threshold judgment of the absolute value of the prediction residual block with the comparison of the coding cost function is adopted;
the first type of inter-frame mode refers to an inter-frame coding mode which needs to perform motion search, the second type of inter-frame mode refers to an inter-frame coding mode which does not need to perform motion search, and the preferred coding mode refers to a coding mode which is selected by a judgment standard with low coding cost or other judgment standards combined with the coding cost.
5. An apparatus for the method of selecting the macroblock mode of claim 4, comprising: the device comprises a low-precision pixel first-class interframe mode selector, a high-precision pixel motion estimator, an intraframe mode selector, a first mode decision device, a second-class interframe mode selector, an SKIP mode calculator and a second mode decision device; wherein,
the output end of the low-precision pixel first-class inter-frame mode selector is connected with the high-precision pixel motion estimator and outputs the optimal coding mode in the first-class inter-frame mode and the coding cost of the macro block under the coding mode;
the input end of the high-precision pixel motion estimator is connected with the first-class interframe mode selector of the low-precision pixels, the output end of the high-precision pixel motion estimator is connected with the mode decision device, and the input end of the high-precision pixel motion estimator outputs the corresponding mode and the coding cost of the macro block in the coding mode after the high-precision motion estimation;
the output end of the intra-frame mode selector is connected with the first mode decision device and outputs the optimal intra-frame mode and the coding cost of the macro block under the coding mode;
the output end of the second type interframe mode selector is connected with the first mode decision device and outputs the optimal coding mode in the second type interframe mode and the macro block coding cost under the coding mode;
one input end of the first mode decision device is connected with the high-precision pixel motion estimator, one input end of the first mode decision device is connected with the intra-frame mode selector, the other input end of the first mode decision device is connected with the second type inter-frame mode selector, the output end of the first mode decision device is connected with the second mode decision device, and the optimal mode of the three input modes and the coding cost of the macro block under the coding mode are output;
the output end of the SKIP mode calculator is connected with the second mode decision device and outputs the SKIP mode and the coding cost of the macro block under the SKIP mode;
one input end of the second mode decision device is connected with the first mode decision device, the other input end is connected with the SKIP mode calculator, and the better coding mode of the two input coding modes is output.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 201010184776 CN101867818B (en) | 2008-06-06 | 2008-06-06 | Selection method and device of macroblock mode |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 201010184776 CN101867818B (en) | 2008-06-06 | 2008-06-06 | Selection method and device of macroblock mode |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN 200810062426 Division CN101304529A (en) | 2008-06-06 | 2008-06-06 | Method and device for selecting macro block pattern |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101867818A CN101867818A (en) | 2010-10-20 |
CN101867818B true CN101867818B (en) | 2012-08-29 |
Family
ID=42959342
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN 201010184776 Expired - Fee Related CN101867818B (en) | 2008-06-06 | 2008-06-06 | Selection method and device of macroblock mode |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101867818B (en) |
Families Citing this family (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102065298B (en) * | 2011-01-05 | 2012-10-24 | 西安电子科技大学 | High-performance macroblock coding implementation method |
CN102811346B (en) * | 2011-05-31 | 2015-09-02 | 富士通株式会社 | coding mode selection method and system |
CN102404570B (en) * | 2011-11-16 | 2014-06-04 | 浙江工业大学 | Method for rapidly selecting multi-view video coding modes based on rate distortion sensitivity |
CN105812795B (en) * | 2014-12-31 | 2019-02-12 | 浙江大华技术股份有限公司 | A kind of determination method and apparatus of the coding mode of maximum coding unit |
CN109996074A (en) * | 2017-12-29 | 2019-07-09 | 富士通株式会社 | Picture coding device, picture decoding apparatus and electronic equipment |
CN113489997A (en) * | 2021-05-27 | 2021-10-08 | 杭州博雅鸿图视频技术有限公司 | Motion vector prediction method, motion vector prediction device, storage medium and terminal |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1810037A (en) * | 2003-06-25 | 2006-07-26 | 汤姆森许可贸易公司 | Fast mode-decision encoding for interframes |
CN101032173A (en) * | 2004-09-28 | 2007-09-05 | 索尼株式会社 | Encoder, encoding method, program of encoding method and recording medium wherein program of encoding method is recorded |
CN101068355A (en) * | 2007-06-05 | 2007-11-07 | 南京大学 | MPEG2-H.264 code fast converting method |
CN101179728A (en) * | 2007-12-13 | 2008-05-14 | 北京中星微电子有限公司 | Method and apparatus for determining interframe encoding mode |
-
2008
- 2008-06-06 CN CN 201010184776 patent/CN101867818B/en not_active Expired - Fee Related
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1810037A (en) * | 2003-06-25 | 2006-07-26 | 汤姆森许可贸易公司 | Fast mode-decision encoding for interframes |
CN101032173A (en) * | 2004-09-28 | 2007-09-05 | 索尼株式会社 | Encoder, encoding method, program of encoding method and recording medium wherein program of encoding method is recorded |
CN101068355A (en) * | 2007-06-05 | 2007-11-07 | 南京大学 | MPEG2-H.264 code fast converting method |
CN101179728A (en) * | 2007-12-13 | 2008-05-14 | 北京中星微电子有限公司 | Method and apparatus for determining interframe encoding mode |
Non-Patent Citations (1)
Title |
---|
JP特开2003-284091A 2003.10.03 |
Also Published As
Publication number | Publication date |
---|---|
CN101867818A (en) | 2010-10-20 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103248893B (en) | From H.264/AVC standard to code-transferring method and transcoder thereof the fast frame of HEVC standard | |
JP4755095B2 (en) | Bidirectional prediction method used for encoding / decoding side of video encoding | |
CN101304529A (en) | Method and device for selecting macro block pattern | |
CN101815215B (en) | Selecting method for coding mode and a device thereof | |
CN103634606B (en) | Video encoding method and apparatus | |
CN101267556B (en) | Quick motion estimation method and video coding and decoding method | |
CN103546749B (en) | Method for optimizing HEVC (high efficiency video coding) residual coding by using residual coefficient distribution features and bayes theorem | |
KR20050089090A (en) | Fast mode decision making for interframe encoding | |
CN102067610A (en) | Rate control model adaptation based on slice dependencies for video coding | |
CN110933430B (en) | Secondary coding optimization method | |
Shen et al. | Ultra fast H. 264/AVC to HEVC transcoder | |
CN101867818B (en) | Selection method and device of macroblock mode | |
CN1589576A (en) | Reduced-complexity video decoding using larger pixel-grid motion compensation | |
CN100574447C (en) | Fast intraframe predicting mode selecting method based on the AVS video coding | |
CN110351552B (en) | Fast coding method in video coding | |
CN102932642A (en) | Interframe coding quick mode selection method | |
CN103384327A (en) | AVS fast mode selection algorithm based on adaptive threshold | |
CN101742288B (en) | Video noise reduction encoding method and video noise reduction encoding device | |
CN103442228A (en) | Quick frame inner transcoding method from H.264/AVC standard to HEVC standard and transcoder thereof | |
CN104754337A (en) | Video encoding method | |
CN108989818B (en) | Image coding parameter adjusting method and device | |
CN101883275B (en) | Video coding method | |
CN1457196A (en) | Video encoding method based on prediction time and space domain conerent movement vectors | |
WO2007139839A2 (en) | Methods and apparatuses for video compression intra prediction mode determination | |
CN102595137B (en) | Fast mode judging device and method based on image pixel block row/column pipelining |
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: 20120829 |