Matlab Imread resizes tif file -


so i'm using imread function in matlab , when save tiff file , open in photoshop, has white border , can't understand why. want maintain resolution 512 512 image. ideas why? , how can fix that?

here's sample code:

b = imread('w_noise1.tif');  n = 1:5,     b = medfilt2(b); end  b = filter2(fspecial('average',3),b)/255;  imshow(b) 

are sure it's issue imread? i'd surprised if is.

see this link medfilt2 explains "medfilt2 pads image 0s on edges, median values points within [m n]/2 of edges might appear distorted."

edit: tried replicate problem. issue print puts white frame around image after save it. functionality, print made printing plots. if want save image, should use imwrite.


Comments

Popular posts from this blog

objective c - Change font of selected text in UITextView -

php - Accessing POST data in Facebook cavas app -

c# - Getting control value when switching a view as part of a multiview -