Functions | |
void | VolumeCentroid (Volume v, double mean[3]) |
Compute center of gravity of a volume. | |
double | VolumeMoment (Volume v, double mean[3], int m0, int m1, int m2) |
Compute central moments of a volume. | |
void | VBinCentroid (VImage src, double mean[3]) |
Compute central moments of a binary raster image. | |
double | VBinMoment (VImage src, double mean[3], int m0, int m1, int m2) |
Compute central moments of a binary raster image. | |
long | VolumeSize (Volume v) |
compute volume size, output the number of voxels of a single volume | |
long | VBinSize (VImage src) |
count number of foreground voxels. | |
float | VolumeDir (Volume vol, float *e, float x[3]) |
computer principal direction of a volume from its interia matrix | |
void | VolumeEigen (Volume vol, gsl_vector *eval, gsl_matrix *evec) |
computer principal directions of a volume from its interia matrix |
The following functions compute several shape features, including central moments, center of gravity, and volume size.
void VolumeCentroid | ( | Volume | v, | |
double | mean[3] | |||
) |
Compute center of gravity of a volume.
v | input volume. | |
*mean | output array. The center of gravity is returned in mean[0],mean[1],mean[2]. Sufficient memory must have been allocated for <mean> prior to the call. |
double VolumeMoment | ( | Volume | v, | |
double | mean[3], | |||
int | m0, | |||
int | m1, | |||
int | m2 | |||
) |
Compute central moments of a volume.
v | input volume | |
*mean | input array containing the center of gravity as mean[0],mean[1],mean[2] (slice,row,column). If mean is NULL, the center of gravity is taken to be (0,0,0). | |
m0 | first index of moment | |
m1 | second index of moment | |
m2 | third index of moment |
void VBinCentroid | ( | VImage | src, | |
double | mean[3] | |||
) |
Compute central moments of a binary raster image.
src | input image (bit repn) | |
*mean | output array. The center of gravity is returned in mean[0],mean[1],mean[2]. Sufficient memory must have been allocated for <mean> prior to the call. |
double VBinMoment | ( | VImage | src, | |
double | mean[3], | |||
int | m0, | |||
int | m1, | |||
int | m2 | |||
) |
Compute central moments of a binary raster image.
src | input image (bit repn) | |
*mean | input array containing the center of gravity as mean[0],mean[1],mean[2] (slice,row,column). If mean is NULL, the center of gravity is taken to be (0,0,0); | |
m0 | first index of moment | |
m1 | second index of moment | |
m2 | third index of moment |
long VolumeSize | ( | Volume | v | ) |
compute volume size, output the number of voxels of a single volume
v | a single volume |
long VBinSize | ( | VImage | src | ) |
count number of foreground voxels.
src | input image (bit repn) |
float VolumeDir | ( | Volume | vol, | |
float * | e, | |||
float | x[3] | |||
) |
computer principal direction of a volume from its interia matrix
vol | input volume | |
e | output largest eigenvalue | |
x | output first eigenvector |
void VolumeEigen | ( | Volume | vol, | |
gsl_vector * | eval, | |||
gsl_matrix * | evec | |||
) |
computer principal directions of a volume from its interia matrix
vol | input volume | |
eval | output eigenvalues | |
evec | output matrix of eigenvectors (columns) |