[x264-devel] commit: Macroblock-tree ratecontrol (Jason Garrett-Glaser )

git version control git at videolan.org
Fri Aug 7 08:23:12 CEST 2009


x264 | branch: master | Jason Garrett-Glaser <darkshikari at gmail.com> | Tue Aug  4 17:46:33 2009 -0700| [bb66c482242a0747823661b212114c1a2f015fe3] | committer: Jason Garrett-Glaser 

Macroblock-tree ratecontrol
On by default; can be turned off with --no-mbtree.
Uses a large lookahead to track temporal propagation of data and weight quality accordingly.
Requires a very large separate statsfile (2 bytes per macroblock) in multi-pass mode.
Doesn't work with b-pyramid yet.
Note that MB-tree inherently measures quality different from the standard qcomp method, so bitrates produced by CRF may change somewhat.
This makes the "medium" preset a bit slower.  Accordingly, make "fast" slower as well, and introduce a new preset "faster" between "fast" and "veryfast".
All presets "fast" and above will have MB-tree on.
Add a new option, --rc-lookahead, to control the distance MB tree looks ahead to perform propagation analysis.
Default is 40; larger values will be slower and require more memory but give more accurate results.
This value will be used in the future to control ratecontrol lookahead (VBV).
Add a new option, --no-psy, to disable all psy optimizations that don't improve PSNR or SSIM.
This disables psy-RD/trellis, but also other more subtle internal psy optimizations that can't be controlled directly via external parameters.
Quality improvement from MB-tree is about 2-70% depending on content.
Strength of MB-tree adjustments can be tweaked using qcompress; higher values mean lower MB-tree strength.
Note that MB-tree may perform slightly suboptimally on fades; this will be fixed by weighted prediction, which is coming soon.

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=bb66c482242a0747823661b212114c1a2f015fe3
---

 common/common.c       |   22 ++-
 common/common.h       |   50 ++++++-
 common/frame.c        |   10 +-
 common/frame.h        |    3 +
 common/osdep.h        |    9 +-
 encoder/analyse.c     |    4 +-
 encoder/encoder.c     |   56 ++++++-
 encoder/ratecontrol.c |  203 +++++++++++++++++-------
 encoder/ratecontrol.h |    3 +-
 encoder/slicetype.c   |  424 ++++++++++++++++++++++++++++++++++++++-----------
 x264.c                |   34 +++-
 x264.h                |    5 +-
 12 files changed, 642 insertions(+), 181 deletions(-)

Diff:   http://git.videolan.org/gitweb.cgi/x264.git/?a=commitdiff;h=bb66c482242a0747823661b212114c1a2f015fe3


More information about the x264-devel mailing list