SIVIC API  0.9.26
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
svkGESigna5XReader Class Reference

#include <svkGESigna5XReader.h>

Inheritance diagram for svkGESigna5XReader:
svkImageReader2 svkGESignaLX2Reader

Public Member Functions

 vtkTypeMacro (svkGESigna5XReader, svkImageReader2)
 
virtual int CanReadFile (const char *fname)
 
virtual const char * GetFileExtensions ()
 
virtual const char * GetDescriptiveName ()
 
virtual svkImageReader2::ReaderType GetReaderType ()
 
- Public Member Functions inherited from svkImageReader2
 vtkTypeMacro (svkImageReader2, vtkImageReader2)
 
svkImageDataGetOutput ()
 
svkImageDataGetOutput (int)
 
svkDcmHeaderGetDcmHeader (const char *fileName)
 
void OnlyReadOneInputFile ()
 
void OnlyGlobFiles ()
 
void GlobFileNames ()
 
void OnlyReadHeader (bool onlyReadHeader)
 

Static Public Member Functions

static svkGESigna5XReaderNew ()
 
- Static Public Member Functions inherited from svkImageReader2
static string StripWhite (string in)
 
static string RemoveDelimFromDate (string *slashDate, char delimChar= '/')
 
static string GetFileRoot (const char *fname)
 
static string GetFileExtension (const char *fname)
 
static string GetFilePath (const char *fname)
 
static string GetFileNameWithoutPath (const char *fname)
 
static long GetFileSize (ifstream *fs)
 

Protected Member Functions

 svkGESigna5XReader ()
 
 ~svkGESigna5XReader ()
 
virtual void ExecuteInformation ()
 
virtual void ExecuteDataWithInformation (vtkDataObject *output, vtkInformation *outInfo)
 
virtual int FillOutputPortInformation (int port, vtkInformation *info)
 
virtual
svkDcmHeader::DcmPixelDataFormat 
GetFileType ()
 
virtual GESignaHeaderReadHeader (const char *FileNameToRead)
 
bool CalculateTopLeftHandCornerAndRowColumnAndNormalVectors (GESignaHeader *hdr, double tlhc[3], double row[3], double column[3], double normal[3])
 
bool SortFilesByImagePositionPatient (GESignaHeader *selectedFile, vtkStringArray *fileNames, bool ascending)
 
bool CopyGenesisImage (FILE *infp, int width, int height, int compress, short *map_left, short *map_wide, unsigned short *output)
 
bool LoadData (const char *filename, unsigned short *outPtr, int *outExt, vtkIdType *)
 
void statTimeAndDateToAscii (void *clock, char *time, char *date)
 
void InitDcmHeader ()
 
void InitEnhancedMRImageModule ()
 
void InitPatientModule ()
 
void InitGeneralStudyModule ()
 
void InitGeneralSeriesModule ()
 
void InitGeneralEquipmentModule ()
 
void InitEnhancedGeneralEquipmentModule ()
 
void InitMultiFrameFunctionalGroupsModule ()
 
void InitMRImageAndSpectroscopyInstanceMacro ()
 
void InitMRPulseSequenceModule ()
 
void InitSharedFunctionalGroupMacros ()
 
void InitPixelMeasuresMacro ()
 
void InitPlaneOrientationMacro ()
 
void InitPixelValueTransformationMacro ()
 
void InitPerFrameFunctionalGroupMacros ()
 
void InitMRImageFrameTypeMacro ()
 
void InitMRTimingAndRelatedParametersMacro ()
 
void InitMRFOVGeometryMacro ()
 
void InitMREchoMacro ()
 
void InitMRModifierMacro ()
 
void InitMRImagingModifierMacro ()
 
void InitMRReceiveCoilMacro ()
 
void InitMRTransmitCoilMacro ()
 
void InitMRAveragesMacro ()
 
- Protected Member Functions inherited from svkImageReader2
 svkImageReader2 ()
 
 ~svkImageReader2 ()
 
void SetupOutputInformation ()
 
void SetupOutputExtent ()
 
void SetupOutputScalarData ()
 
virtual void ReadLine (ifstream *hdr, istringstream *iss)
 
void ReadLineIgnore (ifstream *hdr, istringstream *iss, char delim)
 
string ReadLineSubstr (ifstream *hdr, istringstream *iss, int start, int stop)
 
string ReadLineValue (ifstream *hdr, istringstream *iss, char delim)
 
int ReadLineKeyValue (ifstream *hdr, istringstream *iss, char delim, string *key, string *value)
 
virtual void SetProvenance ()
 
virtual string GetFileSeriesDescription (string fileName)
 
