1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 20:07:34 +00:00

LibVideo/VP9: Move quantizer indices into FrameContext

This also renames (most?) of the related quantizer functions and
variables to make more sense. I haven't determined what AC/DC stands
for here, but it may be just an arbitrary naming scheme for the first
and subsequent coefficients used to quantize the residuals for a block.
This commit is contained in:
Zaggy1024 2022-11-23 06:26:02 -06:00 committed by Andreas Kling
parent 0df5c1f32f
commit f4e835635f
5 changed files with 50 additions and 42 deletions

View file

@ -77,17 +77,17 @@ private:
u16 dc_q(u8 bit_depth, u8 b);
u16 ac_q(u8 bit_depth, u8 b);
// Returns the quantizer index for the current block
u8 get_qindex();
u8 get_base_quantizer_index(BlockContext const&);
// Returns the quantizer value for the dc coefficient for a particular plane
u16 get_dc_quant(u8 bit_depth, u8 plane);
u16 get_dc_quantizer(BlockContext const&, u8 plane);
// Returns the quantizer value for the ac coefficient for a particular plane
u16 get_ac_quant(u8 bit_depth, u8 plane);
u16 get_ac_quantizer(BlockContext const&, u8 plane);
// (8.6.2) Reconstruct process
DecoderErrorOr<void> reconstruct(u8 plane, BlockContext const&, u32 transform_block_x, u32 transform_block_y, TXSize transform_block_size);
// (8.7) Inverse transform process
DecoderErrorOr<void> inverse_transform_2d(u8 bit_depth, Span<Intermediate> dequantized, u8 log2_of_block_size);
DecoderErrorOr<void> inverse_transform_2d(BlockContext const&, Span<Intermediate> dequantized, u8 log2_of_block_size);
// (8.7.1) 1D Transforms
// (8.7.1.1) Butterfly functions