summaryrefslogtreecommitdiff
path: root/vpxenc.c
diff options
context:
space:
mode:
authorDeb Mukherjee <debargha@google.com>2014-10-01 12:17:37 -0700
committerDeb Mukherjee <debargha@google.com>2014-10-01 16:51:48 -0700
commita30774c50d2b1b626b05a99dcd29aa766f0b223b (patch)
tree37c7d40913ec6fd72079b18e5f3219f4c02d2f7d /vpxenc.c
parent30fbf23fdae441441bf5d6b71665a1b35560fbf8 (diff)
downloadlibvpx-a30774c50d2b1b626b05a99dcd29aa766f0b223b.tar.gz
libvpx-a30774c50d2b1b626b05a99dcd29aa766f0b223b.tar.bz2
libvpx-a30774c50d2b1b626b05a99dcd29aa766f0b223b.zip
Adds support of 440 content.
Adds enums and corresponding vpx level code. Change-Id: Ia402d47490a4466988d7edc6b7e3e5163f20a381
Diffstat (limited to 'vpxenc.c')
-rw-r--r--vpxenc.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/vpxenc.c b/vpxenc.c
index a074400f3..53a291152 100644
--- a/vpxenc.c
+++ b/vpxenc.c
@@ -140,6 +140,8 @@ static const arg_def_t use_i422 = ARG_DEF(NULL, "i422", 0,
"Input file is I422");
static const arg_def_t use_i444 = ARG_DEF(NULL, "i444", 0,
"Input file is I444");
+static const arg_def_t use_i440 = ARG_DEF(NULL, "i440", 0,
+ "Input file is I440");
static const arg_def_t codecarg = ARG_DEF(NULL, "codec", 1,
"Codec to use");
static const arg_def_t passes = ARG_DEF("p", "passes", 1,
@@ -244,7 +246,7 @@ static const arg_def_t lag_in_frames = ARG_DEF(NULL, "lag-in-frames", 1,
"Max number of frames to lag");
static const arg_def_t *global_args[] = {
- &use_yv12, &use_i420, &use_i422, &use_i444,
+ &use_yv12, &use_i420, &use_i422, &use_i444, &use_i440,
&usage, &threads, &profile,
&width, &height,
#if CONFIG_WEBM_IO
@@ -829,6 +831,8 @@ static void parse_global_config(struct VpxEncoderConfig *global, char **argv) {
global->color_type = I422;
else if (arg_match(&arg, &use_i444, argi))
global->color_type = I444;
+ else if (arg_match(&arg, &use_i440, argi))
+ global->color_type = I440;
else if (arg_match(&arg, &quietarg, argi))
global->quiet = 1;
else if (arg_match(&arg, &verbosearg, argi))
@@ -1288,7 +1292,12 @@ static const char* image_format_to_string(vpx_img_fmt_t f) {
case VPX_IMG_FMT_I420: return "I420";
case VPX_IMG_FMT_I422: return "I422";
case VPX_IMG_FMT_I444: return "I444";
+ case VPX_IMG_FMT_I440: return "I440";
case VPX_IMG_FMT_YV12: return "YV12";
+ case VPX_IMG_FMT_I42016: return "I42016";
+ case VPX_IMG_FMT_I42216: return "I42216";
+ case VPX_IMG_FMT_I44416: return "I44416";
+ case VPX_IMG_FMT_I44016: return "I44016";
default: return "Other";
}
}
@@ -1734,6 +1743,7 @@ static void high_img_upshift(vpx_image_t *dst, vpx_image_t *src,
case VPX_IMG_FMT_I42016:
case VPX_IMG_FMT_I42216:
case VPX_IMG_FMT_I44416:
+ case VPX_IMG_FMT_I44016:
break;
default:
fatal("Unsupported image conversion");
@@ -1774,6 +1784,7 @@ static void low_img_upshift(vpx_image_t *dst, vpx_image_t *src,
case VPX_IMG_FMT_I420:
case VPX_IMG_FMT_I422:
case VPX_IMG_FMT_I444:
+ case VPX_IMG_FMT_I440:
break;
default:
fatal("Unsupported image conversion");
@@ -1819,6 +1830,7 @@ static void img_cast_16_to_8(vpx_image_t *dst, vpx_image_t *src) {
case VPX_IMG_FMT_I420:
case VPX_IMG_FMT_I422:
case VPX_IMG_FMT_I444:
+ case VPX_IMG_FMT_I440:
break;
default:
fatal("Unsupported image conversion");
@@ -1993,6 +2005,9 @@ int main(int argc, const char **argv_) {
case I444:
input.fmt = VPX_IMG_FMT_I444;
break;
+ case I440:
+ input.fmt = VPX_IMG_FMT_I440;
+ break;
case YV12:
input.fmt = VPX_IMG_FMT_YV12;
break;