MASKS Monash Image Library MASKS
The image library supports another structure called I_MASK:
typedef struct IMASK_T
{
long row;
long col;
union
{
char chr;
short sht;
long lng;
double dbl;
} value;
}
IMASK;
This structure allows the image library to work with sparse structures
instead of matrices. However there is little support for this structure at
present.
Note: istructelem does not use this structure, although it is still
supported for compatibility reasons.
| igetmaskany | returns the value (double) at the position in a mask |
| igetmaskbpp | returns the bits per pixel of the value in the IMASK structure. |
| igetmaskchar | returns the value (as a char) at the current position in the mask. |
| igetmaskcol | returns the offset column at the current position in the mask. |
| igetmaskdouble | returns the value (as a double) at the current position in the mask. |
| igetmasklength | returns the number of elements in the mask. |
| igetmasklong | returns the value (as a long) at the current position in the mask. |
| igetmaskpix | returns the value (int) at the position in a mask |
| igetmaskpos | returns the current position in the mask [0..nelems-1]. |
| igetmaskptr | returns a pointer to the current IMASK structure. |
| igetmaskrow | returns the offset row at the current position in the mask. |
| igetmaskshort | returns the value (as a short) at the current position in the mask. |
| iimtomask | converts an image (array) into a mask (sparse). orig_row and orig_col indicate the origin's position. |
| imasknext | increments pointer and counter to next element in mask. Returns 0 if at the end of the mask |
| imaskprev | decrements pointer and counter to prev element in mask. Returns 0 if at the start of the mask |
| imaskref | sets position and pointer to the position p. Returns 0 if it fails. |
| imaskstart | adjusts pointer and counter to start of mask |
| imasktoim | converts a mask (sparse) into an image (array). |
| imkmask | create a new mask |
| iputmaskany | places row and col offsets, and the value at the current position. |
| iputmaskchar | sets the row and col offsets, and the char value at the current position. |
| iputmaskdouble | sets the row and col offsets, and the double value at the current position. |
| iputmasklong | sets the row and col offsets, and the long value at the current position. |
| iputmaskpix | places row and col offsets, and the value at the current position. |
| iputmaskshort | sets the row and col offsets, and the short value at the current position. |
| istrtomask | converts the string elem into a sparse mask space or _ indicates new row. 0 and 1 indicate values in the mask. i indicates active origin, o for a non-active origin. |
| istructelem | returns number of offsets and adjusts the offsets array for the element string. The offset array represents the rows and columns of the template. For example "010 1o1 010" is a 3x3 template with the origin at 'o' |
index | userguide | full | arithmetic | basic | binary | blocks | colour | compress | display | docs | fft | hist | image | io | makefile | masks | memory | misc | morph | pixel | rgb | stats | transform | error | mapping