marImageData Class Reference

#include <marImageData.h>

List of all members.

Public Member Functions

 marImageData (vtkImageData *imagedata)
 ~marImageData ()
void SetSpcOriginal (double spc[3])
void SetVoiOriginal (int voi[6])
void AddImageData (vtkImageData *imagedata)
void removeImageData (int index)
void GetSpcOriginal (double spc[3])
void GetVoiOriginal (int voi[6])
vtkImageData * GetImageData ()
vtkImageData * GetImageDataT (int t)
int GetMaxT ()
int GetXOriginal (int value)
int GetYOriginal (int value)
int GetZOriginal (int value)

Private Attributes

double _spcOriginal [3]
int _voiOriginal [6]
std::vector< vtkImageData * > _imagedataLST

Detailed Description

Definition at line 12 of file marImageData.h.


Constructor & Destructor Documentation

marImageData::marImageData ( vtkImageData *  imagedata  ) 

Definition at line 8 of file marImageData.cpp.

References _spcOriginal, _voiOriginal, and AddImageData().

00009 {
00010         _spcOriginal[0] = 1;
00011         _spcOriginal[1] = 1;
00012         _spcOriginal[2] = 1;
00013         _voiOriginal[0] = 0;
00014         _voiOriginal[1] = 0;
00015         _voiOriginal[2] = 0;
00016         _voiOriginal[3] = 0;
00017         _voiOriginal[4] = 0;
00018         _voiOriginal[5] = 0;
00019         if(imagedata!=NULL){
00020                 AddImageData(imagedata);
00021         }
00022 }

Here is the call graph for this function:

marImageData::~marImageData (  ) 

Definition at line 24 of file marImageData.cpp.

References _imagedataLST.

00025 {
00026         int i,size=_imagedataLST.size();
00027         for (i=0;i<size;i++)
00028         {
00029         //      _imagedataLST[i]->Delete();
00030         }
00031         _imagedataLST.clear();
00032 }


Member Function Documentation

void marImageData::AddImageData ( vtkImageData *  imagedata  ) 

Definition at line 51 of file marImageData.cpp.

References _imagedataLST.

Referenced by marDynData::loadData(), marImageData(), wxMaracas_ViewerWidget::SetImage(), and wxMPRWidget::setImageData().

00052 {
00053         if (imagedata!=NULL){
00054                 _imagedataLST.push_back( imagedata );
00055         }
00056 }

Here is the caller graph for this function:

vtkImageData * marImageData::GetImageData (  ) 
vtkImageData * marImageData::GetImageDataT ( int  t  ) 

Definition at line 74 of file marImageData.cpp.

References _imagedataLST.

Referenced by vtkBaseData::GetImageData().

00075 {
00076         if(_imagedataLST.size() > t){
00077                 return _imagedataLST[t];
00078         }
00079         return NULL;
00080 }

Here is the caller graph for this function:

int marImageData::GetMaxT (  ) 

Definition at line 151 of file marImageData.cpp.

References _imagedataLST.

Referenced by vtkBaseData::SetT().

00152 {
00153         return _imagedataLST.size();
00154 }

Here is the caller graph for this function:

void marImageData::GetSpcOriginal ( double  spc[3]  ) 

Definition at line 58 of file marImageData.cpp.

References _spcOriginal.

00059 {
00060         spc[0] = this->_spcOriginal[0];
00061         spc[1] = this->_spcOriginal[1];
00062         spc[2] = this->_spcOriginal[2];
00063 }

void marImageData::GetVoiOriginal ( int  voi[6]  ) 

Definition at line 65 of file marImageData.cpp.

References _voiOriginal.

00066 {
00067         int i;
00068         for (i=0;i<6;i++)
00069         {
00070                 voi[i] = this->_voiOriginal[i];
00071         }
00072 }

int marImageData::GetXOriginal ( int  value  ) 

Definition at line 103 of file marImageData.cpp.

