From: demis dem on
ImageAnalyst <imageanalyst(a)mailinator.com> wrote in message <3795ae91-1e5b-43b9-90da-3b5f91b80349(a)21g2000yqj.googlegroups.com>...
> Don:
> I didn't see that format listed on wotsit.org
> http://www.wotsit.org/list.asp?al=P
> so what is it?
> You might have to write your own file reader using fopen, fscanf, etc.

hey everybody
do anyone have a solution for this issue(which is reading .pct image and convert it to jpg or bmp) ?! plz help
Don if u figure out how to do that plz advice me
thnx in advance
BR
From: Don on

Hello

Code to open pct format is as follow:

fid=fopen('filename.pct'); %function to open file
a=fread(fid); %function to read data in binary format
b=a(297:262440,:); %stores data without a header
c=reshape(b,512,512); %forms image data into array
d=mat2gray(c); %changing matrix into intensity image
imshow(d),title('title'); %displays image

In my case I had to open pct file which consisted header followed by grey-level image of 512x512 pixels. I think that code will help. Good luck.