From: astro mmi on
Hi everyone,
Here, I have performed the transformation of a given image using the tranformation shown below.
The norma image
s=(-0.0107)+(0.0107)*exp(4.5510*double(norma));
figure,imshow(s)
title('tranformed image')
The operation on any image results in an binary image. I want to know if it is right or there is some way where I can still get thegray scale enhanced output. s=output and norma=normalised input image.Pls help.Thanx in advance
From: Jomar Bueyes on
On Feb 22, 3:37 pm, "astro mmi" <pyarsa_ma...(a)yahoo.co.in> wrote:
> Hi everyone,
>   Here, I have performed the transformation of a given image using the tranformation shown below.
>  The norma image
> s=(-0.0107)+(0.0107)*exp(4.5510*double(norma));
> figure,imshow(s)
> title('tranformed image')
>  The operation on any image results in an binary image. I want to know if it is right or there is some way where I can still get thegray scale enhanced output. s=output and norma=normalised input image.Pls help.Thanx in advance

After doing the transformation, rescale the gray scale to the number
of gray levels you are using for display or to the range [0,1]. The
former approach requires you to set the color map. The two approaches
are
1) Assuming 64 gray levels
imshow(63*s/max(s(:)) + 1); colormap(gray(64));
2)
imshow(s/max(s(:)) % colormap not needed

HTH

Jomar
From: ImageAnalyst on
Use imshow(s, []); instead. Or use imagesc().