void SetReadLength (int length)
 

Protected Attributes

int numFrames
 
svkDcmHeader::DcmDataOrderingDirection dataSliceOrder
 
GESignaHeaderimageHeader
 
svkEnhancedMRIIODiod
 
- Protected Attributes inherited from svkImageReader2
vtkDataArray * dataArray
 
bool readOneInputFile
 
bool onlyGlobFiles
 
bool onlyReadHeader
 

Additional Inherited Members

- Public Types inherited from svkImageReader2
enum  ReaderType {
  UNDEFINED = -1, DICOM_MRS =0, DICOM_MRI, DICOM_ENHANCED_MRI,
  DICOM_SEGMENTATION, DICOM_RAW, SIEMENS_RDA, VARIAN_FID,
  VARIAN_FDF, GE_PFILE, GE_SDBM, GE_POSTAGE_STAMP,
  GE_SIGNA_LX2, GE_SIGNA_5X, LC_MODEL_COORD, LC_MODEL_CSV,
  LC_MODEL_TABLE, VARIABLE_FLIP_DAT, BRUKER_MRS, PHILIPS_S,
  DDF, IDF, LAST_TYPE = IDF
}
 

Detailed Description

This is a SIVIC reader for GE Genesis *.MR Signa 5X files. This class parses a GE MR header to initialize an svkMriImageData object with an svkDcmHeader corresponding to a DICOM Enhanced MRI Storage SOP class (SOP Class UID: 1.2.840.10008.5.1.4.1.1.4).

The ITK itkGE5ImageIO.cxx and VTK vtkGESignaReader.cxx files were used as guides when creating this class. The CopyGenesisImage method is the vtkcopygenesisimage function from vtkGESignaReader.cxx

Constructor & Destructor Documentation

svkGESigna5XReader ( )
protected
~svkGESigna5XReader ( )
protected

Member Function Documentation

bool CalculateTopLeftHandCornerAndRowColumnAndNormalVectors ( GESignaHeader hdr,
double  tlhc[3],
double  row[3],
double  column[3],
double  normal[3] 
)
protected
int CanReadFile ( const char *  fname)
virtual

Reimplemented in svkGESignaLX2Reader.

References GE_SIGNA_5X_MAGIC_NUMBER.

bool CopyGenesisImage ( FILE *  infp,
int  width,
int  height,
int  compress,
short *  map_left,
short *  map_wide,
unsigned short *  output 
)
protected
void ExecuteDataWithInformation ( vtkDataObject *  output,
vtkInformation *  outInfo 
)
protectedvirtual

Side effect of Update() method. Used to load pixel data and initialize vtkImageData Called after ExecuteInformation()

References svkGESigna5XReader::LoadData().

void ExecuteInformation ( )
protectedvirtual
int FillOutputPortInformation ( int  port,
vtkInformation *  info 
)
protectedvirtual

Reimplemented from svkImageReader2.

virtual const char* GetDescriptiveName ( )
inlinevirtual

Reimplemented in svkGESignaLX2Reader.

virtual const char* GetFileExtensions ( )
inlinevirtual

Reimplemented in svkGESignaLX2Reader.

svkDcmHeader::DcmPixelDataFormat GetFileType ( )
protectedvirtual

Returns the file root without extension

Implements svkImageReader2.

References svkDcmHeader::UNSIGNED_INT_2.

virtual svkImageReader2::ReaderType GetReaderType ( )
inlinevirtual

Implements svkImageReader2.

Reimplemented in svkGESignaLX2Reader.

References svkImageReader2::GE_SIGNA_5X.

void InitDcmHeader ( )
protectedvirtual
void InitEnhancedGeneralEquipmentModule ( )
protected
void InitEnhancedMRImageModule ( )
protected
void InitGeneralEquipmentModule ( )
protected
void InitGeneralSeriesModule ( )
protected
void InitGeneralStudyModule ( )
protected
void InitMRAveragesMacro ( )
protected
void InitMREchoMacro ( )
protected
void InitMRFOVGeometryMacro ( )
protected
void InitMRImageAndSpectroscopyInstanceMacro ( )
protected
void InitMRImageFrameTypeMacro ( )
protected
void InitMRImagingModifierMacro ( )
protected
void InitMRModifierMacro ( )
protected
void InitMRPulseSequenceModule ( )
protected
void InitMRReceiveCoilMacro ( )
protected

Should work for single vs multi-coil, but will not currently differentiate between volume, surface, body coils

References svkDcmHeader::AddSequenceItemElement(), svkImageData::GetDcmHeader(), svkImageReader2::GetOutput(), svkGESigna5XReader::imageHeader, and GESignaHeader::MR_Receive_Coil_Name.

