How to find quantize, flooring and mod 2 of an image
2 views (last 30 days)
Show older comments
I have decomposed/ generated the coefficient matrices of the level-one approximation (LL) and horizontal (LH), vertical (HL) and diagonal features (HH) of an image with the following code line:
figure
subplot (2,2,1);
imshow(LL,[]);
title('LL subband-Approximation');
and similarly for LH, HL, HH band.
Now my problem is:
(i) separate LL out and quantify it to [0,255]. (ii) Then implement following term:
LL'(subscript i,j)= floor[LL (subscript i,j)/2^k] mod 2
where 0<=K<=7 and subscript i,j are 128*128.
How can this be implemented in MatLab. Please provide me the code.
0 Comments
Answers (1)
Walter Roberson
on 30 May 2015
Quantize:
minLL = min(LL(:));
maxLL = max(LL(:));
halfLL = minLL + (maxLL - minLL)/2;
qLL = 255*(LL > halfLL);
0 Comments
See Also
Categories
Find more on Modify Image Colors in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!