NIREP

ResourceListTree.h

Go to the documentation of this file.
00001 #include "gecSpatialData.h"
00002 #include "gecImage.h"
00003 #include "gecObjectMap.h"
00004 #include "gecTransformation.h"
00005 #include <string>
00006 
00007 /* Definition of loaded spatial data list entry */
00008 // Note that a transformation is also classified as spatial data and will be
00009 // added to this list despite the fact that spatial data resource list and
00010 // transformation resource list are two separate lists.
00011 class LoadedSpatialData {
00012 public:
00013   gec::SpatialData* data;     // Pointer to spatial data in memory
00014   unsigned int      refCount; // Reference count - keep track of dependencies
00015 };
00016 
00017 
00018 /* Definition of spatial data resource entry */
00019 // Spatial data item (e.g. MRI, CT, OBJMAP, etc) attributes
00020 class SpatialDataItem {
00021   public:
00022   typedef std::map<std::string, std::string> AttributeList;
00023   std::string                directory;  // directory location of file
00024   std::string                filename;   // location of the data set
00025   gec::SpatialData::DataType datatype;   // e.g. IMAGE, OBJECTMAP, LANDMARK, etc
00026   AttributeList              attributes; // e.g. description, modality, scanner, etc
00027 };
00028 
00029 
00030 // Spatial data set (e.g. "01") attributes
00031 class SpatialDataSet {
00032   public:
00033   typedef std::map<std::string, SpatialDataItem> SpatialDataItemList;
00034   std::string         name;       // e.g. "na01"
00035   std::string         identifier; // e.g. "hnnl001"
00036   std::string         race;       // e.g. "Martian"
00037   signed short        handedness; // e.g. +95
00038   unsigned short      age;        // e.g. 969
00039   enum Gender {M,F}   gender;     // e.g. Male
00040   SpatialDataItemList dataitem;   // [dataID (e.g. MRI, OBJMAP), dataitem]
00041 };
00042 
00043 // Spatial data resource list (top level resource table) attributes
00044 class SpatialDataResourceList {
00045   public:
00046   typedef std::map<std::string, SpatialDataSet> SpatialDataSetList;
00047   std::string        path;    // path where the resource file is located
00048   std::string        id;      // e.g. "T1"
00049   std::string        title;   // e.g. "T1 database"
00050   SpatialDataSetList dataset; // [datasetID (e.g. "01"), dataset]
00051 };
00052 
00053 /* Definition of transformation data resource entry */
00054 // Transformation item attributes
00055 class TransformationItem {
00056   public:
00057   typedef std::vector<std::string>           FilenameList;
00058   typedef std::map<std::string, std::string> AttributeList;
00059   std::string   directory;  // e.g. "./data/na01_To_na02/"
00060   FilenameList  filename;   // location(s) of transformation file(s)
00061   AttributeList attributes; // additional attributes
00062 };
00063 
00064 // Transformation set (e.g. "SICLE_param1") attributes
00065 class TransformationSet {
00066   public:
00067   typedef std::map<std::string, TransformationItem> TransformationItemList;
00068   std::string                             path;           // path where the resource file is located
00069   std::string                             name;           // e.g. SICLE, AIR, DEMONS, etc
00070   std::string                             parameter;      // e.g. ICC=0, TC=1, etc
00071   std::string                             description;    // algorithm and paramter description
00072   gec::Transformation::TransformationType format;         // e.g. DISPLACEMENT, AFFINE, SICLE, etc
00073   std::vector<float>                      scale;          // e.g. scale factor to convert to image space
00074   TransformationItemList                  transformation; // [source+target, transformation]
00075 };
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Defines