Info

This question is closed. Reopen it to edit or answer.

In my problem, i have taken rgb image of size 512*512,then converted it to greyscale and applied dct2 on it.now i want to do huffman coding of this.Plz tell me how to do this and also tell me if i am wrong.

1 view (last 30 days)
I=imread('lena.jpg'); % Reads the image whose name is lena & format is jpg.
whos %
save I
load I
T1=I;
figure;imshow(I);
title('coloured image of lena')
T1=im2double(T1);
G=rgb2gray(T1);
whos
imshow(G);
imagesc(G);title('grayscale image of lena')
T2=G;
Z=dct2(T2);
figure;imshow(Z);
title('dct transformed')
  1 Comment
Walter Roberson
Walter Roberson on 27 Nov 2013
dct is for lossy encoding, not lossless encoding.
dct and huffman is very likely "modified huffman encoding" rather than pure huffman encoding. You need to research the algorithm.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!