IP Library Granted Patent US 9,906,792
Granted Patent B2
US 9,906,792 · App. 14/596,971 · Granted Feb 27, 2018

Rate control in video encoding

Inventors: Dominic Hugo Symes (Cambridge, GB); Ola Hugosson (Lund, SE); Erik Persson (Lund, SE)
Assignee: ARM Limited
H04N19/124H04N19/13H04N19/15H04N19/176H04N19/91
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,906,792
App. No.
14/596,971
Granted
Feb 27, 2018
Kind
B2
Abstract

A video encoder and method of video encoding are provided. At an encoding stage a selected degree of quantization is applied to the encoding of macroblocks of the input video sequence and quantized part-encoded macroblocks are generated. Quantization circuitry in the encoding stage is configured to select the selected degree of quantization for each macroblock in a current slice in dependence on a complexity estimate indicative of the expected entropy encoding complexity of a predetermined set of the quantized part-encoded macroblocks defined for that macroblock.

Claims (48)

1. A video encoder configured to perform a video encoding process comprising receiving an input video sequence and encoding the input video sequence on a slice-basis into an output bitstream, the video encoder comprising:

an encoding stage comprising quantization circuitry configured to:

apply a selected degree of quantization to the encoding of macroblocks of the input video sequence to generate quantized part-encoded macroblocks,

select the selected degree of quantization for each macroblock in a current slice in dependence on a complexity estimate indicative of an expected entropy encoding complexity of a predetermined set of the quantized part-encoded macroblocks defined for that macroblock and does not depend on quantized part-encoded macroblocks outside the predetermined set, and

receive an indication of an output bitstream bitrate from the video encoder and adapt the selected degree of quantization in dependence on a difference between a user-specified target bitrate for the output bitstream and the output bitstream bitrate,

wherein the video encoder is configured to apply a variable delay to the indication of the output bitstream bitrate from the video encoder such that a current picture being quantized by the quantization circuitry is dependent on a previous picture,

wherein a predetermined number of pictures separates the current picture from the previous picture regardless of whether the video encoder has already encoded beyond the previous picture, and

wherein for at least one macroblock of the current slice the predetermined set does not include all previous output bitstream order macroblocks of the current slice.

2. The video encoder as claimed in claim 1 , wherein the video encoder comprises multiple processor cores each configured to perform the video encoding process on a respective portion of the current slice, wherein the encoding stage of each of the multiple processor cores is configured not to operate on a selected macroblock in its respective portion until all macroblocks of the predetermined set defined for the selected macroblock have been processed by the encoding stage of one of the multiple processor cores.

3. The video encoder as claimed in claim 2 , wherein the respective portion of the current slice on which each processor core of the multiple processor cores is configured to perform the video encoding process is a horizontal stripe across a frame of the input video sequence.

4. The video encoder as claimed in claim 1 , wherein the encoding stage comprises transformation circuitry configured to apply transform coding to the encoding of macroblocks of the input video sequence, and the encoding stage is configured to determine the complexity estimate for each macroblock to which the transformation circuitry applies the transform coding.

5. The video encoder as claimed in claim 1 , wherein the complexity estimate is calculated on the basis of a number of bits in each quantized coefficient of the part-encoded macroblock processed by the encoding stage.

6. The video encoder as claimed in claim 1 , wherein the complexity estimate is calculated on the basis of a number of significant bits in each quantized coefficient of the part-encoded macroblock processed by the encoding stage.

7. The video encoder as claimed in claim 1 , wherein the complexity estimate is calculated on the basis of a constant plus a number of significant bits in each quantized coefficient of the part-encoded macroblock processed by the encoding stage.

8. The video encoder as claimed in claim 1 , wherein the complexity estimate is calculated on the basis of an absolute value of each quantized coefficient of the part-encoded macroblock processed by the encoding stage.

9. The video encoder as claimed in claim 1 , wherein the complexity estimate is a sum over complexity estimates for each non-zero quantized coefficient of the part-encoded macroblock processed by the encoding stage.

10. The video encoder as claimed in claim 1 , wherein the predetermined set only comprises quantized part-encoded macroblocks in the current slice on which that macroblock is dependent for reference frame reconstruction.

11. The video encoder as claimed in claim 1 , wherein the predetermined set only comprises macroblocks which precede that macroblock in raster scan order.

12. The video encoder as claimed in claim 1 , wherein the video encoder is configured to perform the video encoding process on each frame of the input video sequence beginning with an upper-left-most macroblock in the frame and ending with a lower-right-most macroblock in the frame,

