summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWillem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl>2016-11-28 17:05:09 +0100
committerWillem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl>2016-11-28 17:05:09 +0100
commit7300a49309f13aee9d21e39bf0e2638a461b21fc (patch)
tree607103ce3bd9e23226f22b9be68ed931f22e9a6f
parentfe1fca9f80e77e280240f8773027bbcaf1590abb (diff)
downloadastra-7300a49309f13aee9d21e39bf0e2638a461b21fc.tar.gz
astra-7300a49309f13aee9d21e39bf0e2638a461b21fc.tar.bz2
astra-7300a49309f13aee9d21e39bf0e2638a461b21fc.tar.xz
astra-7300a49309f13aee9d21e39bf0e2638a461b21fc.zip
Fix warnings
-rw-r--r--include/astra/ParallelBeamLinearKernelProjector2D.inl6
-rw-r--r--src/CudaFDKAlgorithm3D.cpp2
-rw-r--r--src/CudaSartAlgorithm.cpp2
3 files changed, 4 insertions, 6 deletions
diff --git a/include/astra/ParallelBeamLinearKernelProjector2D.inl b/include/astra/ParallelBeamLinearKernelProjector2D.inl
index 30040fa..5dd4781 100644
--- a/include/astra/ParallelBeamLinearKernelProjector2D.inl
+++ b/include/astra/ParallelBeamLinearKernelProjector2D.inl
@@ -54,8 +54,8 @@ void CParallelBeamLinearKernelProjector2D::projectBlock_internal(int _iProjFrom,
{
// variables
float32 theta, sin_theta, cos_theta, inv_sin_theta, inv_cos_theta, t;
- float32 lengthPerRow, updatePerRow, inv_pixelLengthX;
- float32 lengthPerCol, updatePerCol, inv_pixelLengthY;
+ float32 lengthPerRow, updatePerRow;
+ float32 lengthPerCol, updatePerCol;
bool switch_t;
int iAngle, iDetector, iVolumeIndex, iRayIndex;
int row, col, x1;
@@ -82,12 +82,10 @@ void CParallelBeamLinearKernelProjector2D::projectBlock_internal(int _iProjFrom,
// precalculate kernel limits
lengthPerRow = m_pVolumeGeometry->getPixelLengthY() * inv_cos_theta;
updatePerRow = sin_theta * inv_cos_theta;
- inv_pixelLengthX = 1.0f / m_pVolumeGeometry->getPixelLengthX();
// precalculate kernel limits
lengthPerCol = m_pVolumeGeometry->getPixelLengthX() * inv_sin_theta;
updatePerCol = cos_theta * inv_sin_theta;
- inv_pixelLengthY = 1.0f / m_pVolumeGeometry->getPixelLengthY();
// loop detectors
for (iDetector = _iDetFrom; iDetector < _iDetTo; ++iDetector) {
diff --git a/src/CudaFDKAlgorithm3D.cpp b/src/CudaFDKAlgorithm3D.cpp
index fef4f41..d02db6d 100644
--- a/src/CudaFDKAlgorithm3D.cpp
+++ b/src/CudaFDKAlgorithm3D.cpp
@@ -221,7 +221,7 @@ void CCudaFDKAlgorithm3D::run(int _iNrIterations)
const CProjectionGeometry3D* projgeom = m_pSinogram->getGeometry();
const CConeProjectionGeometry3D* conegeom = dynamic_cast<const CConeProjectionGeometry3D*>(projgeom);
- const CVolumeGeometry3D& volgeom = *m_pReconstruction->getGeometry();
+ // const CVolumeGeometry3D& volgeom = *m_pReconstruction->getGeometry();
ASTRA_ASSERT(conegeom);
diff --git a/src/CudaSartAlgorithm.cpp b/src/CudaSartAlgorithm.cpp
index 645b40c..a768db9 100644
--- a/src/CudaSartAlgorithm.cpp
+++ b/src/CudaSartAlgorithm.cpp
@@ -98,7 +98,7 @@ bool CCudaSartAlgorithm::initialize(const Config& _cfg)
} else if (projOrder == "custom") {
vector<float32> projOrderList = _cfg.self.getOptionNumericalArray("ProjectionOrderList");
projectionOrder = new int[projOrderList.size()];
- for (int i = 0; i < projOrderList.size(); i++) {
+ for (unsigned int i = 0; i < projOrderList.size(); i++) {
projectionOrder[i] = static_cast<int>(projOrderList[i]);
}
sart->setProjectionOrder(projectionOrder, projectionCount);