.warp File Transformations

 

In AIR, .warp files are the nonlinear equivalents of .air files. However, the specification of .warp files differ in several ways. First of all, the transformation specified in a .warp file will convert internal voxel coordinate locations in an uninterpolated version of the standard file to the corresponding uninterpolated internal voxel coordinate locations in the reslice file. Homogenous coordinates are not used (the .warp file does include storage for possible future implementation of homogenous coordinates). All transformations are stored as fifth order polynomials, starting with the lowest order terms (the pure translations) and ending with the highest order terms (this is in contrast to.air files which the reverse priority). If the letters x, y, and z within a term are placed in reverse alphabetic order, the terms of the same order are prioritized alphabetically (e.g., for third order terms the priority is xxx yxx yyx yyy zxx zyx zyy zzx zzy zzz).

The .warp file transformation can be displayed using the program scan_warp.

For a voxel with coordinates (x,y,z) in the standard file, the corresponding coordinates (x',y',z') in the reslice file are computed in C code using the array e as:

x'=e[0][0]+e[1][0]*x+e[2][0]*y+e[3][0]*z+e[4][0]*xx +...+e[10][0]*xxx + ... + e[20][0]*xxxx+ ...+e[35][0]*xxxxx+...+e[55][0]*zzzzz

y'==e[0][1]+e[1][1]*x+e[2][1]*y+e[3][1]*z+e[4][1]*xx +...+e[10][1]*xxx + ... + e[20][1]*xxxx+ ...+e[35][1]*xxxxx+...+e[55][1]*zzzzz

z' =e[0][2]+e[1][2]*x+e[2][2]*y+e[3][2]*z+e[4][2]*xx +...+e[10][2]*xxx + ... + e[20][2]*xxxx+ ...+e[35][2]*xxxxx+...+e[55][2]*zzzzz


Modified: December 11,2001

© 1995-2001 Roger P. Woods, M.D.(rwoods@ucla.edu)