27 mProbeMovementDefinition.mRangeNormalizedTranslation = cx::Vector3D::UnitX();
30 mProbeMovementDefinition.mRangeAngle = 0;
31 mProbeMovementDefinition.mSteps = 200;
38 mProbeMovementDefinition.mRangeNormalizedTranslation = cx::Vector3D::UnitX() * range;
42 mProbeMovementDefinition.mRangeAngle = range;
46 mProbeMovementDefinition.mSteps = steps;
62 mBounds = cx::Vector3D::Ones() * size;
64 mProbeMovementDefinition.mRangeNormalizedTranslation = cx::Vector3D::UnitX();
65 mProbeMovementDefinition.mRangeAngle = 0;
66 mProbeMovementDefinition.mSteps = size/spacing+1;
72 mPhantom->printInfo();
74 std::cout << indent <<
"ProbeMovement RangeNormalizedTranslation: " << mProbeMovementDefinition.mRangeNormalizedTranslation << std::endl;
75 std::cout << indent <<
"ProbeMovement RangeAngle: " << mProbeMovementDefinition.mRangeAngle << std::endl;
76 std::cout << indent <<
"ProbeMovement Steps: " << mProbeMovementDefinition.mSteps<< std::endl;
94 std::vector<cx::Transform3D> SyntheticReconstructInput::generateFrames_rMt_tilted()
97 cx::Vector3D range_translation = mBounds[0] * mProbeMovementDefinition.mRangeNormalizedTranslation;
98 double range_angle = mProbeMovementDefinition.mRangeAngle;
99 int steps = mProbeMovementDefinition.mSteps;
102 return this->generateFrames(p0,
105 Eigen::Vector3d::UnitY(),
113 std::vector<cx::Transform3D> SyntheticReconstructInput::generateFrames(
cx::Vector3D p0,
120 std::vector<cx::Transform3D> planes;
121 for(
int i = 0; i < steps; ++i)
124 double t = (i-R/2)/R;
126 transform.translation() = p0 + range_translation*t;
127 transform.rotate(Eigen::AngleAxisd(t*range_angle, rotation_axis));
128 planes.push_back(transform);
136 cx::Vector3D range_translation = mBounds[0] * mProbeMovementDefinition.mRangeNormalizedTranslation;
137 double range_angle = mProbeMovementDefinition.mRangeAngle;
138 int steps_full = 3*mProbeMovementDefinition.mSteps;
141 std::vector<cx::Transform3D> rMt_full;
142 rMt_full = this->generateFrames(p0,
145 Eigen::Vector3d::UnitY(),
151 for (
unsigned i=0; i<steps_full; i+=2)
155 pos.
mPos = rMt_full[i];
160 std::vector<vtkImageDataPtr> frames;
161 for (
unsigned i=0; i<steps_full; i+=3)
167 frames.push_back(mPhantom->sampleUsData(rMt_full[i], mProbe));
172 result.
rMpr = cx::Transform3D::Identity();
181 std::vector<cx::Transform3D> planes = this->generateFrames_rMt_tilted();
184 retval = mPhantom->sampleUsData(planes, mProbe, dMr);
One position with timestamp.
Transform3D Transform3D
Transform3D is a representation of an affine 3D transform.
double roundAwayFromZero(double val)
Eigen::Vector3d Vector3D
Vector3D is a representation of a point or vector in 3D.
Definition of characteristics for an Ultrasound Probe Sector.
QString streamXml2String(T &val)
boost::shared_ptr< class ProcessedUSInputData > ProcessedUSInputDataPtr
static USFrameDataPtr create(ImagePtr inputFrameData)
float4 transform(float16 matrix, float4 voxel)
void setData(ProbeDefinition data)