MrSID Decode SDK for LiDAR Reference Manual
1.1.4.4709
|
00001 /* ////////////////////////////////////////////////////////////////////////// 00002 // // 00003 // This code is Copyright (c) 2008-2010 LizardTech, Inc, 1008 Western // 00004 // Avenue, Suite 200, Seattle, WA 98104. Unauthorized use or distribution // 00005 // prohibited. Access to and use of this code is permitted only under // 00006 // license from LizardTech, Inc. Portions of the code are protected by // 00007 // US and foreign patents and other filings. All Rights Reserved. // 00008 // // 00010 /* PUBLIC */ 00011 00012 #ifndef __LIDAR_TXT_POINT_READER_H__ 00013 #define __LIDAR_TXT_POINT_READER_H__ 00014 00015 #include "lidar/PointReader.h" 00016 #include "lidar/IO.h" 00017 00018 LT_BEGIN_LIDAR_NAMESPACE 00019 00026 class TXTPointReader : public PointReader 00027 { 00028 CONCRETE_OBJECT(TXTPointReader); 00029 public: 00030 00042 void init(const char *path, const char *format, 00043 size_t header, bool doFullInit); 00055 void init(IO *io, const char *format, 00056 size_t header, bool doFullInit); 00057 00070 void init(const char *path, const PointInfo &fieldInfo, 00071 size_t header, bool doFullInit); 00084 void init(IO *io, const PointInfo &fieldInfo, 00085 size_t header, bool doFullInit); 00086 00095 void initBoundsAndNumPoints(void); 00096 00097 const char *getFileFormatString(void) const; 00098 00099 void loadMetadata(Metadata &metadata, bool sanitize) const; 00100 00101 double getTotalWork(const Bounds &bounds, double fraction) const; 00102 00103 PointIterator *createIterator(const Bounds &bounds, 00104 double fraction, 00105 const PointInfo &pointInfo, 00106 ProgressDelegate *delegate) const; 00107 00136 static void parseFormat(const char *format, 00137 PointInfo &fieldInfo); 00148 static void parseFormat(const char *format, 00149 PointInfo &fieldInfo, 00150 const PointInfo &pointInfo); 00151 00178 static void parseQuantization(const char *format, 00179 PointInfo &fieldInfo); 00180 00181 00182 protected: 00183 void setBoundsAndNumPoints(bool doFullInit); 00184 00185 IO *m_io; 00186 size_t m_header; 00187 PointInfo m_fieldInfo; 00188 double m_totalWork; 00189 00190 class Iterator; 00191 }; 00192 00193 LT_END_LIDAR_NAMESPACE 00194 #endif // __LIDAR_TXT_POINT_READER_H__