[fitsbits] reading a single value

Nico Vermaas vermaas.spamstop at astron.nl
Fri Jul 25 02:35:09 EDT 2003


Hi,

Would this be the right way to read a single value from a fits file? 
(I add [x:x,y:y,z:z] to the filename and then read one float).

Nico

--        
sprintf(filter,"%s[%d:%d,%d:%d,%d:%d]",this->filename,point[X],point[X],point[Y],point[Y],point[Z],point[Z]);
if (!fits_open_file(&fptr, filter, READONLY, &status)) {
   fits_read_img(fptr,TFLOAT,1,1,0,buffer,0,&status);
} // if

====================================================
Nico Vermaas
ASTRON - Westerbork Radio Observatory
The Netherlands
====================================================



More information about the fitsbits mailing list