00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef GDCMJPEGFRAGMENTSINFO_H
00021 #define GDCMJPEGFRAGMENTSINFO_H
00022
00023 #include "gdcmJPEGFragment.h"
00024
00025 #include <list>
00026 #include <iostream>
00027
00028 namespace gdcm
00029 {
00040 class GDCM_EXPORT JPEGFragmentsInfo
00041 {
00042 public:
00043 JPEGFragmentsInfo();
00044 ~JPEGFragmentsInfo();
00045 void Print( std::ostream &os = std::cout, std::string const &indent = "" );
00046
00047 void DecompressFromFile(std::ifstream *fp, uint8_t *buffer, int nBits,
00048 int numBytes, int length);
00049
00050 void AddFragment(JPEGFragment *fragment);
00051 JPEGFragment *GetFirstFragment();
00052 JPEGFragment *GetNextFragment();
00053 unsigned int GetFragmentCount();
00054
00055 private:
00056 typedef std::list<JPEGFragment *> JPEGFragmentsList;
00057
00058
00059 int StateSuspension;
00060 void *SampBuffer;
00061 char *pimage;
00062 JPEGFragmentsList Fragments;
00063 JPEGFragmentsList::iterator ItFragments;
00064 };
00065 }
00066
00067
00068 #endif
00069