References _spcOriginal, _voiOriginal, and min.

Referenced by wxQuantificationWidgetCT::MoveSlider(), and vtkInfoTextImage::PutPosition().

00104 {
00105         double min=_spcOriginal[0];
00106         if (_spcOriginal[1]<min)
00107         {
00108                 min = _spcOriginal[1];
00109         }
00110         if (_spcOriginal[2]<min)
00111         {
00112                 min = _spcOriginal[2];
00113         }
00114         double result = value / (  _spcOriginal[0] / min ) ;
00115         result=result + _voiOriginal[0];
00116         return (int)result;
00117 }

Here is the caller graph for this function:

int marImageData::GetYOriginal ( int  value  ) 

Definition at line 119 of file marImageData.cpp.

References _spcOriginal, _voiOriginal, and min.

Referenced by wxQuantificationWidgetCT::MoveSlider(), and vtkInfoTextImage::PutPosition().

00120 {
00121         double min=_spcOriginal[0];
00122         if (_spcOriginal[1]<min)
00123         {
00124                 min = _spcOriginal[1];
00125         }
00126         if (_spcOriginal[2]<min)
00127         {
00128                 min = _spcOriginal[2];
00129         }
00130         double result = value / (  _spcOriginal[1] / min ) ;
00131         result=result + _voiOriginal[2];
00132         return (int)result;
00133 }

Here is the caller graph for this function:

int marImageData::GetZOriginal ( int  value  ) 

Definition at line 135 of file marImageData.cpp.

References _spcOriginal, _voiOriginal, and min.

Referenced by wxQuantificationWidgetCT::MoveSlider(), and vtkInfoTextImage::PutPosition().

00136 {
00137         double min=_spcOriginal[0];
00138         if (_spcOriginal[1]<min)
00139         {
00140                 min = _spcOriginal[1];
00141         }
00142         if (_spcOriginal[2]<min)
00143         {
00144                 min = _spcOriginal[2];
00145         }
00146         double result = value / (  _spcOriginal[2] / min ) ;
00147         result=result + _voiOriginal[4];
00148         return (int)result;
00149 }

Here is the caller graph for this function:

void marImageData::removeImageData ( int  index  ) 

Definition at line 90 of file marImageData.cpp.

References _imagedataLST.

Referenced by wxMaracas_ViewerWidget::SetImage(), and wxMPRWidget::setImageData().

00091 {
00092         if(index < _imagedataLST.size()){
00093 
00094                 //vtkImageData* img = _imagedataLST[index];
00095                 for(int i = index; i < _imagedataLST.size()-1; i++){                    
00096                         _imagedataLST[i] = _imagedataLST[i+1];
00097                 }
00098                 _imagedataLST.pop_back();
00099                 //delete img;
00100         }       
00101 }

Here is the caller graph for this function:

void marImageData::SetSpcOriginal ( double  spc[3]  ) 

Definition at line 35 of file marImageData.cpp.

References _spcOriginal.

Referenced by marDynData::loadData().

00036 {
00037         this->_spcOriginal[0]=spc[0];
00038         this->_spcOriginal[1]=spc[1];
00039         this->_spcOriginal[2]=spc[2];
00040 }

Here is the caller graph for this function:

void marImageData::SetVoiOriginal ( int  voi[6]  ) 

Definition at line 42 of file marImageData.cpp.

References _voiOriginal.

Referenced by marDynData::loadData().

00043 {
00044         int i;
00045         for (i=0;i<6;i++)
00046         {
00047                 this->_voiOriginal[i] = voi[i];
00048         }
00049 }

Here is the caller graph for this function:


Member Data Documentation

std::vector<vtkImageData *> marImageData::_imagedataLST [private]
double marImageData::_spcOriginal[3] [private]
int marImageData::_voiOriginal[6] [private]

The documentation for this class was generated from the following files:

Generated on 18 Mar 2010 for creaMaracasVisu_lib by  doxygen 1.6.1