how to display the output?
    1 visualización (últimos 30 días)
  
       Mostrar comentarios más antiguos
    
Hai, As a part of my project i want to calculate the dct of given image and compute the inverse dct to get back the original image. And the invrese transformed image undergo some attacks like awgn and the histogram equalization etc. But i couldn't display the output properly getting a white image in the figure...how can I get the original image in figure.code is below.
I=imread('pout.tif');
k=dct2(I);
L=idct2(k);
attack=histeq(L);
figure;imshow(attack)
channel=awgn(L,40);
figure;imshow(channel);
0 comentarios
Respuestas (2)
  Guillaume
      
      
 el 5 de Dic. de 2014
        What is the type of your image? And what is the range of intensities in that image.
Possibly your image is of type double while the intensities are in the range 0-255. In which case if you call imshow with just the image you'll get a mostly white image as imshow assumes an intensity range of 0-1 for double images.
If that is the case, either pass the intensity range to imshow (or [] to use min-max of your image), or divide your image by the max intensity:
imshow(attack, []);  %or
imshow(attack/255);
Ver también
Categorías
				Más información sobre Histograms en Help Center y File Exchange.
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!