00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef GDCMTS_H
00020 #define GDCMTS_H
00021
00022 #include "gdcmRefCounter.h"
00023
00024 #include <map>
00025 #include <string>
00026 #include <iostream>
00027
00028 namespace gdcm
00029 {
00030
00031 typedef std::string TSKey;
00032 typedef std::string TSAtr;
00033 typedef std::map<TSKey, TSAtr> TSHT;
00034
00035
00036
00041 class GDCM_EXPORT TS : public RefCounter
00042 {
00043 gdcmTypeMacro(TS);
00044
00045 public:
00046 enum SpecialType {
00047 ImplicitVRLittleEndian = 0,
00048 ImplicitVRBigEndianPrivateGE,
00049 ExplicitVRLittleEndian,
00050 DeflatedExplicitVRLittleEndian,
00051 ExplicitVRBigEndian,
00052 JPEGBaselineProcess1,
00053 JPEGExtendedProcess2_4,
00054 JPEGExtendedProcess3_5,
00055 JPEGSpectralSelectionProcess6_8,
00056 JPEGFullProgressionProcess10_12,
00057 JPEGLosslessProcess14,
00058 JPEGLosslessProcess14_1,
00059 JPEGLSLossless,
00060 JPEGLSNearLossless,
00061 JPEG2000Lossless,
00062 JPEG2000,
00063 RLELossless,
00064 MPEG2MainProfile,
00065 UnknownTS
00066 };
00067
00068 public:
00070 static TS *New() {return new TS();}
00071
00072 virtual void Print(std::ostream &os = std::cout,
00073 std::string const & = "" );
00074
00075 int Count(TSKey const &key);
00076 TSAtr const &GetValue(TSKey const &key);
00077 bool IsTransferSyntax(TSKey const &key);
00078 bool IsRLELossless(TSKey const &key);
00079 bool IsJPEGLossless(TSKey const&key);
00080 bool IsJPEGLossy(TSKey const&key);
00081 bool IsJPEG2000(TSKey const &key);
00082 bool IsJPEG(TSKey const &key);
00083 bool IsJPEGLS(TSKey const &key);
00084 bool IsMPEG(TSKey const &key);
00085
00086
00087 SpecialType GetSpecialTransferSyntax(TSKey const &key);
00088 const char* GetSpecialTransferSyntax(SpecialType t);
00089
00090 protected:
00091 TS();
00092 ~TS();
00093
00094 private:
00095 TSHT TsMap;
00096 };
00097 }
00098
00099
00100 #endif