43 static bool alreadyDone =
false;
46 MITK_DEBUG <<
"QuantificationObjectFactory c'tor" << std::endl;
48 itk::ObjectFactoryBase::RegisterFactory(m_NrrdTbssImageIOFactory);
49 itk::ObjectFactoryBase::RegisterFactory(m_NrrdTbssRoiImageIOFactory);
51 itk::ObjectFactoryBase::RegisterFactory(m_NrrdTbssImageWriterFactory);
52 itk::ObjectFactoryBase::RegisterFactory(m_NrrdTbssRoiImageWriterFactory);
57 CreateFileExtensionsMap();
66 itk::ObjectFactoryBase::UnRegisterFactory(m_NrrdTbssImageIOFactory);
67 itk::ObjectFactoryBase::RegisterFactory(m_NrrdTbssRoiImageIOFactory);
69 itk::ObjectFactoryBase::UnRegisterFactory(m_NrrdTbssImageWriterFactory);
70 itk::ObjectFactoryBase::UnRegisterFactory(m_NrrdTbssRoiImageWriterFactory);
79 std::string classname =
"TbssRoiImage";
80 if(node->
GetData() && classname.compare(node->
GetData()->GetNameOfClass())==0)
83 newMapper->SetDataNode(node);
86 classname =
"TbssImage";
87 if(node->
GetData() && classname.compare(node->
GetData()->GetNameOfClass())==0)
90 newMapper->SetDataNode(node);
96 std::string classname =
"TbssImage";
97 if(node->
GetData() && classname.compare(node->
GetData()->GetNameOfClass())==0)
100 newMapper->SetDataNode(node);
110 std::string classname =
"TbssRoiImage";
111 if(node->
GetData() && classname.compare(node->
GetData()->GetNameOfClass())==0)
116 classname =
"TbssImage";
117 if(node->
GetData() && classname.compare(node->
GetData()->GetNameOfClass())==0)
126 std::string fileExtension;
127 this->CreateFileExtensions(m_FileExtensionsMap, fileExtension);
128 return fileExtension.c_str();
133 return m_FileExtensionsMap;
138 std::string fileExtension;
139 this->CreateFileExtensions(m_SaveFileExtensionsMap, fileExtension);
140 return fileExtension.c_str();
145 return m_SaveFileExtensionsMap;
148 void mitk::QuantificationObjectFactory::CreateFileExtensionsMap()
150 m_FileExtensionsMap.insert(std::pair<std::string, std::string>(
"*.tbss",
"TBSS data"));
151 m_FileExtensionsMap.insert(std::pair<std::string, std::string>(
"*.roi",
"TBSS ROI data"));
153 m_SaveFileExtensionsMap.insert(std::pair<std::string, std::string>(
"*.tbss",
"TBSS data"));
154 m_SaveFileExtensionsMap.insert(std::pair<std::string, std::string>(
"*.roi",
"TBSS ROI data"));
157 struct RegisterQuantificationObjectFactory{
158 RegisterQuantificationObjectFactory()
159 : m_Factory(
mitk::QuantificationObjectFactory::
New() )
164 ~RegisterQuantificationObjectFactory()
virtual const char * GetSaveFileExtensions() override
static void SetDefaultProperties(mitk::DataNode *node, mitk::BaseRenderer *renderer=NULL, bool overwrite=false)
Set the default properties for general image rendering.
static void SetDefaultProperties(DataNode *node, BaseRenderer *renderer=NULL, bool overwrite=false)
virtual Mapper::Pointer CreateMapper(mitk::DataNode *node, MapperSlotId slotId) override
static Pointer GetInstance()
DataCollection - Class to facilitate loading/accessing structured data.
FileWriterList m_FileWriters
BaseData * GetData() const
Get the data object (instance of BaseData, e.g., an Image) managed by this DataNode.
QuantificationObjectFactory()
int TbssGradientPixelType
Create instances of NrrdDiffusionImageReader objects using an object factory.
Create instances of NrrdDiffusionImageReader objects using an object factory.
static RegisterQuantificationObjectFactory registerQuantificationObjectFactory
virtual const char * GetFileExtensions() override
~QuantificationObjectFactory()
static void SetDefaultProperties(mitk::DataNode *node, mitk::BaseRenderer *renderer=NULL, bool overwrite=false)
virtual mitk::CoreObjectFactoryBase::MultimapType GetFileExtensionsMap() override
unsigned int MapperSlotId
std::multimap< std::string, std::string > MultimapType
virtual void SetDefaultProperties(mitk::DataNode *node) override
Class for nodes of the DataTree.
virtual mitk::CoreObjectFactoryBase::MultimapType GetSaveFileExtensionsMap() override
static itkEventMacro(BoundingShapeInteractionEvent, itk::AnyEvent) class MITKBOUNDINGSHAPE_EXPORT BoundingShapeInteractor Pointer New()
Basic interaction methods for mitk::GeometryData.