diff options
author | Willem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl> | 2015-12-04 16:35:00 +0100 |
---|---|---|
committer | Willem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl> | 2015-12-04 16:35:00 +0100 |
commit | f3ac1849f2b141ea1845752e1ca2317845e90e3a (patch) | |
tree | adcdc9013af5cca4165857408ed7181ffdf0de64 /src/CudaProjector2D.cpp | |
parent | 8144bf0397ee1913b830d82058ccd40df741f1b3 (diff) | |
parent | 0d015b1c91581ee5ef3e936f03e4c62fbc7ea362 (diff) | |
download | astra-f3ac1849f2b141ea1845752e1ca2317845e90e3a.tar.gz astra-f3ac1849f2b141ea1845752e1ca2317845e90e3a.tar.bz2 astra-f3ac1849f2b141ea1845752e1ca2317845e90e3a.tar.xz astra-f3ac1849f2b141ea1845752e1ca2317845e90e3a.zip |
Merge branch 'master'
Diffstat (limited to 'src/CudaProjector2D.cpp')
-rw-r--r-- | src/CudaProjector2D.cpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/CudaProjector2D.cpp b/src/CudaProjector2D.cpp index a26e32d..acf6000 100644 --- a/src/CudaProjector2D.cpp +++ b/src/CudaProjector2D.cpp @@ -61,6 +61,7 @@ void CCudaProjector2D::_clear() m_projectionKernel = ker2d_default; m_iVoxelSuperSampling = 1; m_iDetectorSuperSampling = 1; + m_iGPUIndex = -1; } //---------------------------------------------------------------------------------------- @@ -125,18 +126,18 @@ bool CCudaProjector2D::initialize(const Config& _cfg) m_iDetectorSuperSampling = (int)_cfg.self.getOptionNumerical("DetectorSuperSampling", 1); CC.markOptionParsed("DetectorSuperSampling"); + // GPU number + m_iGPUIndex = (int)_cfg.self.getOptionNumerical("GPUindex", -1); + m_iGPUIndex = (int)_cfg.self.getOptionNumerical("GPUIndex", m_iGPUIndex); + CC.markOptionParsed("GPUIndex"); + if (!_cfg.self.hasOption("GPUIndex")) + CC.markOptionParsed("GPUindex"); + + m_bIsInitialized = _check(); return m_bIsInitialized; } -/* -bool CProjector2D::initialize(astra::CProjectionGeometry2D *, astra::CVolumeGeometry2D *) -{ - ASTRA_ASSERT(false); - - return false; -} -*/ std::string CCudaProjector2D::description() const { |