X-Git-Url: http://git.kpe.io/?p=ctsim.git;a=blobdiff_plain;f=include%2Fctndicom.h;h=7817ab46c328beba14a6bdf4e4650eda9c4e84a3;hp=701434b0e0542628040616ae7bd913f78c622733;hb=8a7697ce57b56cdc43698cd1241ad98d49f9b5ac;hpb=505de7e90b7c4a6ab3e81ee3192a7d9837701806 diff --git a/include/ctndicom.h b/include/ctndicom.h index 701434b..7817ab4 100644 --- a/include/ctndicom.h +++ b/include/ctndicom.h @@ -9,7 +9,7 @@ ** This is part of the CTSim program ** Copyright (c) 1983-2001 Kevin Rosenberg ** -** $Id: ctndicom.h,v 1.2 2001/03/02 02:08:14 kevin Exp $ +** $Id$ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -29,13 +29,42 @@ #define _CTNDICOM_H_ #if HAVE_CTN_DICOM -#include +#include +#include +#include +#ifdef GCCSUNOS +#include +#endif + +#include "ctsupport.h" + +#if SIZEOF_LONG == 4 +#define LONGSIZE 32 +#elif SIZEOF_LONG ==8 +#define LONGSIZE 64 +#endif + +#if SIZEOF_INT == 2 +#define INTSIZE 16 +#elif SIZEOF_INT == 4 +#define INTSIZE 32 +#elif SIZEOF_INT == 8 +#define INTSIZE 64 +#endif + +#if SIZEOF_SHORT == 2 +#define SHORTSIZE 16 +#elif SIZEOF_SHORT == 4 +#define SHORTSIZE 32 +#endif -#include "dicom.h" -#include "condition.h" -#include "lst.h" -#include "dicom_objects.h" +#include "dicom.h" +#include "ctnthread.h" +#include "lst.h" +#include "condition.h" +#include "dicom_objects.h" +#include class ImageFile; class Projections; @@ -78,5 +107,26 @@ public: Projections* getProjections() const {return m_pProjections;} }; + +class DicomExporter { +private: + const ImageFile* m_pImageFile; + std::string m_strFilename; + bool m_bFail; + std::string m_strFailMessage; + DCM_OBJECT* m_pObject; + + bool createDicomObject(); + +public: + + DicomExporter (ImageFile* pImageFile); + ~DicomExporter(); + + bool writeFile (const char* const pszFilename); + bool fail() const {return m_bFail;} + const std::string& failMessage() const {return m_strFailMessage;} +}; + #endif // HAVE_CTN_DICOM #endif // _CTNDICOM_H_