From b3e8338a7fa4c7ed9a5954ca02fa3126aefff530 Mon Sep 17 00:00:00 2001 From: Willem Jan Palenstijn Date: Tue, 2 Dec 2014 14:20:46 +0100 Subject: Add ProjectionGeometry3D::projectPoint for par3d and cone. Par3d_vec and cone_vec to follow. --- include/astra/ProjectionGeometry3D.h | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'include/astra/ProjectionGeometry3D.h') diff --git a/include/astra/ProjectionGeometry3D.h b/include/astra/ProjectionGeometry3D.h index 20ad8f3..9e7f787 100644 --- a/include/astra/ProjectionGeometry3D.h +++ b/include/astra/ProjectionGeometry3D.h @@ -298,10 +298,23 @@ public: * * @param _iIndex the index of the detector. * @param _iAngleIndex output: index of angle - * @param _iDetectorIndex output: index of dectecor + * @param _iDetectorIndex output: index of detector */ virtual void indexToAngleDetectorIndex(int _iIndex, int& _iAngleIndex, int& _iDetectorIndex) const; + /** Project a point onto the detector. The 3D point coordinates + * are in units. The output fU,fV are the (unrounded) indices of the + * detector column and row. + * This may fall outside of the actual detector. + * + * @param fX,fY,fZ coordinates of the point to project + * @param iAngleIndex the index of the angle to use + * @param fU,fV the projected point. + */ + virtual void projectPoint(float32 fX, float32 fY, float32 fZ, + int iAngleIndex, + float32 &fU, float32 &fV) const = 0; + /** Returns true if the type of geometry defined in this class is the one specified in _sType. * * @param _sType geometry type to compare to. -- cgit v1.2.3