Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/videolan/dav1d.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonald S. Bultje <rsbultje@gmail.com>2018-11-17 00:32:40 +0300
committerRonald S. Bultje <rsbultje@gmail.com>2018-11-17 00:46:23 +0300
commit242c35f3e26e4384a5f1e68c86b269ba60d70ef4 (patch)
treee56d5f5c5619a514e5ae93f748019a8cd51eb83d
parent0fdee4daee5b70dcbfc8e3f3fd5d82095b57d6bf (diff)
If Y/AC is 0 (but lossless=0), only allow coding DCT_DCT
This is consistent with what libaom does. Should fix #175.
-rw-r--r--src/env.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/env.h b/src/env.h
index b0edb10..02e2614 100644
--- a/src/env.h
+++ b/src/env.h
@@ -127,9 +127,13 @@ static inline enum TxfmTypeSet get_ext_txtp_set(const enum RectTxfmSize tx,
const Av1FrameHeader *const hdr,
const int seg_id)
{
- if (hdr->segmentation.lossless[seg_id]) {
- assert(tx == (int) TX_4X4);
- return TXTP_SET_LOSSLESS;
+ if (!hdr->segmentation.qidx[seg_id]) {
+ if (hdr->segmentation.lossless[seg_id]) {
+ assert(tx == (int) TX_4X4);
+ return TXTP_SET_LOSSLESS;
+ } else {
+ return TXTP_SET_DCT;
+ }
}
const TxfmInfo *const t_dim = &dav1d_txfm_dimensions[tx];