and wherein the predetermined set only comprises macroblocks which lie on, or upwards and leftwards of, a line of macroblocks running diagonally through that macroblock in a lower-left to upper-right direction.

13. The video encoder as claimed in claim 1 , wherein the video encoder comprises multiple processor cores each configured to perform the video encoding process on a respective portion of the current slice,

and wherein the video encoder is further configured to determine the predetermined number of pictures which separates the current picture from the previous picture as: a number of the multiple processor cores divided by a minimum number of slices per frame, plus a constant.

14. The video encoder as claimed in claim 1 , wherein the quantization circuitry is configured to select a quantization algorithm to use to produce the quantized part-encoded macroblocks for each new frame in the input video sequence.

15. The video encoder as claimed in claim 14 , wherein the quantization circuitry is configured to select the quantization algorithm to use to produce the quantized part-encoded macroblocks for each new stripe in the input video sequence.

16. The video encoder as claimed in claim 15 , wherein the quantization circuitry is configured to select the quantization algorithm to use to produce the quantized part-encoded macroblocks for each new macroblock in the input video sequence.

17. The video encoder as claimed in claim 1 , wherein the quantization circuitry is configured to define the predetermined set of the quantized part-encoded macroblocks in the current slice for a first macroblock of a new frame in the input video sequence as a selected macroblock in a last row of an immediately preceding frame in the input video sequence.

18. The video encoder as claimed in claim 17 , wherein the selected macroblock is the second macroblock in the last row of the immediately preceding frame.

19. The video encoder as claimed in claim 1 , further comprising:

an intermediate storage unit into which the encoding stage is configured to store the quantized part-encoded macroblocks; and

a second encoding stage comprising entropy encoding circuitry configured to retrieve the quantized part-encoded macroblocks from the intermediate storage unit and to entropy encode the quantized part-encoded macroblocks to generate the output bitstream.

20. A method of performing video encoding to encode an input video sequence on a slice-basis into an output bitstream comprising the steps of:

receiving the input video sequence; and

applying a selected degree of quantization to the encoding of macroblocks of the input video sequence to generate quantized part-encoded macroblocks,

wherein the selected degree of quantization for each macroblock in a current slice is selected in dependence on a complexity estimate indicative of an expected entropy encoding complexity of a predetermined set of the quantized part-encoded macroblocks defined for that macroblock and does not depend on quantized part-encoded macroblocks outside the predetermined set,

receiving an indication of an output bitstream bitrate from the video encoder,

adapting the selected degree of quantization in dependence on a difference between a user-specified target bitrate for the output bitstream and the output bitstream bitrate, and

applying a variable delay to the indication of the output bitstream bitrate from the video encoder such that a current picture being quantized by the quantization circuitry is dependent on a previous picture,

wherein a predetermined number of pictures separates the current picture from the previous picture regardless of whether the video encoder has already encoded beyond the previous picture, and

wherein for at least one macroblock of the current slice the predetermined set does not include all previous output bitstream order macroblocks of the current slice.

21. A video encoder configured to perform a video encoding process comprising receiving an input video sequence and encoding the input video sequence on a slice-basis into an output bitstream, the video encoder comprising:

means for receiving the input video sequence; and

means for applying a selected degree of quantization to the encoding of macroblocks of the input video sequence to generate quantized part-encoded macroblocks,

wherein the selected degree of quantization for each macroblock in a current slice is selected in dependence on a complexity estimate indicative of an expected entropy encoding complexity of a predetermined set of the quantized part-encoded macroblocks defined for that macroblock and does not depend on quantized part-encoded macroblocks outside the predetermined set,

means for receiving an indication of an output bitstream bitrate from the video encoder,

means for adapting the selected degree of quantization in dependence on a difference between a user-specified target bitrate for the output bitstream and the output bitstream bitrate, and

means for applying a variable delay to the indication of the output bitstream bitrate from the video encoder such that a current picture being quantized by the quantization circuitry is dependent on a previous picture,

wherein a predetermined number of pictures separates the current picture from the previous picture regardless of whether the video encoder has already encoded beyond the previous picture, and

wherein for at least one macroblock of the current slice the predetermined set does not include all previous output bitstream order macroblocks of the current slice.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 8, 2015
From: SYMES, DOMINIC HUGO; HUGOSSON, OLA; PERSSON, ERIK
To: ARM LIMITED
Reel/Frame 035360/0011 →
Priority Claims (1)
GB 1402934.2 · Feb 19, 2014 · national
Continuity (1)
Related Publication 20150237346A1 · Aug 20, 2015