avcodec/cbs_av1: Add tx mode enum values

Signed-off-by: Fei Wang <fei.w.wang@intel.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
pull/390/head
Fei Wang 1 year ago committed by Haihao Xiang
parent 95b5c81729
commit 6c3a5d625f
  1. 7
      libavcodec/av1.h
  2. 4
      libavcodec/cbs_av1_syntax_template.c

@ -175,6 +175,13 @@ enum {
AV1_RESTORE_SWITCHABLE = 3, AV1_RESTORE_SWITCHABLE = 3,
}; };
// TX mode (section 6.8.21)
enum {
AV1_ONLY_4X4 = 0,
AV1_TX_MODE_LARGEST = 1,
AV1_TX_MODE_SELECT = 2,
};
// Sequence Headers are actually unbounded because one can use // Sequence Headers are actually unbounded because one can use
// an arbitrary number of leading zeroes when encoding via uvlc. // an arbitrary number of leading zeroes when encoding via uvlc.
// The following estimate is based around using the lowest number // The following estimate is based around using the lowest number

@ -1028,9 +1028,9 @@ static int FUNC(read_tx_mode)(CodedBitstreamContext *ctx, RWContext *rw,
int err; int err;
if (priv->coded_lossless) if (priv->coded_lossless)
infer(tx_mode, 0); infer(tx_mode, AV1_ONLY_4X4);
else else
increment(tx_mode, 1, 2); increment(tx_mode, AV1_TX_MODE_LARGEST, AV1_TX_MODE_SELECT);
return 0; return 0;
} }

Loading…
Cancel
Save