Referenced by svkGESigna5XReader::InitSharedFunctionalGroupMacros().

void InitMRTimingAndRelatedParametersMacro ( )
protected
void InitMRTransmitCoilMacro ( )
protected
void InitMultiFrameFunctionalGroupsModule ( )
protected
void InitPatientModule ( )
protected
void InitPerFrameFunctionalGroupMacros ( )
protected
void InitPixelMeasuresMacro ( )
protected
void InitPixelValueTransformationMacro ( )
protected
void InitPlaneOrientationMacro ( )
protected
void InitSharedFunctionalGroupMacros ( )
protected
bool LoadData ( const char *  filename,
unsigned short *  outPtr,
int *  outExt,
vtkIdType *   
)
protected
static svkGESigna5XReader* New ( )
static
GESignaHeader * ReadHeader ( const char *  FileNameToRead)
protectedvirtual

Reimplemented in svkGESignaLX2Reader.

References GEImageMainHeader::Background_Shade, GEImageMainHeader::Bottom_Offset, GEImageMainHeader::Checksum, GEImageMainHeader::Compressed, GEImageMainHeader::Depth, GEImageMainHeader::Dlevel, GEImageMainHeader::Dwindow, GESignaHeader::Exam_Description, GESignaHeader::Exam_Hospital_Name, GESignaHeader::Exam_Magnet_Strength, GESignaHeader::Exam_Number, GESignaHeader::Exam_Operator, GESignaHeader::Exam_Patient_Age, GESignaHeader::Exam_Patient_Age_Notation, GESignaHeader::Exam_Patient_History, GESignaHeader::Exam_Patient_ID, GESignaHeader::Exam_Patient_Name, GESignaHeader::Exam_Patient_Sex, GESignaHeader::Exam_Patient_Weight_In_Grams, GESignaHeader::Exam_Radiologist, GESignaHeader::Exam_Referring_Physician, GESignaHeader::Exam_Requisition_Number, GESignaHeader::Exam_Software_Version, GESignaHeader::Exam_System_ID, GESignaHeader::Exam_Time_Stamp, GESignaHeader::Exam_Time_Stamp_Date, GESignaHeader::Exam_Time_Stamp_Time, GESignaHeader::Exam_Type, GESignaHeader::Exam_Unique_System_ID, GE_SIGNA_5X_MAGIC_NUMBER, GE_VERSION_FIX, GEImageMainHeader::Header_Length, GEImageMainHeader::Height, GEImageMainHeader::Length_Compress, GEImageMainHeader::Length_DBHeader, GEImageMainHeader::Length_Exam, GEImageMainHeader::Length_Graphics, GEImageMainHeader::Length_Histogram, GEImageMainHeader::Length_ID, GEImageMainHeader::Length_Image, GEImageMainHeader::Length_Series, GEImageMainHeader::Length_Suite, GEImageMainHeader::Length_Text, GEImageMainHeader::Length_Unpack, GEImageMainHeader::Length_User, GEImageMainHeader::Level_Offset, GEImageMainHeader::Magic_Number, GESignaHeader::mainHeader, GESignaHeader::MR_A_Bottom_Right_Corner, GESignaHeader::MR_A_Normal, GESignaHeader::MR_A_Top_Left_Corner, GESignaHeader::MR_A_Top_Right_Corner, GESignaHeader::MR_Average_SAR, GESignaHeader::MR_Bitmap_Of_Saturation_Selections, GESignaHeader::MR_Cardiac_Heart_Rate, GESignaHeader::MR_Center_Frequency, GESignaHeader::MR_Echo_Number, GESignaHeader::MR_Echo_Train_Length, GESignaHeader::MR_Fat_Water_SAT, GESignaHeader::MR_Flip_Angle, GESignaHeader::MR_FOV_X, GESignaHeader::MR_FOV_Y, GESignaHeader::MR_Fractional_Echo_Flag, GESignaHeader::MR_Frequency_Direction, GESignaHeader::MR_Image_Contrast_Mode, GESignaHeader::MR_Image_Dimension_X, GESignaHeader::MR_Image_Dimension_Y, GESignaHeader::MR_Image_Location, GESignaHeader::MR_Image_Matrix_Size_X, GESignaHeader::MR_Image_Matrix_Size_Y, GESignaHeader::MR_Image_Number, GESignaHeader::MR_Image_Pixel_Size_X, GESignaHeader::MR_Image_Pixel_Size_Y, GESignaHeader::MR_Image_Type, GESignaHeader::MR_Images_Per_Cardiac_Cycle, GESignaHeader::MR_Imaging_Mode, GESignaHeader::MR_Imaging_Options, GESignaHeader::MR_IV_Contrast_Agent, GESignaHeader::MR_Number_Of_Averages, GESignaHeader::MR_Number_Of_Echoes, GESignaHeader::MR_Number_Of_Slices, GESignaHeader::MR_Oral_Contrast_Agent, GESignaHeader::MR_Plane_Type, GESignaHeader::MR_Preparatory_Pulse_Option, GESignaHeader::MR_Projection_Algorithm, GESignaHeader::MR_Pulse_Echo_Time, GESignaHeader::MR_Pulse_Inversion_Time, GESignaHeader::MR_Pulse_Repetition_Time, GESignaHeader::MR_Pulse_Sequence, GESignaHeader::MR_Pulse_Sequence_Name, GESignaHeader::MR_R_Bottom_Right_Corner, GESignaHeader::MR_R_Normal, GESignaHeader::MR_R_Top_Left_Corner, GESignaHeader::MR_R_Top_Right_Corner, GESignaHeader::MR_Raw_Data_Run_Number, GESignaHeader::MR_Receive_Coil_Name, GESignaHeader::MR_S_Bottom_Right_Corner, GESignaHeader::MR_S_Normal, GESignaHeader::MR_S_Top_Left_Corner, GESignaHeader::MR_S_Top_Right_Corner, GESignaHeader::MR_Scan_Duration, GESignaHeader::MR_Slice_Spacing, GESignaHeader::MR_Slice_Thickness, GESignaHeader::MR_Surface_Coil_Intensity_Correction, GESignaHeader::MR_Time_Stamp, GESignaHeader::MR_Time_Stamp_Date, GESignaHeader::MR_Time_Stamp_Time, GESignaHeader::MR_Timestamp_Of_Last_Change, GESignaHeader::MR_Timestamp_Of_Last_Change_Date, GESignaHeader::MR_Timestamp_Of_Last_Change_Time, GESignaHeader::MR_Trigger_Window, GESignaHeader::MR_Variable_Bandwidth, GESignaHeader::MR_Vascular_Collapse, GEImageMainHeader::Overflow, GEImageMainHeader::Pointer_Compress, GEImageMainHeader::Pointer_DBHeader, GEImageMainHeader::Pointer_Exam, GEImageMainHeader::Pointer_Graphics, GEImageMainHeader::Pointer_Histogram, GEImageMainHeader::Pointer_ID, GEImageMainHeader::Pointer_Image, GEImageMainHeader::Pointer_Series, GEImageMainHeader::Pointer_Suite, GEImageMainHeader::Pointer_Text, GEImageMainHeader::Pointer_Unpack, GEImageMainHeader::Pointer_User, GESignaHeader::Series_Description, GESignaHeader::Series_Number, GESignaHeader::Series_Patient_Entry, GESignaHeader::Series_Patient_Position, GESignaHeader::Series_Scan_Potocol_Name, GESignaHeader::Series_Time_Stamp, GESignaHeader::Series_Time_Stamp_Date, GESignaHeader::Series_Time_Stamp_Time, GESignaHeader::Series_Type, svkGESigna5XReader::statTimeAndDateToAscii(), GESignaHeader::Suite_Product_ID, GEImageMainHeader::Top_Offset, GEImageMainHeader::Underflow, GEImageMainHeader::Version, and GEImageMainHeader::Width.

Referenced by svkGESigna5XReader::InitDcmHeader(), svkGESigna5XReader::InitPerFrameFunctionalGroupMacros(), and svkGESigna5XReader::SortFilesByImagePositionPatient().

bool SortFilesByImagePositionPatient ( GESignaHeader selectedFile,
vtkStringArray *  fileNames,
bool  ascending 
)
protected

Sort the list of files in either ascending or descending order by ImagePositionPatient and Series ID. If the Series ID is not the same as the input, the file is removed from the list. Also return true if this is a multi-volume series.

References svkGESigna5XReader::CalculateTopLeftHandCornerAndRowColumnAndNormalVectors(), GESignaHeader::Exam_Number, svkGESigna5XReader::ReadHeader(), and GESignaHeader::Series_Number.

Referenced by svkGESigna5XReader::InitDcmHeader().

void statTimeAndDateToAscii ( void *  clock,
char *  time,
char *  date 
)
protected
vtkTypeMacro ( svkGESigna5XReader  ,
svkImageReader2   
)

Member Data Documentation

svkDcmHeader::DcmDataOrderingDirection dataSliceOrder
protected
GESignaHeader* imageHeader
protected
svkEnhancedMRIIOD* iod
protected
int numFrames
protected

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