Currently job artifacts in CI/CD pipelines on LRZ GitLab never expire. Starting from Wed 26.1.2022 the default expiration time will be 30 days (GitLab default). Currently existing artifacts in already completed jobs will not be affected by the change. The latest artifacts for all jobs in the latest successful pipelines will be kept. More information: https://gitlab.lrz.de/help/user/admin_area/settings/continuous_integration.html#default-artifacts-expiration

Commit 30b3896a authored by Hossain Mahmud's avatar Hossain Mahmud
Browse files

Initial changes for GenericImageReader and AbstractImageReader

parent fcc64595
// ================================================================================================
//
// This file is part of the CAMPVis Software Framework.
//
// If not explicitly stated otherwise: Copyright (C) 2012, all rights reserved,
// Christian Schulte zu Berge <christian.szb@in.tum.de>
// Chair for Computer Aided Medical Procedures
// Technische Universitt Mnchen
// Boltzmannstr. 3, 85748 Garching b. Mnchen, Germany
// For a full list of authors and contributors, please refer to the file "AUTHORS.txt".
//
// The licensing of this softare is not yet resolved. Until then, redistribution in source or
// binary forms outside the CAMP chair is not permitted, unless explicitly stated in legal form.
// However, the names of the original authors and the above copyright notice must retain in its
// original state in any case.
//
// Legal disclaimer provided by the BSD license:
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
// IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
// AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
// POSSIBILITY OF SUCH DAMAGE.
//
// ================================================================================================
#include "abstractimagereader.h"
//#include <fstream>
//
//#include "tgt/filesystem.h"
//#include "core/datastructures/imagedata.h"
//#include "core/datastructures/imagerepresentationdisk.h"
//#include "core/datastructures/genericimagerepresentationlocal.h"
//#include "core/tools/textfileparser.h"
namespace campvis {
AbstractImageReader::AbstractImageReader()
: p_url("url", "Image URL", "")
, p_targetImageID("targetImageName", "Target Image ID", "AbstractImageReader.output", DataNameProperty::WRITE)
{
}
AbstractImageReader::~AbstractImageReader() {
}
void AbstractImageReader::setURL(StringProperty p_url) {
this->p_url.setValue(p_url.getValue());
std::string url = this->p_url.getValue();
unsigned extPos = (unsigned) url.rfind('.');
if (extPos != std::string::npos) {
this->_ext = url.substr(extPos);
}
}
void AbstractImageReader::setTargetImageId(DataNameProperty& targetImageId) {
this->p_targetImageID.setValue(targetImageId.getValue());
std::set<AbstractProperty*> sharedProperties = targetImageId.getSharedProperties();
for(std::set<AbstractProperty*>::iterator it = sharedProperties.begin(); it != sharedProperties.end(); it++) {
this->p_targetImageID.addSharedProperty(*it);
}
}
void AbstractImageReader::setTargetImageId(std::string imageId) {
this->p_targetImageID.setValue(imageId);
}
void AbstractImageReader::setTargetImageIdSharedProperty(DataNameProperty* sharedProperty) {
this->p_targetImageID.addSharedProperty(sharedProperty);
}
}
\ No newline at end of file
// ================================================================================================
//
// This file is part of the CAMPVis Software Framework.
//
// If not explicitly stated otherwise: Copyright (C) 2012, all rights reserved,
// Christian Schulte zu Berge <christian.szb@in.tum.de>
// Chair for Computer Aided Medical Procedures
// Technische Universität München
// Boltzmannstr. 3, 85748 Garching b. München, Germany
// For a full list of authors and contributors, please refer to the file "AUTHORS.txt".
//
// The licensing of this softare is not yet resolved. Until then, redistribution in source or
// binary forms outside the CAMP chair is not permitted, unless explicitly stated in legal form.
// However, the names of the original authors and the above copyright notice must retain in its
// original state in any case.
//
// Legal disclaimer provided by the BSD license:
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
// IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
// AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
// POSSIBILITY OF SUCH DAMAGE.
//
// ================================================================================================
#ifndef ABSTRACTIMAGEREADER_H__
#define ABSTRACTIMAGEREADER_H__
#include <string>
#include <vector>
#include "core/pipeline/abstractprocessor.h"
#include "core/properties/datanameproperty.h"
#include "core/properties/floatingpointproperty.h"
//#include "modules/io/processors/csvdimagereader.h"
//#include "modules/io/processors/ltfimagereader.h"
//#include "modules/io/processors/mhdimagereader.h"
//#include "modules/io/processors/rawimagereader.h"
//#include "modules/io/processors/vtkimagereader.h"
namespace campvis {
/**
* Reads an image file into the pipeline. This is mainly a wrapper class. It uses
* the other image reader implemented for its tasks.
*
* Provides the interface for the classes that reads images from different types
* of files into ImageRepresentationDisk representation
*
*/
class AbstractImageReader : public AbstractProcessor {
public:
/**
* Constructs a new AbstractImageReader Processor
**/
AbstractImageReader();
/**
* Destructor
**/
virtual ~AbstractImageReader();
/**
* Provides the interface for the classes that reads images from different types
* of files into ImageRepresentationDisk representation
* \param data DataContainer to work on
*/
//virtual void process(DataContainer& data);
///// \see AbstractProcessor::getName()
//virtual const std::string getName() = 0;
///// \see AbstractProcessor::getDescription()
//virtual const std::string getDescription() = 0;
///// \see AbstractProcessor::getAuthor()
//virtual const std::string getAuthor() = 0;
///// \see AbstractProcessor::getProcessorState()
//virtual ProcessorState getProcessorState() = 0;
/// \see AbstractProcessor::getExtension()
virtual const std::string getExtension() = 0;
/// \see AbstractProcessor::getMetaProperties()
virtual PropertyCollection& getMetaProperties() = 0;
/// functions to set the property of the readers
virtual void setURL(StringProperty p_url);
virtual void setTargetImageId(DataNameProperty& targetImageId);
virtual void setTargetImageId(std::string imageId);
virtual void setTargetImageIdSharedProperty(DataNameProperty* sharedProperty);
public:
StringProperty p_url; ///< URL for file to read
DataNameProperty p_targetImageID; ///< image ID for read image
protected:
std::string _ext;
static const std::string loggerCat_;
private:
};
}
#endif // ABSTRACTIMAGEREADER_H__
......@@ -44,12 +44,15 @@ namespace campvis {
const std::string CsvdImageReader::loggerCat_ = "CAMPVis.modules.io.CsvdImageReader";
CsvdImageReader::CsvdImageReader()
: AbstractProcessor()
, p_url("url", "Image URL", "")
, p_targetImageID("targetImageName", "Target Image ID", "CsvdImageReader.output", DataNameProperty::WRITE)
: AbstractImageReader()
//, p_url("url", "Image URL", "")
//, p_targetImageID("targetImageName", "Target Image ID", "CsvdImageReader.output", DataNameProperty::WRITE)
, p_imageOffset("ImageOffset", "Image Offset in mm", tgt::vec3(0.f), tgt::vec3(-10000.f), tgt::vec3(10000.f), tgt::vec3(0.1f))
, p_voxelSize("VoxelSize", "Voxel Size in mm", tgt::vec3(1.f), tgt::vec3(-100.f), tgt::vec3(100.f), tgt::vec3(0.1f))
{
this->_ext = "csv";
this->p_targetImageID.setValue("CsvdImageReader.output");
addProperty(&p_url);
addProperty(&p_targetImageID);
addProperty(&p_imageOffset);
......@@ -180,4 +183,10 @@ namespace campvis {
validate(INVALID_RESULT);
}
PropertyCollection& CsvdImageReader::getMetaProperties() {
PropertyCollection dummy;
return dummy;
}
}
\ No newline at end of file
......@@ -31,6 +31,7 @@
#define CSVDIMAGEREADER_H__
#include <string>
#include "abstractimagereader.h"
#include "core/pipeline/abstractprocessor.h"
#include "core/properties/datanameproperty.h"
......@@ -41,7 +42,7 @@ namespace campvis {
* Reads a CSVD to read multiple CSV image files into the pipeline.
* This YANF (yet another neat format) is proudly provided by Christian Schulte zu Berge.
*/
class CsvdImageReader : public AbstractProcessor {
class CsvdImageReader : public AbstractImageReader {
public:
/**
* Constructs a new CsvdImageReader Processor
......@@ -68,9 +69,11 @@ namespace campvis {
virtual const std::string getAuthor() const { return "Christian Schulte zu Berge <christian.szb@in.tum.de>"; };
/// \see AbstractProcessor::getProcessorState()
virtual ProcessorState getProcessorState() const { return AbstractProcessor::EXPERIMENTAL; };
StringProperty p_url; ///< URL for file to read
DataNameProperty p_targetImageID; ///< image ID for read image
/// \see AbstractProcessor::getExtension()
virtual const std::string getExtension() { return _ext;};
/// \see AbstractProcessor::getMetaProperties()
PropertyCollection& getMetaProperties();
Vec3Property p_imageOffset; ///< Image Offset in mm
Vec3Property p_voxelSize; ///< Voxel Size in mm
......
// ================================================================================================
//
// This file is part of the CAMPVis Software Framework.
//
// If not explicitly stated otherwise: Copyright (C) 2012, all rights reserved,
// Christian Schulte zu Berge <christian.szb@in.tum.de>
// Chair for Computer Aided Medical Procedures
// Technische Universitt Mnchen
// Boltzmannstr. 3, 85748 Garching b. Mnchen, Germany
// For a full list of authors and contributors, please refer to the file "AUTHORS.txt".
//
// The licensing of this softare is not yet resolved. Until then, redistribution in source or
// binary forms outside the CAMP chair is not permitted, unless explicitly stated in legal form.
// However, the names of the original authors and the above copyright notice must retain in its
// original state in any case.
//
// Legal disclaimer provided by the BSD license:
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
// IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
// AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
// POSSIBILITY OF SUCH DAMAGE.
//
// ================================================================================================
#include "genericimagereader.h"
#include <fstream>
#include "tgt/filesystem.h"
#include "core/datastructures/imagedata.h"
#include "core/datastructures/imagerepresentationdisk.h"
#include "core/datastructures/genericimagerepresentationlocal.h"
#include "core/tools/textfileparser.h"
namespace campvis {
const std::string GenericImageReader::loggerCat_ = "CAMPVis.modules.io.MhdImageReader";
GenericImageReader::GenericImageReader()
: AbstractProcessor()
, p_url("url", "Image URL", "")
{
//CsvdImageReader *_csvdImageReader = new CsvdImageReader();
//this->_readers.push_back(_csvdImageReader);
//LtfImageReader *_ltfImageReader = new LtfImageReader();
//this->_readers.push_back(_ltfImageReader);
//MhdImageReader *_mhdImageReader = new MhdImageReader();
//this->_readers.push_back(_mhdImageReader);
//RawImageReader *_rawImageReader = new RawImageReader();
//this->_readers.push_back(_rawImageReader);
//VtkImageReader *_vtkImageReader = new VtkImageReader();
//this->_readers.push_back(_vtkImageReader);
this->_readers.push_back(new CsvdImageReader());
this->_readers.push_back(new LtfImageReader());
this->_readers.push_back(new MhdImageReader());
this->_readers.push_back(new RawImageReader());
this->_readers.push_back(new VtkImageReader());
}
GenericImageReader::~GenericImageReader() {
for(std::vector<AbstractImageReader*>::iterator it = this->_readers.begin(); it != this->_readers.end(); it++) {
delete *it;
}
}
void GenericImageReader::process(DataContainer& data) {
for(std::vector<AbstractImageReader*>::iterator it = this->_readers.begin(); it != this->_readers.end(); it++) {
if((*it)->getExtension() == this->_ext) {
(*it)->process(data);
break;
}
}
return;
}
void GenericImageReader::setURL(StringProperty p_url) {
this->p_url.setValue(p_url.getValue());
for(std::vector<AbstractImageReader*>::iterator it = this->_readers.begin(); it != this->_readers.end(); it++) {
if((*it)->getExtension() == this->_ext) {
(*it)->p_url.setValue(this->p_url.getValue());
break;
}
}
std::string url = this->p_url.getValue();
unsigned extPos = (unsigned) url.rfind('.');
if (extPos != std::string::npos) {
this->_ext = url.substr(extPos);
}
return;
}
void GenericImageReader::setTargetImageId(DataNameProperty& targetImageId) {
for(std::vector<AbstractImageReader*>::iterator it = this->_readers.begin(); it != this->_readers.end(); it++) {
if((*it)->getExtension() == this->_ext) {
(*it)->p_targetImageID.setValue(targetImageId.getValue());
std::set<AbstractProperty*> sharedProperties = targetImageId.getSharedProperties();
for(std::set<AbstractProperty*>::iterator jt = sharedProperties.begin(); jt != sharedProperties.end(); jt++) {
(*it)->p_targetImageID.addSharedProperty(*jt);
}
break;
}
}
return;
}
void GenericImageReader::setTargetImageId(std::string imageId) {
for(std::vector<AbstractImageReader*>::iterator it = this->_readers.begin(); it != this->_readers.end(); it++) {
if((*it)->getExtension() == this->_ext) {
(*it)->p_targetImageID.setValue(imageId);
break;
}
}
return;
}
void GenericImageReader::setTargetImageIdSharedProperty(DataNameProperty* sharedProperty) {
for(std::vector<AbstractImageReader*>::iterator it = this->_readers.begin(); it != this->_readers.end(); it++) {
if((*it)->getExtension() == this->_ext) {
(*it)->p_targetImageID.addSharedProperty(sharedProperty);
break;
}
}
return;
}
void GenericImageReader::setMetaProperties(PropertyCollection &metaProperties) {
return;
}
}
\ No newline at end of file
// ================================================================================================
//
// This file is part of the CAMPVis Software Framework.
//
// If not explicitly stated otherwise: Copyright (C) 2012, all rights reserved,
// Christian Schulte zu Berge <christian.szb@in.tum.de>
// Chair for Computer Aided Medical Procedures
// Technische Universität München
// Boltzmannstr. 3, 85748 Garching b. München, Germany
// For a full list of authors and contributors, please refer to the file "AUTHORS.txt".
//
// The licensing of this softare is not yet resolved. Until then, redistribution in source or
// binary forms outside the CAMP chair is not permitted, unless explicitly stated in legal form.
// However, the names of the original authors and the above copyright notice must retain in its
// original state in any case.
//
// Legal disclaimer provided by the BSD license:
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
// IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
// AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
// POSSIBILITY OF SUCH DAMAGE.
//
// ================================================================================================
#ifndef GENERICIMAGEREADER_H__
#define GENERICIMAGEREADER_H__
#include <string>
#include "core/pipeline/abstractprocessor.h"
#include "core/properties/datanameproperty.h"
#include "core/properties/floatingpointproperty.h"
#include "modules/io/processors/csvdimagereader.h"
#include "modules/io/processors/ltfimagereader.h"
#include "modules/io/processors/mhdimagereader.h"
#include "modules/io/processors/rawimagereader.h"
#include "modules/io/processors/vtkimagereader.h"
namespace campvis {
/**
* Reads an image file into the pipeline. This is mainly a wrapper class. It uses
* the other image reader implemented for its tasks.
*
*/
class GenericImageReader : public AbstractProcessor {
public:
/**
* Constructs a new GenericImageReader Processor
**/
GenericImageReader();
/**
* Destructor
**/
virtual ~GenericImageReader();
/**
* Reads the MHD file into an ImageRepresentationDisk representation
* \param data DataContainer to work on
*/
virtual void process(DataContainer& data);
/// \see AbstractProcessor::getName()
virtual const std::string getName() const { return "GenericImageReader"; };
/// \see AbstractProcessor::getDescription()
virtual const std::string getDescription() const { return "Reads an image into the pipeline."; };
/// \see AbstractProcessor::getAuthor()
virtual const std::string getAuthor() const { return "Hossain Mahmud <mahmud@in.tum.de>"; };
/// \see AbstractProcessor::getProcessorState()
virtual ProcessorState getProcessorState() const { return AbstractProcessor::TESTING; };
/// functions to set the property of the readers
void setURL(StringProperty p_url);
void setTargetImageId(DataNameProperty& targetImageId);
void setTargetImageId(std::string imageId);
void setTargetImageIdSharedProperty(DataNameProperty* sharedProperty);
void setMetaProperties(PropertyCollection &metaProperties);
protected:
static const std::string loggerCat_;
private:
std::vector<AbstractImageReader*> _readers;
StringProperty p_url;
std::string _ext;
CsvdImageReader _csvdImageReader;
LtfImageReader _ltfImageReader;
MhdImageReader _mhdImageReader;
RawImageReader _rawImageReader;
VtkImageReader _vtkImageReader;
//std::map<std::string, std::string> _extMap;
};
}
#endif // GENERICIMAGEREADER_H__
......@@ -51,15 +51,16 @@ namespace campvis {
const std::string LtfImageReader::loggerCat_ = "CAMPVis.modules.io.LtfImageReader";
LtfImageReader::LtfImageReader()
: AbstractProcessor()
, p_url("url", "Image URL", "")
: AbstractImageReader()
, p_size("Size", "Image Size", tgt::ivec3(1), tgt::ivec3(1), tgt::ivec3(2048))
, p_numChannels("NumChannels", "Number of Channels per Element", 1, 1, 9)
, p_baseType("BaseType", "Base Type", baseTypeOptions, 7)
, p_targetImageID("targetImageName", "Target Image ID", "LtfImageReader.output", DataNameProperty::WRITE)
, p_imageOffset("ImageOffset", "Image Offset in mm", tgt::vec3(0.f), tgt::vec3(-10000.f), tgt::vec3(10000.f), tgt::vec3(0.1f))
, p_voxelSize("VoxelSize", "Voxel Size in mm", tgt::vec3(1.f), tgt::vec3(-100.f), tgt::vec3(100.f), tgt::vec3(0.1f))
{
this->_ext = "ltf";
this->p_targetImageID.setValue("LtfImageReader.output");
addProperty(&p_url);
addProperty(&p_size);
addProperty(&p_numChannels);
......@@ -103,4 +104,9 @@ namespace campvis {
validate(INVALID_RESULT);
}
PropertyCollection& LtfImageReader::getMetaProperties() {
PropertyCollection dummy;
return dummy;
}
}
......@@ -30,6 +30,8 @@
#ifndef LTFIMAGEREADER_H__
#define LTFIMAGEREADER_H__
#include "AbstractImageReader.h"
#include "core/pipeline/abstractprocessor.h"
#include "core/properties/datanameproperty.h"
#include "core/properties/floatingpointproperty.h"
......@@ -42,7 +44,7 @@ namespace campvis {
/**
* Reads raw images into the pipeline.
*/
class LtfImageReader : public AbstractProcessor {
class LtfImageReader : public AbstractImageReader {
public:
/**
* Constructs a new LtfImageReader Processor
......@@ -69,14 +71,16 @@ namespace campvis {
virtual const std::string getAuthor() const { return "Christian Schulte zu Berge <christian.szb@in.tum.de>"; };
/// \see AbstractProcessor::getProcessorState()
virtual ProcessorState getProcessorState() const { return AbstractProcessor::EXPERIMENTAL; };
/// \see AbstractProcessor::getExtension()
virtual const std::string getExtension() { return _ext;};
/// \see AbstractProcessor::getMetaProperties()
PropertyCollection& getMetaProperties();
StringProperty p_url; ///< URL for file to read
IVec3Property p_size; ///< Image size
IntProperty p_numChannels; ///< Number of channels per element
GenericOptionProperty<WeaklyTypedPointer::BaseType> p_baseType; ///< Base type
DataNameProperty p_targetImageID; ///< image ID for read image
Vec3Property p_imageOffset; ///< Image Offset in mm
Vec3Property p_voxelSize; ///< Voxel Size in mm
......
......@@ -45,12 +45,12 @@ namespace campvis {
const std::string MhdImageReader::loggerCat_ = "CAMPVis.modules.io.MhdImageReader";
MhdImageReader::MhdImageReader()
: AbstractProcessor()
, p_url("url", "Image URL", "")
, p_targetImageID("targetImageName", "Target Image ID", "MhdImageReader.output", DataNameProperty::WRITE)
: AbstractImageReader()
, p_imageOffset("ImageOffset", "Image Offset in mm", tgt::vec3(0.f), tgt::vec3(-10000.f), tgt::vec3(10000.f), tgt::vec3(0.1f))
, p_voxelSize("VoxelSize", "Voxel Size in mm", tgt::vec3(1.f), tgt::vec3(-100.f), tgt::vec3(100.f), tgt::vec3(0.1f))
{
this->_ext = "mhd";
this->p_targetImageID.setValue("MhdImageReader.output");
addProperty(&p_url);
addProperty(&p_targetImageID);
addProperty(&p_imageOffset);
......@@ -202,4 +202,9 @@ namespace campvis {
validate(INVALID_RESULT);
}
PropertyCollection& MhdImageReader::getMetaProperties() {
PropertyCollection dummy;
return dummy;
}
}
\ No newline at end of file
......@@ -31,6 +31,7 @@
#define MHDIMAGEREADER_H__
#include <string>
#include "abstractimagereader.h"
#include "core/pipeline/abstractprocessor.h"
#include "core/properties/datanameproperty.h"
......@@ -42,7 +43,7 @@ namespace campvis {
*
* \note Full format specification at http://www.itk.org/Wiki/MetaIO/Documentation
*/
class MhdImageReader : public AbstractProcessor {
class MhdImageReader : public AbstractImageReader {