summaryrefslogtreecommitdiffstats
path: root/tests/test_ParallelBeamLinearKernelProjector2D.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_ParallelBeamLinearKernelProjector2D.cpp')
-rw-r--r--tests/test_ParallelBeamLinearKernelProjector2D.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/test_ParallelBeamLinearKernelProjector2D.cpp b/tests/test_ParallelBeamLinearKernelProjector2D.cpp
index a34c82c..c62f670 100644
--- a/tests/test_ParallelBeamLinearKernelProjector2D.cpp
+++ b/tests/test_ParallelBeamLinearKernelProjector2D.cpp
@@ -85,10 +85,10 @@ float32 compute_linear_kernel(const astra::CProjectionGeometry2D& projgeom, cons
if (fabs(cos(fAngle)) > fabs(sin(fAngle))) {
fDetStep = volgeom.getPixelLengthY() * fabs(cos(fAngle));
- fWeight = volgeom.getPixelLengthX() * 1.0f / fabs(cos(fAngle));
+ fWeight = projgeom.getDetectorWidth() * volgeom.getPixelLengthX() * 1.0f / fabs(cos(fAngle));
} else {
fDetStep = volgeom.getPixelLengthX() * fabs(sin(fAngle));
- fWeight = volgeom.getPixelLengthY() * 1.0f / fabs(sin(fAngle));
+ fWeight = projgeom.getDetectorWidth() * volgeom.getPixelLengthY() * 1.0f / fabs(sin(fAngle));
}
// printf("step: %f\n weight: %f\n", fDetStep, fWeight);