summaryrefslogtreecommitdiffstats
path: root/third_party/aom/av1/common/cdef.c
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/aom/av1/common/cdef.c')
-rw-r--r--third_party/aom/av1/common/cdef.c20
1 files changed, 6 insertions, 14 deletions
diff --git a/third_party/aom/av1/common/cdef.c b/third_party/aom/av1/common/cdef.c
index 53dff98b7..b35acfc82 100644
--- a/third_party/aom/av1/common/cdef.c
+++ b/third_party/aom/av1/common/cdef.c
@@ -26,13 +26,9 @@ int sb_all_skip(const AV1_COMMON *const cm, int mi_row, int mi_col) {
int skip = 1;
maxc = cm->mi_cols - mi_col;
maxr = cm->mi_rows - mi_row;
-#if CONFIG_EXT_PARTITION
- if (maxr > cm->mib_size_log2) maxr = cm->mib_size_log2;
- if (maxc > cm->mib_size_log2) maxc = cm->mib_size_log2;
-#else
- if (maxr > MAX_MIB_SIZE) maxr = MAX_MIB_SIZE;
- if (maxc > MAX_MIB_SIZE) maxc = MAX_MIB_SIZE;
-#endif
+
+ maxr = AOMMIN(maxr, cm->mib_size);
+ maxc = AOMMIN(maxc, cm->mib_size);
for (r = 0; r < maxr; r++) {
for (c = 0; c < maxc; c++) {
@@ -63,13 +59,9 @@ int sb_compute_dering_list(const AV1_COMMON *const cm, int mi_row, int mi_col,
grid = cm->mi_grid_visible;
maxc = cm->mi_cols - mi_col;
maxr = cm->mi_rows - mi_row;
-#if CONFIG_EXT_PARTITION
- if (maxr > cm->mib_size_log2) maxr = cm->mib_size_log2;
- if (maxc > cm->mib_size_log2) maxc = cm->mib_size_log2;
-#else
- if (maxr > MAX_MIB_SIZE) maxr = MAX_MIB_SIZE;
- if (maxc > MAX_MIB_SIZE) maxc = MAX_MIB_SIZE;
-#endif
+
+ maxr = AOMMIN(maxr, cm->mib_size);
+ maxc = AOMMIN(maxc, cm->mib_size);
const int r_step = mi_size_high[BLOCK_8X8];
const int c_step = mi_size_wide[BLOCK_8X8];