5. Intraprediction
● No reference pixel => set it to 128(average)
● Mode choosing
=> by MSE and choose the smallest
● Block prediction order
⇒ From top to bottom, left to right
● Those pixels that can not form a 4*4 block
● Get the residue and chosen mode in each
block
6. DCT & Quantization
● Take the residue and do 4*4 integer
transform
● Choose Qstep(1~16)
◦ Quantize the transformed matrix
◦ Match the number of bits
◦ Choose the Qstep that has the smallest
MSE