ncigt-fil
Functions
GradWarp Functions

Functions

void gwarp_apply2 (float W[], float hpp[], float vpp[], float *hpixs, float *vpixs, int N_h, int N_v, float mag[])
 
void gwarp_calc (float *tl, float *tr, float *br, float *bl, int N_h, int N_v, float hpixs[], float vpixs[], float *d, float *u, float W[], float hpp[], float vpp[], char *fname)
 
void gwarp_prep (float tl[], float tr[], float br[], float bl[], int N_h, int N_v, float hpixs[], float vpixs[], float d[], float u[])
 
int gwarp_read_parms (char *fname, GWARP_PARMS *gwp)
 

Detailed Description

Function Documentation

void gwarp_apply2 ( float  W[],
float  hpp[],
float  vpp[],
float *  hpixs,
float *  vpixs,
int  N_h,
int  N_v,
float  mag[] 
)
Parameters
Wthe weighting factor
hppunwarped location in the horizontal direction
vppunwarped location in the vertical direction
hpixslocations along the horizontal axis where pixels are found
vpixslocations along the vertical axis where pixels are found
N_hNumber of pixels in horizontal direction
N_vnumber of pixels in vertical direction
magimage data
void gwarp_calc ( float *  tl,
float *  tr,
float *  br,
float *  bl,
int  N_h,
int  N_v,
float  hpixs[],
float  vpixs[],
float *  d,
float *  u,
float  W[],
float  hpp[],
float  vpp[],
char *  fname 
)

outputs: W, hpp, vpp

Parameters
tl(unused) top left coordinate (x,y,z), in cm
tr(unused) top right coordinate (x,y,z), in cm
br(unused) bottom right coordinate (x,y,z), in cm
blbottom left coordinate (x,y,z), in cm
N_hNumber of horizontal
N_vnumber of vertical
hpixshorizontal pixels (length = N_out)
vpixsvertical pixels (length = N_out)
dscale factors (length = 2)
uunit vector directions (length = 6)
Wthe weighting factor (length = N_h*N_v)
hppunwarped location in the horizontal direction (length = N_h*N_v)
vppunwarped location in the vertical direction (length = N_h*N_v)
fnameinput filename for the gradwarp spherical harmonic correction coefficients. Set to NULL if unavailable.
void gwarp_prep ( float  tl[],
float  tr[],
float  br[],
float  bl[],
int  N_h,
int  N_v,
float  hpixs[],
float  vpixs[],
float  d[],
float  u[] 
)

compute the 'd' and 'u' vectors, based on the size of the FOV and the number of pixels along each image dimension.

Parameters
tltop left coordinate (x,y,z), in cm
trtop right coordinate (x,y,z), in cm
brbottom left coordinate (x,y,z), in cm
blbottom right coordinate (x,y,z), in cm
N_hNumber of h
N_vNumber of v
hpixslocations along the horizontal axis where pixels are found
vpixslocations along the vertical axis where pixels are found
int gwarp_read_parms ( char *  fname,
GWARP_PARMS *  gwp 
)

Function to parse the GE gradwarp spherical harmonic correction file.

Parameters
fnameinput filename
gwpthe destination, structure of gradwarp parameters