MrSID Decode SDK for Raster Reference Manual  9.5.1.4427
NITFReaderManager.h
Go to the documentation of this file.
1 /* //////////////////////////////////////////////////////////////////////////
2 // //
3 // This code is Copyright (c) 2010 LizardTech, Inc, 1008 Western Avenue, //
4 // Suite 200, Seattle, WA 98104. Unauthorized use or distribution //
5 // prohibited. Access to and use of this code is permitted only under //
6 // license from LizardTech, Inc. Portions of the code are protected by //
7 // US and foreign patents and other filings. All Rights Reserved. //
8 // //
10 /* PUBLIC */
11 
12 #ifndef NITFReaderManager_H
13 #define NITFReaderManager_H
14 
15 // lt_lib_base
16 #include "lt_base.h"
17 
18 // lt_lib_mrsid_core
19 #include "lti_geoImageReader.h"
20 #include "lti_imageStageManager.h"
21 
23 class LTFileSpec;
24 class LTIOStreamInf;
25 
26 namespace Nitf
27 {
28  class ImageReader;
29  class FileHeader;
30  class ImageSegment;
31  class GraphicSegment;
32  class LabelSegment;
33  class TextSegment;
34  class DataSegment;
35  class ReservedSegment;
36  class FileMetadata;
37  class SecurityMetadata;
38 }
39 
40 
54 {
56 public:
66  LT_STATUS initialize(const LTFileSpec& fileSpec, bool useWorldFile=true);
67 
75  LT_STATUS initialize(LTIOStreamInf *stream);
76 
90  LT_STATUS createReader(Nitf::ImageReader*& reader, lt_uint32 idx);
91 
107  LT_STATUS createImageStage(lt_uint32 imageNumber,
108  LTIImageStage *&imageStage);
109 
125  void setCompat_2500B_N2(bool use2500B);
126 
135  bool getCompat_2500B_N2() const;
136 
137  lt_int64 getFileSize() const;
138 
142  const Nitf::FileHeader* getFileHeader() const;
143 
147  lt_uint32 getNumImageSegments() const;
148 
159  const Nitf::ImageSegment* getImageSegment(lt_uint32 num) const;
160 
164  const char* getImageSegmentIID1(lt_uint32 num) const;
165 
169  lt_uint32 getNumGraphicSegments() const;
170 
179  const Nitf::GraphicSegment* getGraphicSegment(lt_uint32 num) const;
180 
184  lt_uint32 getNumLabelSegments() const;
185 
194  const Nitf::LabelSegment* getLabelSegment(lt_uint32 num) const;
195 
199  lt_uint32 getNumTextSegments() const;
200 
209  const Nitf::TextSegment* getTextSegment(lt_uint32 num) const;
210 
214  lt_uint32 getNumDataSegments() const;
215 
224  const Nitf::DataSegment* getDataSegment(lt_uint32 num) const;
225 
229  lt_uint32 getNumResSegments() const;
230 
239  const Nitf::ReservedSegment* getResSegment(lt_uint32 num) const;
240 
244  const char* getVersionString() const;
245 
249  const Nitf::FileMetadata* getFileMetadata() const;
250 
254  const Nitf::SecurityMetadata* getSecurityMetadata() const;
255 
256  // not for public use
257  LTFileSpec* getFileSpec() const;
258 
259 private:
260  LT_STATUS fixMetadata(LTIImageStage *mos);
261 
262  LTFileSpec *m_fileSpec;
263  LTIOStreamInf *m_stream;
264  bool m_ownStream;
265  lt_int64 m_fileSize;
266  bool m_useWorldFile;
267 
268  Nitf::FileHeader* m_fileHeader;
269  Nitf::ImageSegment** m_imageSegments;
270  Nitf::GraphicSegment** m_graphicSegments;
271  Nitf::LabelSegment** m_labelSegments;
272  Nitf::TextSegment** m_textSegments;
273  Nitf::DataSegment** m_dataSegments;
274  Nitf::ReservedSegment** m_resSegments;
275  lt_uint32 m_numImageSegments;
276  lt_uint32 m_numGraphicSegments;
277  lt_uint32 m_numLabelSegments;
278  lt_uint32 m_numTextSegments;
279  lt_uint32 m_numDataSegments;
280  lt_uint32 m_numResSegments;
281 
282  char* m_versionString;
283 
284  bool m_compat_2500B_N2;
285 };
286 
287 
289 
290 #endif // NITFReaderManager_H
represents a text segment in an NITF file
Definition: TextSegment.h:36
container for Security metadata
represents the file header properties of a NITF file
Definition: FileHeader.h:41
#define LT_BEGIN_LIZARDTECH_NAMESPACE
compiler does not support namespaces
Definition: lt_define.h:96
Include file for all LizardTech sources.
represents a graphic segment in an existing NITF file
lt_uint32 LT_STATUS
An integral status code.
Definition: lt_status.h:39
Abstract definition of a stream.
Represents a file or directory path.
Definition: lt_fileSpec.h:33
represents a data segment in an existing NITF file
Definition: DataSegment.h:34
abstract class for managing a list of image stages
class for reading an NITF file
represents a image segment in an existing NITF file
Definition: ImageSegment.h:44
#define LT_END_LIZARDTECH_NAMESPACE
compiler does not support namespaces
Definition: lt_define.h:97
represents a Reserved segment in an NITF file
represents a label segment in an existing NITF file
Definition: LabelSegment.h:34
abstract class for decoding from an image
#define LTI_REFERENCE_COUNTED_BOILERPLATE(classname)
unsigned int lt_uint32
unsigned 32-bit integer
Definition: lt_types.h:54
class for representing an NITF image segment as an LTIImageReader
Definition: ImageReader.h:46
container for File Header metadata
Definition: FileMetadata.h:38

LizardTech