summaryrefslogtreecommitdiff
path: root/vp8/vp8_cx_iface.c
diff options
context:
space:
mode:
authorDmitry Kovalev <dkovalev@google.com>2014-08-21 11:21:18 -0700
committerDmitry Kovalev <dkovalev@google.com>2014-08-21 11:21:18 -0700
commit48274c64a41e3d0f9fc94b71f86fb6fce6b1bc58 (patch)
treece76dd29b4ec6dafb7a5356cfa4f2af6255934c3 /vp8/vp8_cx_iface.c
parentdf083b266aac1a25044b7d43e630c51614791523 (diff)
downloadlibvpx-48274c64a41e3d0f9fc94b71f86fb6fce6b1bc58.tar
libvpx-48274c64a41e3d0f9fc94b71f86fb6fce6b1bc58.tar.gz
libvpx-48274c64a41e3d0f9fc94b71f86fb6fce6b1bc58.tar.bz2
libvpx-48274c64a41e3d0f9fc94b71f86fb6fce6b1bc58.zip
Removing extraconfig_map from vp8_cx_iface.c.
We have just one default set of extra config values, g_usage is never used with VP8. Change-Id: If05e2e87bf33c8db10c9d226dbc59381bae475eb
Diffstat (limited to 'vp8/vp8_cx_iface.c')
-rw-r--r--vp8/vp8_cx_iface.c58
1 files changed, 17 insertions, 41 deletions
diff --git a/vp8/vp8_cx_iface.c b/vp8/vp8_cx_iface.c
index f12b88613..1654cd821 100644
--- a/vp8/vp8_cx_iface.c
+++ b/vp8/vp8_cx_iface.c
@@ -39,40 +39,28 @@ struct vp8_extracfg
};
-struct extraconfig_map
-{
- int usage;
- struct vp8_extracfg cfg;
-};
-
-static const struct extraconfig_map extracfg_map[] =
-{
- {
- 0,
- {
- NULL,
+static struct vp8_extracfg default_extracfg = {
+ NULL,
#if !(CONFIG_REALTIME_ONLY)
- 0, /* cpu_used */
+ 0, /* cpu_used */
#else
- 4, /* cpu_used */
+ 4, /* cpu_used */
#endif
- 0, /* enable_auto_alt_ref */
- 0, /* noise_sensitivity */
- 0, /* Sharpness */
- 0, /* static_thresh */
+ 0, /* enable_auto_alt_ref */
+ 0, /* noise_sensitivity */
+ 0, /* Sharpness */
+ 0, /* static_thresh */
#if (CONFIG_REALTIME_ONLY & CONFIG_ONTHEFLY_BITPACKING)
- VP8_EIGHT_TOKENPARTITION,
+ VP8_EIGHT_TOKENPARTITION,
#else
- VP8_ONE_TOKENPARTITION, /* token_partitions */
+ VP8_ONE_TOKENPARTITION, /* token_partitions */
#endif
- 0, /* arnr_max_frames */
- 3, /* arnr_strength */
- 3, /* arnr_type*/
- 0, /* tuning*/
- 10, /* cq_level */
- 0, /* rc_max_intra_bitrate_pct */
- }
- }
+ 0, /* arnr_max_frames */
+ 3, /* arnr_strength */
+ 3, /* arnr_type*/
+ 0, /* tuning*/
+ 10, /* cq_level */
+ 0, /* rc_max_intra_bitrate_pct */
};
struct vpx_codec_alg_priv
@@ -632,9 +620,6 @@ static vpx_codec_err_t vp8e_init(vpx_codec_ctx_t *ctx,
{
vpx_codec_err_t res = VPX_CODEC_OK;
struct vpx_codec_alg_priv *priv;
- vpx_codec_enc_cfg_t *cfg;
- unsigned int i;
-
struct VP8_COMP *optr;
vp8_rtcd();
@@ -662,17 +647,8 @@ static vpx_codec_err_t vp8e_init(vpx_codec_ctx_t *ctx,
ctx->config.enc = &ctx->priv->alg_priv->cfg;
}
- cfg = &ctx->priv->alg_priv->cfg;
-
- /* Select the extra vp8 configuration table based on the current
- * usage value. If the current usage value isn't found, use the
- * values for usage case 0.
- */
- for (i = 0;
- extracfg_map[i].usage && extracfg_map[i].usage != cfg->g_usage;
- i++);
- priv->vp8_cfg = extracfg_map[i].cfg;
+ priv->vp8_cfg = default_extracfg;
priv->vp8_cfg.pkt_list = &priv->pkt_list.head;
priv->cx_data_sz = priv->cfg.g_w * priv->cfg.g_h * 3 / 2 * 2;