|
Bsoft
1.9
Bernard's software package
|
Library routines used for editing image contents. More...
#include "img_edit.h"#include "Complex.h"#include "Matrix.h"#include "matrix_linear.h"#include "utilities.h"Go to the source code of this file.
Functions | |
| int | img_delete_range (Bimage *p, double min, double max, double fill, int fill_type) |
| Replaces values in a given range with the fill value. More... | |
| int | img_gradient_correction (Bimage *p) |
| Calculates and corrects for a linear gradient across an image. More... | |
| int | img_extract_tetrahedron (Bimage *p, Vector3< float > *tet, double fill, int fill_type) |
| Extracts a tetrahedral part of the image. More... | |
Variables | |
| int | verbose |
Library routines used for editing image contents.
Definition in file img_edit.cpp.
| int img_delete_range | ( | Bimage * | p, |
| double | min, | ||
| double | max, | ||
| double | fill, | ||
| int | fill_type | ||
| ) |
Replaces values in a given range with the fill value.
| *p | image. |
| min | minimum of range. |
| max | maximum of range. |
| fill | fill value. |
| fill_type | FILL_AVERAGE, FILL_BACKGROUND, FILL_USER. |
All voxels within a given range are set to a given fill value. The new data replaces the old data.
Definition at line 31 of file img_edit.cpp.
Extracts a tetrahedral part of the image.
| *p | image. |
| *tet | four 3-value vectors defining the tetrahedron. |
| fill | fill value. |
| fill_type | FILL_AVERAGE, FILL_BACKGROUND, FILL_USER. |
All voxels outside a tetrahedron defined by four points or vectors are set to a given fill value. The new data replaces the old data.
Definition at line 151 of file img_edit.cpp.
| int img_gradient_correction | ( | Bimage * | p | ) |
Calculates and corrects for a linear gradient across an image.
| *p | the image. |
The linear gradient across an image is calculated as:
density(x,y,z) = b0 + b1*x + b2*y + b3*z
The image is converted to floating point and corrected for the gradient. Definition at line 69 of file img_edit.cpp.
| int verbose |