[Castor-users] multiSiddon - projection lines lengths not updated before accessing
Simon Laperle
Simon.Laperle at USherbrooke.ca
Wed Dec 19 22:27:11 CET 2018
While reading some code, I stumbled on a GetLength() function that wasn't returning the length of the current projectionLine...
The resulting image doesn't change much. So I can't say if it makes the image better or worse.
In detail:
Source: \src\projector\iProjectorIncrementalSiddonMulti.cc
(line:189) if (mp_Scanner->GetRdmPositionsAndOrientations( ap_ProjectionLine->GetIndex1(), ap_ProjectionLine->GetIndex2(),
ap_ProjectionLine->GetPosition1(), ap_ProjectionLine->GetPosition2(),
ap_ProjectionLine->GetOrientation1(), ap_ProjectionLine->GetOrientation2() ))
[...]
// **************************************
// STEP 1: LOR length calculation
// **************************************
(line:213) HPFLTNB length_LOR = ap_ProjectionLine->GetLength();
GetLength() does not take into account the length change caused by mp_Scanner->GetRdmPositionsAndOrientations
If it wasn't intentional, a simple solution would be to add a call to ComputeLineLength():
// **************************************
// STEP 1: LOR length calculation
// **************************************
ap_ProjectionLine->ComputeLineLength();
HPFLTNB length_LOR = ap_ProjectionLine->GetLength();
Hope that helps.
Simon Laperle
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.castor-project.org/pipermail/castor-users/attachments/20181219/b9973c84/attachment-0001.html>
More information about the Castor-users
mailing list