diff options
author | Willem Jan Palenstijn <wjp@usecode.org> | 2015-04-14 14:54:38 +0200 |
---|---|---|
committer | Willem Jan Palenstijn <wjp@usecode.org> | 2015-04-14 14:54:38 +0200 |
commit | d24877997bfe77e7177e3208328d99e1f99ac6b9 (patch) | |
tree | 58a86e22618775acfb5e761201727eec558c9200 /src/Float32ProjectionData2D.cpp | |
parent | 306b3b5613ccb039122d38e8deb1e0ecc9e43403 (diff) | |
parent | 1b32573046f33050b9300324e6c74e10abb6caaf (diff) | |
download | astra-d24877997bfe77e7177e3208328d99e1f99ac6b9.tar.gz astra-d24877997bfe77e7177e3208328d99e1f99ac6b9.tar.bz2 astra-d24877997bfe77e7177e3208328d99e1f99ac6b9.tar.xz astra-d24877997bfe77e7177e3208328d99e1f99ac6b9.zip |
Merge pull request #51 from dmpelt/python-link
Add 'link' feature to Python (for 2D and 3D data)
Diffstat (limited to 'src/Float32ProjectionData2D.cpp')
-rw-r--r-- | src/Float32ProjectionData2D.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/Float32ProjectionData2D.cpp b/src/Float32ProjectionData2D.cpp index 85e0cdd..f7f83e3 100644 --- a/src/Float32ProjectionData2D.cpp +++ b/src/Float32ProjectionData2D.cpp @@ -75,6 +75,16 @@ CFloat32ProjectionData2D::CFloat32ProjectionData2D(const CFloat32ProjectionData2 m_bInitialized = true; } +//---------------------------------------------------------------------------------------- +// Create an instance of the CFloat32ProjectionData2D class with pre-allocated data +CFloat32ProjectionData2D::CFloat32ProjectionData2D(CProjectionGeometry2D* _pGeometry, CFloat32CustomMemory* _pCustomMemory) +{ + m_bInitialized = false; + m_bInitialized = initialize(_pGeometry, _pCustomMemory); +} + + + // Assignment operator CFloat32ProjectionData2D& CFloat32ProjectionData2D::operator=(const CFloat32ProjectionData2D& _other) @@ -119,6 +129,15 @@ bool CFloat32ProjectionData2D::initialize(CProjectionGeometry2D* _pGeometry, flo } //---------------------------------------------------------------------------------------- +// Initialization +bool CFloat32ProjectionData2D::initialize(CProjectionGeometry2D* _pGeometry, CFloat32CustomMemory* _pCustomMemory) +{ + m_pGeometry = _pGeometry->clone(); + m_bInitialized = _initialize(m_pGeometry->getDetectorCount(), m_pGeometry->getProjectionAngleCount(), _pCustomMemory); + return m_bInitialized; +} + +//---------------------------------------------------------------------------------------- // Destructor CFloat32ProjectionData2D::~CFloat32ProjectionData2D() { |