user1604573
user1604573

Reputation: 185

what is the meaning of DC and AC in jpeg file?

I am writing decompressor for jpeg files I know that it's very complex process but anyway I have read this tutorial http://www.impulseadventure.com/photo/jpeg-huffman-coding.html it was very useful until I reached this

The expectation is that image content is 3 components (Y, Cb, Cr). Within each component, the sequence is always one DC value followed by 63 AC values.

So what is the meaning of DC and AC?

Upvotes: 13

Views: 11606

Answers (1)

Mark Adler
Mark Adler

Reputation: 112617

Simply that the first element of a discrete cosine transform (DCT) is the DC or direct current term, which is the average of the pixel values. The remaining elements, the AC or alternating current terms, are independent of the average. So if you added the same number to all the pixel values, only the DC term of the DCT would change. The AC terms would be unchanged.

This is analogous to filtering out the DC component of a signal with a capacitor, allowing only the AC components through.

Upvotes: 24

Related Questions