Skip to content

Commit 730876f

Browse files
nicogmta
authored andcommitted
LibGfx/JPEG: Add a comment to inverse_dct_8x8()
See here: #22739 (comment) No behavior change.
1 parent e159823 commit 730876f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Userland/Libraries/LibGfx/ImageFormats/JPEGLoader.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1432,6 +1432,8 @@ static void dequantize(JPEGLoadingContext& context, Vector<Macroblock>& macroblo
14321432

14331433
static void inverse_dct_8x8(i16* block_component)
14341434
{
1435+
// Does a 2-D IDCT by doing two 1-D IDCTs as described in https://unix4lyfe.org/dct/
1436+
// The 1-D DCT idea is described at https://unix4lyfe.org/dct-1d/, read aan.cc from bottom to top.
14351437
static float const m0 = 2.0f * AK::cos(1.0f / 16.0f * 2.0f * AK::Pi<float>);
14361438
static float const m1 = 2.0f * AK::cos(2.0f / 16.0f * 2.0f * AK::Pi<float>);
14371439
static float const m3 = 2.0f * AK::cos(2.0f / 16.0f * 2.0f * AK::Pi<float>);

0 commit comments

Comments
 (0)