|
TPCCLIB
|
Header file for libtpcroi. More...
#include "tpcclibConfig.h"#include <stdio.h>#include <stdlib.h>#include <string.h>#include <math.h>#include <float.h>#include <ctype.h>#include <time.h>#include "libtpcmisc.h"#include "libtpcimgio.h"Go to the source code of this file.
Data Structures | |
| struct | ROI |
| struct | RoiList |
| struct | ROI_list |
Macros | |
| #define | BACKUP_EXTENSION ".bak" |
| #define | ROI_RECTANGULAR 0 |
| #define | ROI_CIRCULAR 1 |
| #define | ROI_ELLIPSE 2 |
| #define | ROI_TRACE 3 |
| #define | roiEmpty roi_empty |
| #define | roiInit roi_init |
| #define | roiPrint roi_print |
Functions | |
| void | roi_init (ROI_list *rl) |
| void | roi_empty (ROI_list *rl) |
| void | roi_delete (ROI_list *rl, ROI *roi) |
| void | roi_delete_n (ROI_list *rl, int index) |
| int | roi_read (const char *fname, ROI_list *rl) |
| int | roi_save (const char *fname, ROI_list *rl) |
| int | roi_append (FILE *fp, ROI *roi) |
| int | roi_append_n (FILE *fp, ROI_list *rl, int ind) |
| int | roi_onoff (ROI *roi, int dimx, int dimy, char **m) |
| int | roi_compute_rect (ROI *roi) |
| int | roi_compute_circle (ROI *roi) |
| int | roi_compute_ellipse (ROI *roi) |
| void | roi_print (ROI *roi) |
| int | jsqrt (int n) |
| int | roi_mplane (int matnum) |
| int | roi_mframe (int matnum) |
| void | roiDel (ROI_list *rl, int ind) |
| int | roiComputeRect (ROI *roi) |
| int | roiComputeCirc (ROI *roi) |
| int | roiComputeElli (ROI *roi) |
| int | roiRead (const char *fname, ROI_list *rl) |
| int | roiFillGaps (int *x, int *y, int nr, int **ffx, int **ffy) |
| int | roiOnOff (ROI *roi, int dimx, int dimy, char **m) |
| void | roiOnOffPrint (int dimx, int dimy, char **m) |
| int | roiSave (const char *fname, ROI_list *rl) |
| int | roiAppend (char *fname, ROI_list *rl, int ind) |
Variables | |
| char | roierrmsg [128] |
Header file for libtpcroi.
Definition in file libtpcroi.h.
| #define BACKUP_EXTENSION ".bak" |
Backup file extension
Definition at line 27 of file libtpcroi.h.
| #define ROI_CIRCULAR 1 |
Definition for ROI types
Definition at line 36 of file libtpcroi.h.
Referenced by roi_onoff(), and roiRead().
| #define ROI_ELLIPSE 2 |
Definition for ROI types
Definition at line 38 of file libtpcroi.h.
Referenced by roi_onoff(), and roiRead().
| #define ROI_RECTANGULAR 0 |
Definition for ROI types
Definition at line 34 of file libtpcroi.h.
Referenced by roi_onoff(), and roiRead().
| #define ROI_TRACE 3 |
Definition for ROI types
Definition at line 40 of file libtpcroi.h.
Referenced by roi_append(), roi_onoff(), roi_read(), roiAppend(), roiRead(), and roiSave().
| #define roiEmpty roi_empty |
Deprecated function name
Definition at line 151 of file libtpcroi.h.
| #define roiInit roi_init |
Deprecated function name
Definition at line 153 of file libtpcroi.h.
| #define roiPrint roi_print |
Deprecated function name
Definition at line 155 of file libtpcroi.h.
|
extern |
Calculate integer square root.
| n | Integer |
Definition at line 617 of file ecat_roi.c.
Referenced by roiComputeElli().
|
extern |
Append ROIs into given file.
Definition at line 564 of file ecat_roi.c.
Referenced by roi_append_n(), and roi_save().
|
extern |
Append given ROI into file.
Definition at line 595 of file ecat_roi.c.
|
extern |
|
extern |
Compute ellipse ROI.
| roi | ROI |
Definition at line 311 of file ecat_roi.c.
|
extern |
Compute rectangular ROI.
| roi | ROI |
Definition at line 244 of file ecat_roi.c.
|
extern |
|
extern |
|
extern |
Before any use, this should be called, but not later.
| rl | ROI list |
Definition at line 49 of file ecat_roi.c.
|
extern |
| matnum | Matnum |
Definition at line 649 of file ecat_roi.c.
Referenced by roi_print().
|
extern |
| matnum | Matnum |
Definition at line 636 of file ecat_roi.c.
Referenced by roi_print().
|
extern |
The matrix is filled with 0's (outside of ROI) and 1's (inside the ROI border).
If ROI extends outside image borders, those points are ignored. Matrix coordinates are up-to-bottom and left-to-right.
| roi | Definitions for one region-of-interest |
| dimx | Image matrix x dimension when ROI was drawn (1, 2, 3, or 4 times magnified). |
| dimy | Image matrix y dimension when ROI was drawn. |
| m | Allocated memory for output matrix[dimx][dimy] |
Definition at line 451 of file ecat_roi.c.
|
extern |
Prints the contents of (individual) roi data structure.
| roi | ROI |
Definition at line 333 of file ecat_roi.c.
|
extern |
Adds ROI file contents (all ROIs) to specified data structure.
| fname | Filename |
| rl | ROI list |
Definition at line 114 of file ecat_roi.c.
|
extern |
Save ROI list in file.
| fname | File name |
| rl | ROI list |
Definition at line 530 of file ecat_roi.c.
|
extern |
Append ROIs in given file to given ROI list.
| fname | File name |
| rl | Roilist |
| ind | Index |
Definition at line 554 of file ecat_roi_old.c.
|
extern |
Compute circular ROI.
| roi | ROI |
Definition at line 199 of file ecat_roi_old.c.
Referenced by roiRead().
|
extern |
Compute ellipse ROI.
| roi | ROI |
Definition at line 251 of file ecat_roi_old.c.
Referenced by roiRead().
|
extern |
|
extern |
If ind=0, all ROIs in list are deleted keeping memory allocated, else only one ROI is deleted (ind=1, first ROI) keeping memory allocated.
Definition at line 13 of file ecat_roi_old.c.
|
extern |
Fills the gaps between ROI points; join them with new points.
Allocates memory for new point data in fx and fy.
| x | ROI line x positions |
| y | ROI line y positions |
| nr | Nr of ROI line points |
| ffx | Pointer to new data points |
| ffy | Pointer to new data points |
Definition at line 307 of file ecat_roi_old.c.
Referenced by roiOnOff().
|
extern |
The matrix is filled with 0's (outside of ROI), 1's (on the ROI border), and 2's (inside the ROI border).
If ROI extends outside image borders, those points are ignored. Matrix coordinates are up-to-bottom and left-to-right.
| roi | Definitions for one region-of-interest |
| dimx | Image matrix x dimension |
| dimy | Image matrix y dimension |
| m | Allocated memory for output matrix[dimx][dimy] |
Definition at line 404 of file ecat_roi_old.c.
|
extern |
Print ROI on-off matrix.
| dimx | On-off matrix x dimension. |
| dimy | On-off matrix y dimension. |
| m | Pointer to on-off matrix[dimx][dimy]. |
Definition at line 483 of file ecat_roi_old.c.
|
extern |
Adds ROI file contents (all ROIs) to specified data structure.
| fname | File name |
| rl | ROI list |
Definition at line 48 of file ecat_roi_old.c.
|
extern |
Save ROI list in file.
| fname | File name |
| rl | ROI list |
Definition at line 504 of file ecat_roi_old.c.
|
extern |
The ROI library error message
Definition at line 11 of file ecat_roi.c.
Referenced by roi_append(), roi_onoff(), roi_read(), roi_save(), roiAppend(), roiOnOff(), roiRead(), and roiSave().