-1

I'm trying to open this fixed.raw file (can be found here: http://elastix.isi.uu.nl/download/elastix_example_v4.8.zip) on Matlab.

I tried:

row=256;  col=256;
fin=fopen('fixed.raw','r');
I=fread(fin, [col row],'uint8=>uint8'); 
Z=I';
k=imshow(Z)

An image appears, but it isn't properly aligned. Any help is appreciated!

phalanx
  • 1
  • 3

1 Answers1

0

Seems like your image is bigger than you expected. Try running :

row=256;  col=512;
fin=fopen('fixed.raw','r');
I=fread(fin, [col row],'uint8=>uint8'); 
Z=I';
k=imshow(Z)
BillBokeey
  • 3,168
  • 14
  • 28