pub fn encode_tx_block<T: Pixel, W: Writer>(
fi: &FrameInvariants<T>,
ts: &mut TileStateMut<'_, T>,
cw: &mut ContextWriter<'_>,
w: &mut W,
p: usize,
tile_partition_bo: TileBlockOffset,
bx: usize,
by: usize,
tx_bo: TileBlockOffset,
mode: PredictionMode,
tx_size: TxSize,
tx_type: TxType,
bsize: BlockSize,
po: PlaneOffset,
skip: bool,
qidx: u8,
ac: &[i16],
pred_intra_param: IntraParam,
rdo_type: RDOType,
need_recon_pixel: bool,
) -> (bool, ScaledDistortion)
Expand description
For a transform block, predict, transform, quantize, write coefficients to a bitstream, dequantize, inverse-transform.
ยงPanics
- If the block size is invalid for subsampling
- If a tx type other than DCT is used for 64x64 blocks