32#ifndef itkIPLCommonImageIO_h
33#define itkIPLCommonImageIO_h
34#include "ITKIOIPLExport.h"
61 using U8 =
unsigned char;
62 using S8 =
signed char;
63 using U16 =
unsigned short;
65 using U32 =
unsigned int;
126 Write(
const void * buffer)
override;
144 const float sliceLocation,
169 IPLFileNameList * m_FilenameList{};
173 GetStringAt(std::ifstream & f, std::streamoff
Offset,
char * buf,
size_t amount,
bool throw_exception =
true);
176 GetIntAt(std::ifstream & f, std::streamoff
Offset,
int * ip,
bool throw_exception =
true);
179 GetShortAt(std::ifstream & f, std::streamoff
Offset,
short * ip,
bool throw_exception =
true);
182 GetFloatAt(std::ifstream & f, std::streamoff
Offset,
float * ip,
bool throw_exception =
true);
185 GetDoubleAt(std::ifstream & f, std::streamoff
Offset,
double * ip,
bool throw_exception =
true);
200#define RAISE_EXCEPTION() \
202 ExceptionObject exception(__FILE__, __LINE__); \
203 exception.SetDescription("File cannot be read"); \
206 ITK_MACROEND_NOOP_STATEMENT
217 ITK_MACROEND_NOOP_STATEMENT
Class that defines how to read GE4 file format.
void WriteImageInformation() override
short hdr2Short(char *hdr)
int statTimeToAscii(void *clock, char *timeString, int len)
void Read(void *buffer) override
int AddElementToList(char const *const filename, const float sliceLocation, const int offset, const int XDim, const int YDim, const float XRes, const float YRes, const int Key1, const int Key2)
void sortImageListAscend()
int GetShortAt(std::ifstream &f, std::streamoff Offset, short *ip, bool throw_exception=true)
float hdr2Float(char *hdr)
bool CanWriteFile(const char *FileNameToWrite) override
void PrintSelf(std::ostream &os, Indent indent) const override
int GetIntAt(std::ifstream &f, std::streamoff Offset, int *ip, bool throw_exception=true)
virtual void SortImageListByNameAscend()
void sortImageListDescend()
virtual GEImageHeader * ReadHeader(const char *FileNameToRead)
double hdr2Double(char *hdr)
int GetStringAt(std::ifstream &f, std::streamoff Offset, char *buf, vcl_size_t amount, bool throw_exception=true)
bool CanReadFile(const char *FileNameToRead) override
void Write(const void *buffer) override
unsigned int GetComponentSize() const override
virtual void ModifyImageInformation()
virtual void SortImageListByNameDescend()
int GetFloatAt(std::ifstream &f, std::streamoff Offset, float *ip, bool throw_exception=true)
void ReadImageInformation() override
~IPLCommonImageIO() override
int GetDoubleAt(std::ifstream &f, std::streamoff Offset, double *ip, bool throw_exception=true)
Abstract superclass defines image IO interface.
Control indentation during Print() invocation.
Light weight base class for most itk classes.
Base class for most ITK classes.
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Represent a n-dimensional offset between two n-dimensional indexes of n-dimensional image.