MrSID Decode SDK for Raster Reference Manual  9.0.0.3864
MrSIDImageStageManager.h
Go to the documentation of this file.
1 /* $Id$ */
2 /* //////////////////////////////////////////////////////////////////////////
3 // //
4 // This code is Copyright (c) 2004 LizardTech, Inc, 1008 Western Avenue, //
5 // Suite 200, Seattle, WA 98104. Unauthorized use or distribution //
6 // prohibited. Access to and use of this code is permitted only under //
7 // license from LizardTech, Inc. Portions of the code are protected by //
8 // US and foreign patents and other filings. All Rights Reserved. //
9 // //
11 /* PUBLIC */
12 
13 #ifndef __MRSID_IMAGE_STAGE_MANAGER_H__
14 #define __MRSID_IMAGE_STAGE_MANAGER_H__
15 
16 // lt_lib_mrsid_core
17 #include "lti_imageStageManager.h"
18 #include "MrSIDImageReaderBase.h"
19 
20 LT_BEGIN_NAMESPACE(LizardTech)
21 
22 class MG3Container;
23 class MG3SingleImageReader;
24 class MG4SingleImageReader;
25 class MG2ImageReader;
26 
28 {
30 public:
38  LT_STATUS initialize(const LTFileSpec &fileSpec,
41 
49  LT_STATUS initialize(LTIOStreamInf *stream,
52 
53  // LTIImageStageManager overrides
54  LT_STATUS createImageStage(lt_uint32 imageNumber,
55  LTIImageStage *&imageStage);
56  LT_STATUS createOverviewImageStage(LTIImageStage *&imageStage);
57 
58  LT_STATUS createImageStage(lt_uint32 imageNumber,
59  MrSIDSingleImageReaderBase *&imageStage);
60  LT_STATUS createOverviewImageStage(MrSIDSingleImageReaderBase *&imageStage);
61 
62  LT_STATUS getMrSIDVersion(lt_uint8& major, lt_uint8& minor,
63  lt_uint8& tweak, char& letter) const;
64 
65  void setMaxWorkerThreads(int numThreads);
66  int getMaxWorkerThreads(void) const;
67 
68  // for LizardTech internal use only
69  MrSIDMemoryUsage getMemoryUsage(void) const;
70  // for LizardTech internal use only
71  MrSIDStreamUsage getStreamUsage(void) const;
72 
73  // for LizardTech internal use only
74  bool hasMG2Tiles(void) const;
75  // for LizardTech internal use only
76  bool hasMG3Tiles(void) const;
77  // for LizardTech internal use only
78  bool hasMG4Tiles(void) const;
79  // for LizardTech internal use only
80  bool isOptimizable(void) const;
81  // for LizardTech internal use only
82  bool hasOverviewImage(void) const;
83 
84  // for LizardTech internal use only
89  {
90  COMPOSITETYPE_MG2 = 1,
91  COMPOSITETYPE_MG3 = 2,
92  COMPOSITETYPE_MG4 = 3,
93  };
94 
95  // for LizardTech internal use only
96  struct TileInfo
97  {
98  //lt_uint32 imageNumber;
101 
103  bool isLocked;
105 
107  //LTIGeoCoord geoCoord;
108  };
109 
110  // for LizardTech internal use only
111  const TileInfo *getTileInfo(lt_uint32 index) const;
112  // for LizardTech internal use only
113  const TileInfo *getOverviewInfo() const;
114  // for LizardTech internal use only
115  lt_uint32 findTileId(lt_uint32 id) const;
116 
117  // for LizardTech internal use only
118  const MG3Container *getContainer(void) const;
119 
120  // for LizardTech internal use only
121  void treatMG3asMG4(void);
122 protected:
123  LT_STATUS init(lt_uint32 numImages,
124  MrSIDMemoryUsage memoryUsage,
125  MrSIDStreamUsage streamUsage);
126 
127  virtual LT_STATUS updateMemoryModel();
128  virtual LT_STATUS createMG2Reader(lt_uint32 imageNumber,
129  MG2ImageReader *&mg2Reader);
130  virtual LT_STATUS createMG3Reader(lt_uint32 imageNumber,
131  MG3SingleImageReader *&mg3Reader);
132  virtual LT_STATUS createMG4Reader(lt_uint32 imageNumber,
133  MG4SingleImageReader *&mg4Reader);
134 
137 
143  char m_letter;
144  MG3Container *m_container;
151 };
152 
153 
154 LT_END_NAMESPACE(LizardTech)
155 
156 
157 #endif // __MRSID_IMAGE_STAGE_MANAGER_H__

LizardTech