Optimize x265 Rate Control: An Exploration of Lookahead in Frame Bit Allocation and Slice Type Decision

2019 
To improve the rate-distortion (R-D) quality, x265 rate-control makes a variety of vital decisions—such as scene cut detection, slice type decision, and coding-unit quantization parameter ( $QP$ ) offsets—leveraging on lookahead to evaluate the information propagation through the current and the near future consecutive frames. However, as the frame base $QP$ that dominates the bit amount allocated to one frame was only determined by the long-term complexity history in the original algorithm, the frame bit allocation became insensitive to the recent scene changes with the growth of coding time. In addition, the specified threshold in slice type decision, which was compared to the estimated frame coding costs to detect the B-type slice, did not consider the impacts of quantization. As mentioned earlier, the irrational elements degraded the rate accuracy and the R-D performance of x265. In this paper, the frame base $QP$ is determined with not only the coding complexity history but also the complexity changes and the data dependencies between the current and the near future pictures by exploring lookahead. Moreover, the quantization scale is introduced to the threshold specification in slice type decision, which identifies more pictures as B-type properly when increasing $QP$ . The proposed algorithms were conducted in x265 version 2.4. Experiments revealed that under the default preset (–preset medium), 0.617 dB on average and up to 1.705 dB Bjontegaard-Delta quality gains were achieved, while saving the encoding time by 1.13% and improving the rate accuracy by 4.2% on average.
    • Correction
    • Source
    • Cite
    • Save
    • Machine Reading By IdeaReader
    26
    References
    5
    Citations
    NaN
    KQI
    []