|
TPCCLIB
|
Functions for simulating image of vessel (tube). More...
#include "libtpcidi.h"Go to the source code of this file.
Functions | |
| int | idiSimulateTubeVol (VOL *vol, int zi, double cx, double cy, double r, double FWHM, double cbkg, double cblo) |
| int | idiSimulateTubeImg (IMG *img, int zi, double cx, double cy, double r, double *cbkg, double *cblo) |
| int | idiSimulateTubeImgPlane (int simmet, IMG *img, int zi, double cx, double cy, double r, double FWHM, double *cbkg, double *cblo) |
Functions for simulating image of vessel (tube).
Definition in file vessel.c.
| int idiSimulateTubeImg | ( | IMG * | img, |
| int | zi, | ||
| double | cx, | ||
| double | cy, | ||
| double | r, | ||
| double * | cbkg, | ||
| double * | cblo ) |
Simulate dynamic image surrounding a circular object extending across image planes (vessel).
| img | Pointer to allocated dynamic image; volume must contain pixel sizes and dimensions, and the same time frames as the TAC data. |
| zi | Plane index [0..dimz-1]. |
| cx | X distance of circle centre (mm) from the upper left corner of the image. |
| cy | Y distance of circle centre (mm) from the upper left corner of the image. |
| r | Radius of vessel (mm). |
| cbkg | Array of background activities; size must be the same as img frame number. |
| cblo | Array of vessel activities; can be higher or lower than background; size must be the same as img frame number. |
Definition at line 81 of file vessel.c.
| int idiSimulateTubeImgPlane | ( | int | simmet, |
| IMG * | img, | ||
| int | zi, | ||
| double | cx, | ||
| double | cy, | ||
| double | r, | ||
| double | FWHM, | ||
| double * | cbkg, | ||
| double * | cblo ) |
Simulate image surrounding a circular object extending across image planes (bar or vessel). This function applies currently two methods to simulate the spill-over and spill-in effects:
Method 1. is based on Germano et al. JNM 1992; 33: 613-620. This equation can not be used to estimate recovery coefficient or the true activity concentration inside the vessel, but only to fit the radius of the vessel (see Germano), which then can be used to calculate the RC.
Method 2. simulates just the vessel without PVE; add 2D Gaussian smoothing later.
To simulate the circular vessel correctly in 2D image matrix use the equations in Brix et al. Nuklearmedizin 2002;41:184-190 instead; however, that would require numerical solution to double integrals, which may be either slow or error-prone for fitting purposes.
| simmet | Simulation method: 0=Germano, -1 or 1=No PVE. |
| img | Pointer to allocated dynamic image; volume must contain pixel sizes and dimensions, and the same time frames as the TAC data. |
| zi | Plane index [0..dimz-1]. |
| cx | X distance of circle centre (mm) from the upper left corner of the image. |
| cy | Y distance of circle centre (mm) from the upper left corner of the image. |
| r | Radius of vessel (mm). |
| FWHM | FWHM (mm). |
| cbkg | Array of background activities; size must be the same as img frame number. |
| cblo | Array of vessel activities; can be higher or lower than background; size must be the same as img frame number. |
Definition at line 143 of file vessel.c.
| int idiSimulateTubeVol | ( | VOL * | vol, |
| int | zi, | ||
| double | cx, | ||
| double | cy, | ||
| double | r, | ||
| double | FWHM, | ||
| double | cbkg, | ||
| double | cblo ) |
Simulate image volume surrounding a circular object extending across image planes (bar or vessel). Based on Germano et al. JNM 1992; 33: 613-620.
This equation can not be used to estimate recovery coefficient or the true activity concentration inside the vessel, but only to fit the radius of the vessel (see Germano), which then can be used to calculate the RC.
To simulate the circular vessel correctly in 2D image matrix use the equations in Brix et al. Nuklearmedizin 2002;41:184-190 instead; however, that would require numerical solution to double integrals, which may be either slow or error-prone for fitting purposes.
In this version, the activity is calculated as an average of four samples inside the pixel.
| vol | Pointer to allocated image volume; volume must contain pixel sizes and dimensions |
| zi | Plane index [0..dimz-1]. |
| cx | X distance of circle centre (mm) from the upper left corner of the image. |
| cy | Y distance of circle centre (mm) from the upper left corner of the image. |
| r | Radius of vessel (mm). |
| FWHM | FWHM (mm). |
| cbkg | Background activity. |
| cblo | Vessel activity; can be higher or lower than background. |
Definition at line 26 of file vessel.c.