Skip to content

Commit e829959

Browse files
thisyspSimonRit
authored andcommitted
BUG: Fix CUDA/CPU inconsistency in DisplacedDetectorImageFilter
1 parent a7e0f2d commit e829959

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/rtkCudaDisplacedDetectorImageFilter.cu

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ ToUntiltedCoordinateAtIsocenter(float tiltedCoord, float sdd, float sid, float s
4141
const float cosa = sx / sidu;
4242
// the following relation refers to a note by R. Clackdoyle, title
4343
// "Samping a tilted detector"
44-
return l * sid / (sidu - l * cosa);
44+
return l * abs(sid) / (sidu - l * cosa);
4545
}
4646

4747
__global__ void

0 commit comments

Comments
 (0)