#include <src/PlusUsSimulator/PlusSpatialModel.h>
|
void | CalculateIntensity (std::vector< double > &reflectedIntensity, unsigned int numberOfFilledPixels, double distanceBetweenScanlineSamplePointsMm, double previousModelAcousticImpedanceMegarayls, double incidentIntensity, double &transmittedIntensity, double incidenceAngleRad) |
|
double | GetAcousticImpedanceMegarayls () |
|
void | GetLineIntersections (std::deque< LineIntersectionInfo > &lineIntersections, double *scanLineStartPoint_Reference, double *scanLineEndPoint_Reference) |
|
vtkMatrix4x4 * | GetModelToObjectTransform () |
|
| GetStdStringMacro (Name) |
|
| GetStdStringMacro (ObjectCoordinateFrame) |
|
void | operator= (const PlusSpatialModel &model) |
|
| PlusSpatialModel () |
|
| PlusSpatialModel (const PlusSpatialModel &model) |
|
virtual PlusStatus | ReadConfiguration (vtkXMLDataElement *spatialModelElement) |
|
| SetMacro (ImagingFrequencyMhz, double) |
|
| SetMacro (DensityKgPerM3, double) |
|
| SetMacro (SoundVelocityMPerSec, double) |
|
| SetMacro (AttenuationCoefficientDbPerCmMhz, double) |
|
| SetMacro (SurfaceReflectionIntensityDecayDbPerMm, double) |
|
| SetMacro (BackscatterDiffuseReflectionCoefficient, double) |
|
| SetMacro (SurfaceDiffuseReflectionCoefficient, double) |
|
| SetMacro (SurfaceSpecularReflectionCoefficient, double) |
|
| SetMacro (TransducerSpatialModelMaxOverlapMm, double) |
|
void | SetModelFile (const std::string &modelFile) |
|
void | SetReferenceToObjectTransform (vtkMatrix4x4 *referenceToObjectTransform) |
|
| SetStdStringMacro (Name) |
|
| SetStdStringMacro (ObjectCoordinateFrame) |
|
virtual | ~PlusSpatialModel () |
|
Definition at line 23 of file PlusSpatialModel.h.
◆ PlusSpatialModel() [1/2]
PlusSpatialModel::PlusSpatialModel |
( |
| ) |
|
◆ ~PlusSpatialModel()
PlusSpatialModel::~PlusSpatialModel |
( |
| ) |
|
|
virtual |
◆ PlusSpatialModel() [2/2]
◆ CalculateIntensity()
void PlusSpatialModel::CalculateIntensity |
( |
std::vector< double > & |
reflectedIntensity, |
|
|
unsigned int |
numberOfFilledPixels, |
|
|
double |
distanceBetweenScanlineSamplePointsMm, |
|
|
double |
previousModelAcousticImpedanceMegarayls, |
|
|
double |
incidentIntensity, |
|
|
double & |
transmittedIntensity, |
|
|
double |
incidenceAngleRad |
|
) |
| |
Computes relative intensities inside the model
- Parameters
-
incidentIntensity | Dimensionless value, if there is 100% reflection at the surface then this fraction of the beam intensity would be sensed at the transducer. It includes the effect of attenuation of both incoming and reflected direction. |
transmittedIntensity | intensity when the beam leaves the model |
Definition at line 211 of file PlusSpatialModel.cxx.
◆ GetAcousticImpedanceMegarayls()
double PlusSpatialModel::GetAcousticImpedanceMegarayls |
( |
| ) |
|
◆ GetLineIntersections()
void PlusSpatialModel::GetLineIntersections |
( |
std::deque< LineIntersectionInfo > & |
lineIntersections, |
|
|
double * |
scanLineStartPoint_Reference, |
|
|
double * |
scanLineEndPoint_Reference |
|
) |
| |
Get all the intersection points of the model and a line. Input and output points are all in Model coordinate system. The results are appended to the lineIntersections structure. If the line starts inside the model then the first intersection position is 0. The unit of the reference coordinate system must be in mm.
Definition at line 317 of file PlusSpatialModel.cxx.
◆ GetModelToObjectTransform()
vtkMatrix4x4* PlusSpatialModel::GetModelToObjectTransform |
( |
| ) |
|
◆ GetStdStringMacro() [1/2]
PlusSpatialModel::GetStdStringMacro |
( |
Name |
| ) |
|
◆ GetStdStringMacro() [2/2]
◆ operator=()
◆ ReadConfiguration()
PlusStatus PlusSpatialModel::ReadConfiguration |
( |
vtkXMLDataElement * |
spatialModelElement | ) |
|
|
virtual |
◆ SetMacro() [1/9]
Set US imaging frequency for generated image
◆ SetMacro() [2/9]
◆ SetMacro() [3/9]
◆ SetMacro() [4/9]
◆ SetMacro() [5/9]
◆ SetMacro() [6/9]
◆ SetMacro() [7/9]
◆ SetMacro() [8/9]
◆ SetMacro() [9/9]
◆ SetModelFile()
void PlusSpatialModel::SetModelFile |
( |
const std::string & |
modelFile | ) |
|
Set the surface model file name (STL or VTP). It can be used to override the model file name specified in the XML configuration.
Definition at line 524 of file PlusSpatialModel.cxx.
◆ SetModelLocalizer()
void PlusSpatialModel::SetModelLocalizer |
( |
vtkModifiedBSPTree * |
modelLocalizer | ) |
|
|
protected |
◆ SetModelToObjectTransform() [1/2]
void PlusSpatialModel::SetModelToObjectTransform |
( |
vtkMatrix4x4 * |
modelToObjectTransform | ) |
|
|
protected |
◆ SetModelToObjectTransform() [2/2]
void PlusSpatialModel::SetModelToObjectTransform |
( |
double * |
matrixElements | ) |
|
|
protected |
◆ SetPolyData()
void PlusSpatialModel::SetPolyData |
( |
vtkPolyData * |
polyData | ) |
|
|
protected |
◆ SetReferenceToObjectTransform()
void PlusSpatialModel::SetReferenceToObjectTransform |
( |
vtkMatrix4x4 * |
referenceToObjectTransform | ) |
|
◆ SetStdStringMacro() [1/2]
PlusSpatialModel::SetStdStringMacro |
( |
Name |
| ) |
|
◆ SetStdStringMacro() [2/2]
◆ UpdateModelFile()
◆ UpdatePrecomputedAttenuations()
void PlusSpatialModel::UpdatePrecomputedAttenuations |
( |
double |
intensityTransmittedFractionPerPixelTwoWay, |
|
|
int |
numberOfElements |
|
) |
| |
|
protected |
◆ AttenuationCoefficientDbPerCmMhz
double PlusSpatialModel::AttenuationCoefficientDbPerCmMhz |
|
protected |
Attenuation coefficient of the model material (dB / cm / MHz). Includes both absorption and scattering. Positive number.
Definition at line 144 of file PlusSpatialModel.h.
◆ BackscatterDiffuseReflectionCoefficient
double PlusSpatialModel::BackscatterDiffuseReflectionCoefficient |
|
protected |
The fraction of the attenuated intensity that is reflected (backscattered) to all directions. Rough surfaces have higher values (range: 0.0-1.0). Usually not just scattering occurs (there are various ways of scattering) but also absorption, so the value is much less than 1.0.
Definition at line 158 of file PlusSpatialModel.h.
◆ DensityKgPerM3
double PlusSpatialModel::DensityKgPerM3 |
|
protected |
Density in kg/m^3 of the material the model is comprised of
Definition at line 138 of file PlusSpatialModel.h.
◆ ImagingFrequencyMhz
double PlusSpatialModel::ImagingFrequencyMhz |
|
protected |
◆ ModelFile
std::string PlusSpatialModel::ModelFile |
|
protected |
Name of the STL or VTP model file. If no ModelFile is defined then it means that the model is everywhere (background material).
Definition at line 111 of file PlusSpatialModel.h.
◆ ModelFileNeedsUpdate
bool PlusSpatialModel::ModelFileNeedsUpdate |
|
protected |
It is true if the model file needs to be updated (re-read from the ModelFile)
Definition at line 114 of file PlusSpatialModel.h.
◆ ModelLocalizer
vtkModifiedBSPTree* PlusSpatialModel::ModelLocalizer |
|
protected |
◆ ModelToObjectTransform
vtkMatrix4x4* PlusSpatialModel::ModelToObjectTransform |
|
protected |
Transformation matrix from the native coordinate system (as points are stored in the file) to spatial object coordinate system (ObjectCoordinateFrame)
Definition at line 120 of file PlusSpatialModel.h.
◆ Name
std::string PlusSpatialModel::Name |
|
protected |
◆ ObjectCoordinateFrame
std::string PlusSpatialModel::ObjectCoordinateFrame |
|
protected |
This variable defines the name of the spatial object's coordinate frame
Definition at line 130 of file PlusSpatialModel.h.
◆ PolyData
vtkPolyData* PlusSpatialModel::PolyData |
|
protected |
Surface mesh. Points are stored in the Model coordinate system (as in the input file)
Definition at line 190 of file PlusSpatialModel.h.
◆ PrecomputedAttenuations
std::vector<double> PlusSpatialModel::PrecomputedAttenuations |
|
protected |
List of attenuations: intensityTransmittedFractionPerPixelTwoWay, intensityTransmittedFractionPerPixelTwoWay^2, intensityTransmittedFractionPerPixelTwoWay^3, ...
Definition at line 193 of file PlusSpatialModel.h.
◆ ReferenceToObjectTransform
vtkMatrix4x4* PlusSpatialModel::ReferenceToObjectTransform |
|
protected |
Transformation matrix from the reference coordinate system (that is used by external methods) to the object coordinate system (ObjectCoordinateFrame). This transform is not serialized to/from the XML configuration.
Definition at line 127 of file PlusSpatialModel.h.
◆ SoundVelocityMPerSec
double PlusSpatialModel::SoundVelocityMPerSec |
|
protected |
◆ SurfaceDiffuseReflectionCoefficient
double PlusSpatialModel::SurfaceDiffuseReflectionCoefficient |
|
protected |
The fraction of the attenuated intensity that is reflected (backscattered) in an incidence-angle indepentent way.
Definition at line 185 of file PlusSpatialModel.h.
◆ SurfaceReflectionIntensityDecayDbPerMm
double PlusSpatialModel::SurfaceReflectionIntensityDecayDbPerMm |
|
protected |
Attenuation coefficient of the surface reflection (dB / mm). Positive number. We model the reflection from the surface as intensity reflected from a small region with an exponential decay. The decay coefficient refers to the dispersion of the signal in the material and the signal processing electronics.
Definition at line 151 of file PlusSpatialModel.h.
◆ SurfaceSpecularReflectionCoefficient
double PlusSpatialModel::SurfaceSpecularReflectionCoefficient |
|
protected |
The fraction of the attenuated intensity that is reflected (backscattered) in a mirror-like way. Smooth, polished surfaces have higher values (range: 0.0-1.0). A value of one means all the attenuation is caused by a perfect reflection. Usually not just scattering occurs (there are various ways of scattering) but also absorption, so the value is much less than 1.0.
Definition at line 180 of file PlusSpatialModel.h.
◆ TransducerSpatialModelMaxOverlapMm
double PlusSpatialModel::TransducerSpatialModelMaxOverlapMm |
|
protected |
TransducerSpatialModelMaxOverlapMm determines how far from the transducer surface (inside the transducer) we start searching for scanline/SpatialModel intersections. If the value is too small then inside/outside segments may be inverted for the overlapping model. If the value is too large then it may slightly slow down the simulation. When it is decided if a certain part of a scanline is inside or outside of a model it is assumed that after 1 (or 3, 5, 7, ...) intersections we are inside the model and after 2 (or 4, 6, 8, ...) intersections we are outside the model. This is only true if the scanline start point is outside every spatial model. This is always true in theory, but in practice, due to slight registration errors or deformations the transducer surface may get inside a spatial model by a few mm. To avoid inversion of inside/outside, we start the scanline a few mm away from the true transducer surface so that we can detect intersections that are very close to the transducer surface.
Definition at line 172 of file PlusSpatialModel.h.
The documentation for this class was generated from the following files: