shithub: libvpx

Download patch

ref: ca18ac8e4f42cf62878b764d64c2de9606df3a21
parent: dff4d376eaff3460e930711807ce865ff76aff3a
author: James Zern <[email protected]>
date: Mon Apr 29 11:21:40 EDT 2019

vp8cx.h,vpxenc: add note about alt ref ranges

BUG=webm:1597

Change-Id: I56345ec621a06dfe1eae7f205874f34bfb40e6e5

--- a/vpx/vp8cx.h
+++ b/vpx/vp8cx.h
@@ -156,6 +156,9 @@
 
   /*!\brief Codec control function to enable automatic use of arf frames.
    *
+   * \note Valid range for VP8: 0..1
+   * \note Valid range for VP9: 0..6
+   *
    * Supported in codecs: VP8, VP9
    */
   VP8E_SET_ENABLEAUTOALTREF,
--- a/vpxenc.c
+++ b/vpxenc.c
@@ -312,8 +312,6 @@
             "Increase sharpness at the expense of lower PSNR. (0..7)");
 static const arg_def_t static_thresh =
     ARG_DEF(NULL, "static-thresh", 1, "Motion detection threshold");
-static const arg_def_t auto_altref =
-    ARG_DEF(NULL, "auto-alt-ref", 1, "Enable automatic alt reference frames");
 static const arg_def_t arnr_maxframes =
     ARG_DEF(NULL, "arnr-maxframes", 1, "AltRef max frames (0..15)");
 static const arg_def_t arnr_strength =
@@ -335,12 +333,14 @@
 #if CONFIG_VP8_ENCODER
 static const arg_def_t cpu_used_vp8 =
     ARG_DEF(NULL, "cpu-used", 1, "CPU Used (-16..16)");
+static const arg_def_t auto_altref_vp8 = ARG_DEF(
+    NULL, "auto-alt-ref", 1, "Enable automatic alt reference frames. (0..1)");
 static const arg_def_t token_parts =
     ARG_DEF(NULL, "token-parts", 1, "Number of token partitions to use, log2");
 static const arg_def_t screen_content_mode =
     ARG_DEF(NULL, "screen-content-mode", 1, "Screen content mode");
 static const arg_def_t *vp8_args[] = { &cpu_used_vp8,
-                                       &auto_altref,
+                                       &auto_altref_vp8,
                                        &noise_sens,
                                        &sharpness,
                                        &static_thresh,
@@ -374,6 +374,9 @@
 #if CONFIG_VP9_ENCODER
 static const arg_def_t cpu_used_vp9 =
     ARG_DEF(NULL, "cpu-used", 1, "CPU Used (-9..9)");
+static const arg_def_t auto_altref_vp9 = ARG_DEF(
+    NULL, "auto-alt-ref", 1,
+    "Enable automatic alt reference frames, 2+ enables multi-layer. (0..6)");
 static const arg_def_t tile_cols =
     ARG_DEF(NULL, "tile-columns", 1, "Number of tile columns to use, log2");
 static const arg_def_t tile_rows =
@@ -463,7 +466,7 @@
 
 #if CONFIG_VP9_ENCODER
 static const arg_def_t *vp9_args[] = { &cpu_used_vp9,
-                                       &auto_altref,
+                                       &auto_altref_vp9,
                                        &sharpness,
                                        &static_thresh,
                                        &tile_cols,