Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
vp9 [2023/04/02 21:15]
beandog [VP9]
vp9 [2023/04/19 21:54] (current)
beandog [ffmpeg]
Line 6: Line 6:
   * [[http://​ffmpeg.org/​ffmpeg-all.html#​libvpx|ffmpeg libvpx documentation]]   * [[http://​ffmpeg.org/​ffmpeg-all.html#​libvpx|ffmpeg libvpx documentation]]
   * [[https://​developers.google.com/​media/​vp9/​bitrate-modes|VP9 Bitrate Modes in Detail]] - Google'​s   * [[https://​developers.google.com/​media/​vp9/​bitrate-modes|VP9 Bitrate Modes in Detail]] - Google'​s
-  * [[https://​www.texpion.com/​2018/​07/​av1-vs-vp9-vs-avc-h264-vs-hevc-h265-1-lossless.html|AV1 vs VP9 vs AVC (h.264) vs HEVC (h.265): Part I - Lossless]] - a good read, I like this one 
-  * [[https://​github.com/​deterenkelt/​Nadeshiko/​wiki/​Pitfalls-in-VP9|Pitfalls in VP9]] - goes in a bit of detail about quality levels 
   * [[http://​wiki.webmproject.org/​vp9/​vp9-tips|VP9 Tips - Encoding Modes and Recommended Command Line Options]] - upstream'​s wiki   * [[http://​wiki.webmproject.org/​vp9/​vp9-tips|VP9 Tips - Encoding Modes and Recommended Command Line Options]] - upstream'​s wiki
   * [[https://​slhck.info/​video/​2017/​02/​24/​crf-guide.html|CRF Guide (Constant Rate Factor in x264, x265 and libvpx)]]   * [[https://​slhck.info/​video/​2017/​02/​24/​crf-guide.html|CRF Guide (Constant Rate Factor in x264, x265 and libvpx)]]
Line 16: Line 14:
 By default, ''​vpxenc''​ will use 2-pass method for encoding. By default, ''​vpxenc''​ will use 2-pass method for encoding.
  
-As far as I can tellthere's no default ​when using CQ mode. I don't know what variables ​it'​s ​using for default when doing a 1-pass encode.+To gain a CRF-type resultuse ''​--end-usage=cq --cq-level=<​arg>''​ format, and then a 1-pass encode ''​--passes=1''​ Using this, ''​vpxenc''​ uses a default CQ of 32. 
 + 
 +get different encoding times on multiple runs, even though ​it'​s ​producing the exact same files, so watch out for that. 
 + 
 ==== HandBrake ==== ==== HandBrake ====
  
 By default, HandBrake uses a CQ of 22. By default, HandBrake uses a CQ of 22.
 +
 +HandBrake will only use 2-passes if a bitrate is set as well.
 +
 +==== ffmpeg ====
 +
 +You can use ''​ffmpeg''​ to get a deep level of output to see what it's doing, it uses the default CRF of 32:
 +
 +<​code>​
 +ffmpeg -loglevel debug -i sample.y4m -vcodec libvpx-vp9 sample.webm
 +</​code>​
 +
 +Relevant output:
 +
 +<​code>​
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP8E_SET_CPUUSED: ​            1
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP8E_SET_ARNR_MAXFRAMES: ​     0
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP8E_SET_ARNR_STRENGTH: ​      3
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP8E_SET_ARNR_TYPE: ​          3
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP8E_SET_STATIC_THRESHOLD: ​   0
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP8E_SET_CQ_LEVEL: ​           32
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP9E_SET_COLOR_SPACE: ​        0
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP9E_SET_COLOR_RANGE: ​        0
 +[libvpx-vp9 @ 0x55a6e613e3c0] ​  ​VP9E_SET_TARGET_LEVEL: ​       255
 +</​code>​

Navigation