Announce

PukiWiki contents have been moved into SONOTS Plugin (20070703)

Project: Jpeg-like codec

Table of Contents

Overview

encode

  1. RGB to YCbCr
  2. downsample Cb, Cr
  3. 2-D Block DCT
  4. Quantization (Quantization Table)
  5. zigzag scan
  6. entropy coding

decode

  1. entropy decoding
  2. Inverse zigzag
  3. Inverse Quantization
  4. Inverse 2-D Block DCT
  5. upsample Cb, Cr
  6. YCbCr to RGB
First Edition: March 2007. Last Modified: March 2007
Tag: Scientific ComputerVision Compression Matlab

Fundamental Experiments

DCT basis

II1DCTBasisImage.png

2D DCT

Input

saturn.png

Output

II2dctimg.png

Block-based 2D DCT

Input

saturn.png

Output

II3blkdctimg.png

JPEG Experiments

Block-based 2D DCT

I used the built-in dctmtx.m instead of my gen_dctbasis.m and dct2.m instead of my doDct2.m, and blkproc instead of my block_dct2.m

Quantization Table

Zigzag

Huffman encoding

I did not make them.

codec (main)

Result

Input

LenaC.png

Output. Successfully decoded.

IIIJpegCodec.png