intrabc: Add initial skeleton
Missing features:
* RDOPT (Forced on for certain blocks)
* Any form of border extension
* Non MI sized right and bottom edges
* MV prediction
Present features:
* Force intrabc for some blocks
* Carry intrabc in the bitstream
* Validate DV is causal
* Reconstruct intrabc block assuming border extension is unnecessary
Change-Id: Ib1f6868e89bfacc2a4edfc876485bad1b347263b
diff --git a/av1/encoder/encodeframe.c b/av1/encoder/encodeframe.c
index 8ab42d2..23beab2 100644
--- a/av1/encoder/encodeframe.c
+++ b/av1/encoder/encodeframe.c
@@ -5882,6 +5882,11 @@
const int unify_bsize = 0;
const BLOCK_SIZE block_size = AOMMAX(bsize, BLOCK_8X8);
#endif
+#if CONFIG_INTRABC
+ // TODO(aconverse@google.com): Remove this when the non-synthetic encoder
+ // side intrabc is added
+ assert(IMPLIES(is_intrabc_block(mbmi), mbmi->skip));
+#endif
#if CONFIG_PVQ
x->pvq_speed = 0;
@@ -5964,7 +5969,11 @@
set_ref_ptrs(cm, xd, mbmi->ref_frame[0], mbmi->ref_frame[1]);
for (ref = 0; ref < 1 + is_compound; ++ref) {
YV12_BUFFER_CONFIG *cfg = get_ref_frame_buffer(cpi, mbmi->ref_frame[ref]);
+#if CONFIG_INTRABC
+ assert(IMPLIES(!is_intrabc_block(mbmi), cfg));
+#else
assert(cfg != NULL);
+#endif // !CONFIG_INTRABC
av1_setup_pre_planes(xd, ref, cfg, mi_row, mi_col,
&xd->block_refs[ref]->sf);
}