Remove I440 image support from libaom API and tools.
ABI is unaffected.
BUG=aomedia:1672
Change-Id: I12f88f396bd8c3c814a5a554a4702cc35036e858
diff --git a/aom/aom_image.h b/aom/aom_image.h
index dc86a35..2b04373 100644
--- a/aom/aom_image.h
+++ b/aom/aom_image.h
@@ -59,12 +59,10 @@
AOM_IMG_FMT_AOMI420 = AOM_IMG_FMT_PLANAR | 4,
AOM_IMG_FMT_I422 = AOM_IMG_FMT_PLANAR | 5,
AOM_IMG_FMT_I444 = AOM_IMG_FMT_PLANAR | 6,
- AOM_IMG_FMT_I440 = AOM_IMG_FMT_PLANAR | 7,
AOM_IMG_FMT_444A = AOM_IMG_FMT_PLANAR | AOM_IMG_FMT_HAS_ALPHA | 6,
AOM_IMG_FMT_I42016 = AOM_IMG_FMT_I420 | AOM_IMG_FMT_HIGHBITDEPTH,
AOM_IMG_FMT_I42216 = AOM_IMG_FMT_I422 | AOM_IMG_FMT_HIGHBITDEPTH,
AOM_IMG_FMT_I44416 = AOM_IMG_FMT_I444 | AOM_IMG_FMT_HIGHBITDEPTH,
- AOM_IMG_FMT_I44016 = AOM_IMG_FMT_I440 | AOM_IMG_FMT_HIGHBITDEPTH
} aom_img_fmt_t; /**< alias for enum aom_img_fmt */
/*!\brief List of supported color primaries */
diff --git a/aom/src/aom_image.c b/aom/src/aom_image.c
index e1176bd..130d48b 100644
--- a/aom/src/aom_image.c
+++ b/aom/src/aom_image.c
@@ -57,11 +57,9 @@
case AOM_IMG_FMT_AOMI420:
case AOM_IMG_FMT_AOMYV12: bps = 12; break;
case AOM_IMG_FMT_I422:
- case AOM_IMG_FMT_I440: bps = 16; break;
case AOM_IMG_FMT_I444: bps = 24; break;
case AOM_IMG_FMT_I42016: bps = 24; break;
case AOM_IMG_FMT_I42216:
- case AOM_IMG_FMT_I44016: bps = 32; break;
case AOM_IMG_FMT_I44416: bps = 48; break;
default: bps = 16; break;
}
@@ -80,12 +78,10 @@
switch (fmt) {
case AOM_IMG_FMT_I420:
- case AOM_IMG_FMT_I440:
case AOM_IMG_FMT_YV12:
case AOM_IMG_FMT_AOMI420:
case AOM_IMG_FMT_AOMYV12:
- case AOM_IMG_FMT_I42016:
- case AOM_IMG_FMT_I44016: ycs = 1; break;
+ case AOM_IMG_FMT_I42016: ycs = 1; break;
default: ycs = 0; break;
}
diff --git a/aomdec.c b/aomdec.c
index e01cf6a..e05153f 100644
--- a/aomdec.c
+++ b/aomdec.c
@@ -926,10 +926,6 @@
if (use_y4m) {
char y4m_buf[Y4M_BUFFER_SIZE] = { 0 };
size_t len = 0;
- if (img->fmt == AOM_IMG_FMT_I440 || img->fmt == AOM_IMG_FMT_I44016) {
- fprintf(stderr, "Cannot produce y4m output for 440 sampling.\n");
- goto fail;
- }
if (frame_out == 1) {
// Y4M file header
len = y4m_write_file_header(
diff --git a/aomenc.c b/aomenc.c
index 6afa006..9ec5518 100644
--- a/aomenc.c
+++ b/aomenc.c
@@ -140,8 +140,6 @@
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, "Number of passes (1/2)");
@@ -276,7 +274,6 @@
&use_i420,
&use_i422,
&use_i444,
- &use_i440,
&usage,
&threads,
&profile,
@@ -889,8 +886,6 @@
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))
@@ -1344,12 +1339,10 @@
case AOM_IMG_FMT_I420: return "I420";
case AOM_IMG_FMT_I422: return "I422";
case AOM_IMG_FMT_I444: return "I444";
- case AOM_IMG_FMT_I440: return "I440";
case AOM_IMG_FMT_YV12: return "YV12";
case AOM_IMG_FMT_I42016: return "I42016";
case AOM_IMG_FMT_I42216: return "I42216";
case AOM_IMG_FMT_I44416: return "I44416";
- case AOM_IMG_FMT_I44016: return "I44016";
default: return "Other";
}
}
@@ -1890,7 +1883,6 @@
case I420: input.fmt = AOM_IMG_FMT_I420; break;
case I422: input.fmt = AOM_IMG_FMT_I422; break;
case I444: input.fmt = AOM_IMG_FMT_I444; break;
- case I440: input.fmt = AOM_IMG_FMT_I440; break;
case YV12: input.fmt = AOM_IMG_FMT_YV12; break;
}
diff --git a/aomenc.h b/aomenc.h
index 1bb98e3..976079d 100644
--- a/aomenc.h
+++ b/aomenc.h
@@ -27,7 +27,6 @@
I420, // 4:2:0 8+ bit-depth
I422, // 4:2:2 8+ bit-depth
I444, // 4:4:4 8+ bit-depth
- I440, // 4:4:0 8+ bit-depth
YV12, // 4:2:0 with uv flipped, only 8-bit depth
} ColorInputType;
diff --git a/av1/av1_cx_iface.c b/av1/av1_cx_iface.c
index d709720..4ce959a 100644
--- a/av1/av1_cx_iface.c
+++ b/av1/av1_cx_iface.c
@@ -406,8 +406,6 @@
ERROR("Invalid image format. I422 images not supported in profile.");
}
break;
- case AOM_IMG_FMT_I440:
- case AOM_IMG_FMT_I44016:
default:
ERROR(
"Invalid image format. Only YV12, I420, I422, I444 images are "
@@ -427,11 +425,9 @@
case AOM_IMG_FMT_I420: return 12;
case AOM_IMG_FMT_I422: return 16;
case AOM_IMG_FMT_I444: return 24;
- case AOM_IMG_FMT_I440: return 16;
case AOM_IMG_FMT_I42016: return 24;
case AOM_IMG_FMT_I42216: return 32;
case AOM_IMG_FMT_I44416: return 48;
- case AOM_IMG_FMT_I44016: return 32;
default: assert(0 && "Invalid image format"); break;
}
return 0;
diff --git a/av1/av1_iface_common.h b/av1/av1_iface_common.h
index 7e76326..59db776 100644
--- a/av1/av1_iface_common.h
+++ b/av1/av1_iface_common.h
@@ -30,13 +30,8 @@
bps = 16;
}
} else {
- if (!yv12->subsampling_x) {
- img->fmt = AOM_IMG_FMT_I440;
- bps = 16;
- } else {
- img->fmt = AOM_IMG_FMT_I420;
- bps = 12;
- }
+ img->fmt = AOM_IMG_FMT_I420;
+ bps = 12;
}
img->cp = yv12->color_primaries;
img->tc = yv12->transfer_characteristics;
diff --git a/test/yuv_video_source.h b/test/yuv_video_source.h
index 88cabd5..51554af 100644
--- a/test/yuv_video_source.h
+++ b/test/yuv_video_source.h
@@ -86,11 +86,9 @@
switch (format) {
case AOM_IMG_FMT_I420: raw_size_ = width * height * 3 / 2; break;
case AOM_IMG_FMT_I422: raw_size_ = width * height * 2; break;
- case AOM_IMG_FMT_I440: raw_size_ = width * height * 2; break;
case AOM_IMG_FMT_I444: raw_size_ = width * height * 3; break;
case AOM_IMG_FMT_I42016: raw_size_ = width * height * 3; break;
case AOM_IMG_FMT_I42216: raw_size_ = width * height * 4; break;
- case AOM_IMG_FMT_I44016: raw_size_ = width * height * 4; break;
case AOM_IMG_FMT_I44416: raw_size_ = width * height * 6; break;
default: ASSERT_TRUE(0);
}
diff --git a/tools_common.c b/tools_common.c
index 49f46e3..7abc20c 100644
--- a/tools_common.c
+++ b/tools_common.c
@@ -250,8 +250,7 @@
switch (src->fmt) {
case AOM_IMG_FMT_I42016:
case AOM_IMG_FMT_I42216:
- case AOM_IMG_FMT_I44416:
- case AOM_IMG_FMT_I44016: break;
+ case AOM_IMG_FMT_I44416: break;
default: fatal("Unsupported image conversion"); break;
}
for (plane = 0; plane < 3; plane++) {
@@ -286,8 +285,7 @@
switch (src->fmt) {
case AOM_IMG_FMT_I420:
case AOM_IMG_FMT_I422:
- case AOM_IMG_FMT_I444:
- case AOM_IMG_FMT_I440: break;
+ case AOM_IMG_FMT_I444: break;
default: fatal("Unsupported image conversion"); break;
}
for (plane = 0; plane < 3; plane++) {
@@ -327,8 +325,7 @@
switch (dst->fmt) {
case AOM_IMG_FMT_I420:
case AOM_IMG_FMT_I422:
- case AOM_IMG_FMT_I444:
- case AOM_IMG_FMT_I440: break;
+ case AOM_IMG_FMT_I444: break;
default: fatal("Unsupported image conversion"); break;
}
for (plane = 0; plane < 3; plane++) {
@@ -362,8 +359,7 @@
switch (src->fmt) {
case AOM_IMG_FMT_I42016:
case AOM_IMG_FMT_I42216:
- case AOM_IMG_FMT_I44416:
- case AOM_IMG_FMT_I44016: break;
+ case AOM_IMG_FMT_I44416: break;
default: fatal("Unsupported image conversion"); break;
}
for (plane = 0; plane < 3; plane++) {
@@ -396,8 +392,7 @@
switch (dst->fmt) {
case AOM_IMG_FMT_I420:
case AOM_IMG_FMT_I422:
- case AOM_IMG_FMT_I444:
- case AOM_IMG_FMT_I440: break;
+ case AOM_IMG_FMT_I444: break;
default: fatal("Unsupported image conversion"); break;
}
for (plane = 0; plane < 3; plane++) {