ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
E57Format.h
Go to the documentation of this file.
1 /*
2  * E57Format.h - public header of E57 API for reading/writing .e57 files.
3  *
4  * Original work Copyright 2009 - 2010 Kevin Ackley (kackley@gwi.net)
5  * Modified work Copyright 2018 - 2020 Andy Maloney <asmaloney@gmail.com>
6  *
7  * Permission is hereby granted, free of charge, to any person or organization
8  * obtaining a copy of the software and accompanying documentation covered by
9  * this license (the "Software") to use, reproduce, display, distribute,
10  * execute, and transmit the Software, and to prepare derivative works of the
11  * Software, and to permit third-parties to whom the Software is furnished to
12  * do so, all subject to the following:
13  *
14  * The copyright notices in the Software and this entire statement, including
15  * the above license grant, this restriction and the following disclaimer,
16  * must be included in all copies of the Software, in whole or in part, and
17  * all derivative works of the Software, unless such copies or derivative
18  * works are solely in the form of machine-executable object code generated by
19  * a source language processor.
20  *
21  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23  * FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
24  * SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
25  * FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
26  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
27  * DEALINGS IN THE SOFTWARE.
28  */
29 
30 #pragma once
31 
33 
34 #include <cfloat>
35 #include <cstdint>
36 #include <memory>
37 #include <vector>
38 
39 #include "E57Exception.h"
40 
41 namespace e57
42 {
43  using std::int16_t;
44  using std::int32_t;
45  using std::int64_t;
46  using std::int8_t;
47  using std::uint16_t;
48  using std::uint32_t;
49  using std::uint64_t;
50  using std::uint8_t;
51 
52  // Shorthand for unicode string
54  using ustring = std::string;
55 
57  enum NodeType
58  {
60  E57_VECTOR = 2,
64  E57_FLOAT = 6,
65  E57_STRING = 7,
66  E57_BLOB = 8
67  };
68 
71  {
72  E57_SINGLE = 1,
73  E57_DOUBLE = 2
74  };
75 
79  {
80  E57_INT8 = 1,
81  E57_UINT8 = 2,
82  E57_INT16 = 3,
83  E57_UINT16 = 4,
84  E57_INT32 = 5,
85  E57_UINT32 = 6,
86  E57_INT64 = 7,
87  E57_BOOL = 8,
88  E57_REAL32 = 9,
89  E57_REAL64 = 10,
90  E57_USTRING = 11
91  };
92 
95  using ReadChecksumPolicy = int;
96 
99  25;
101  50;
103 
107  constexpr char E57_V1_0_URI[] = "http://www.astm.org/COMMIT/E57/2010-e57-v1.0";
108 
110  // Minimum and maximum values for integers
111  constexpr int8_t E57_INT8_MIN = -128;
112  constexpr int8_t E57_INT8_MAX = 127;
113  constexpr int16_t E57_INT16_MIN = -32768;
114  constexpr int16_t E57_INT16_MAX = 32767;
115  constexpr int32_t E57_INT32_MIN = -2147483647 - 1;
116  constexpr int32_t E57_INT32_MAX = 2147483647;
117  constexpr int64_t E57_INT64_MIN = -9223372036854775807LL - 1;
118  constexpr int64_t E57_INT64_MAX = 9223372036854775807LL;
119  constexpr uint8_t E57_UINT8_MIN = 0U;
120  constexpr uint8_t E57_UINT8_MAX = 0xffU; /* 255U */
121  constexpr uint16_t E57_UINT16_MIN = 0U;
122  constexpr uint16_t E57_UINT16_MAX = 0xffffU; /* 65535U */
123  constexpr uint32_t E57_UINT32_MIN = 0U;
124  constexpr uint32_t E57_UINT32_MAX = 0xffffffffU; /* 4294967295U */
125  constexpr uint64_t E57_UINT64_MIN = 0ULL;
126  constexpr uint64_t E57_UINT64_MAX = 0xffffffffffffffffULL; /* 18446744073709551615ULL */
127 
128  constexpr float E57_FLOAT_MIN = -FLT_MAX;
129  constexpr float E57_FLOAT_MAX = FLT_MAX;
130  constexpr double E57_DOUBLE_MIN = -DBL_MAX;
131  constexpr double E57_DOUBLE_MAX = DBL_MAX;
133 
136 // Internal implementation files should include E57FormatImpl.h first which
137 // defines symbol E57_INTERNAL_IMPLEMENTATION_ENABLE. Normal API users should
138 // not define this symbol. Basically the internal version allows access to the
139 // pointer to the implementation (impl_)
140 #ifdef E57_INTERNAL_IMPLEMENTATION_ENABLE
141 #define E57_OBJECT_IMPLEMENTATION( T ) \
142 public: \
143  std::shared_ptr<T##Impl> impl() const \
144  { \
145  return ( impl_ ); \
146  } \
147  \
148 protected: \
149  std::shared_ptr<T##Impl> impl_;
150 #else
151 #define E57_OBJECT_IMPLEMENTATION( T ) \
152 protected: \
153  std::shared_ptr<T##Impl> impl_;
154 #endif
156 
157  class BlobNode;
158  class BlobNodeImpl;
159  class CompressedVectorNode;
165  class FloatNode;
166  class FloatNodeImpl;
167  class ImageFile;
168  class ImageFileImpl;
169  class IntegerNode;
170  class IntegerNodeImpl;
171  class Node;
172  class NodeImpl;
173  class ScaledIntegerNode;
174  class ScaledIntegerNodeImpl;
175  class SourceDestBuffer;
176  class SourceDestBufferImpl;
177  class StringNode;
178  class StringNodeImpl;
179  class StructureNode;
180  class StructureNodeImpl;
181  class VectorNode;
182  class VectorNodeImpl;
183 
184  class E57_DLL Node
185  {
186  public:
187  Node() = delete;
188 
189  NodeType type() const;
190  bool isRoot() const;
191  Node parent() const;
192  ustring pathName() const;
193  ustring elementName() const;
194  ImageFile destImageFile() const;
195  bool isAttached() const;
196  void dump( int indent = 0, std::ostream &os = std::cout ) const;
197  void checkInvariant( bool doRecurse = true, bool doDowncast = true );
198  bool operator==( Node n2 ) const;
199  bool operator!=( Node n2 ) const;
200 
203 #ifdef E57_INTERNAL_IMPLEMENTATION_ENABLE
204  explicit Node( std::shared_ptr<NodeImpl> ); // internal use only
205 #endif
206 
207  private:
208  friend class NodeImpl;
209 
210  E57_OBJECT_IMPLEMENTATION( Node ) // Internal implementation details, not
211  // part of API, must be last in object
213  };
214 
215  class E57_DLL StructureNode
216  {
217  public:
218  StructureNode() = delete;
219  StructureNode( ImageFile destImageFile );
220 
221  int64_t childCount() const;
222  bool isDefined( const ustring &pathName ) const;
223  Node get( int64_t index ) const;
224  Node get( const ustring &pathName ) const;
225  void set( const ustring &pathName, const Node &n );
226 
227  // Up/Down cast conversion
228  operator Node() const;
229  explicit StructureNode( const Node &n );
230 
231  // Common generic Node functions
232  bool isRoot() const;
233  Node parent() const;
234  ustring pathName() const;
235  ustring elementName() const;
236  ImageFile destImageFile() const;
237  bool isAttached() const;
238 
239  // Diagnostic functions:
240  void dump( int indent = 0, std::ostream &os = std::cout ) const;
241  void checkInvariant( bool doRecurse = true, bool doUpcast = true );
242 
245  private:
246  friend class ImageFile;
247 
248  StructureNode( std::shared_ptr<StructureNodeImpl> ni ); // internal use only
249  StructureNode( std::weak_ptr<ImageFileImpl> fileParent ); // internal use only
250 
251  E57_OBJECT_IMPLEMENTATION( StructureNode ) // Internal implementation details, not part of API, must
252  // be last in object
254  };
255 
256  class E57_DLL VectorNode
257  {
258  public:
259  VectorNode() = delete;
260  explicit VectorNode( ImageFile destImageFile, bool allowHeteroChildren = false );
261 
262  bool allowHeteroChildren() const;
263 
264  int64_t childCount() const;
265  bool isDefined( const ustring &pathName ) const;
266  Node get( int64_t index ) const;
267  Node get( const ustring &pathName ) const;
268  void append( const Node &n );
269 
270  // Up/Down cast conversion
271  operator Node() const;
272  explicit VectorNode( const Node &n );
273 
274  // Common generic Node functions
275  bool isRoot() const;
276  Node parent() const;
277  ustring pathName() const;
278  ustring elementName() const;
279  ImageFile destImageFile() const;
280  bool isAttached() const;
281 
282  // Diagnostic functions:
283  void dump( int indent = 0, std::ostream &os = std::cout ) const;
284  void checkInvariant( bool doRecurse = true, bool doUpcast = true );
285 
288  private:
289  friend class CompressedVectorNode;
290 
291  VectorNode( std::shared_ptr<VectorNodeImpl> ni ); // internal use only
292 
293  E57_OBJECT_IMPLEMENTATION( VectorNode ) // Internal implementation details, not part of API, must be
294  // last in object
296  };
297 
298  class E57_DLL SourceDestBuffer
299  {
300  public:
301  SourceDestBuffer() = delete;
302  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, int8_t *b, const size_t capacity,
303  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( int8_t ) );
304  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, uint8_t *b, const size_t capacity,
305  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( uint8_t ) );
306  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, int16_t *b, const size_t capacity,
307  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( int16_t ) );
308  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, uint16_t *b, const size_t capacity,
309  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( uint16_t ) );
310  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, int32_t *b, const size_t capacity,
311  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( int32_t ) );
312  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, uint32_t *b, const size_t capacity,
313  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( uint32_t ) );
314  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, int64_t *b, const size_t capacity,
315  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( int64_t ) );
316  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, bool *b, const size_t capacity,
317  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( bool ) );
318  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, float *b, const size_t capacity,
319  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( float ) );
320  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, double *b, const size_t capacity,
321  bool doConversion = false, bool doScaling = false, size_t stride = sizeof( double ) );
322  SourceDestBuffer( ImageFile destImageFile, const ustring &pathName, std::vector<ustring> *b );
323 
324  ustring pathName() const;
325  enum MemoryRepresentation memoryRepresentation() const;
326  size_t capacity() const;
327  bool doConversion() const;
328  bool doScaling() const;
329  size_t stride() const;
330 
331  // Diagnostic functions:
332  void dump( int indent = 0, std::ostream &os = std::cout ) const;
333  void checkInvariant( bool doRecurse = true ) const;
334 
337  private:
338  E57_OBJECT_IMPLEMENTATION( SourceDestBuffer ) // Internal implementation details, not part of
339  // API, must be last in object
341  };
342 
344  {
345  public:
347 
348  unsigned read();
349  unsigned read( std::vector<SourceDestBuffer> &dbufs );
350  void seek( int64_t recordNumber ); // !!! not implemented yet
351  void close();
352  bool isOpen();
353  CompressedVectorNode compressedVectorNode() const;
354 
355  void dump( int indent = 0, std::ostream &os = std::cout ) const;
356  void checkInvariant( bool doRecurse = true );
357 
360  private:
361  friend class CompressedVectorNode;
362 
363  CompressedVectorReader( std::shared_ptr<CompressedVectorReaderImpl> ni );
364 
365  E57_OBJECT_IMPLEMENTATION( CompressedVectorReader ) // Internal implementation details, not
366  // part of API, must be last in object
368  };
369 
371  {
372  public:
374 
375  void write( const size_t recordCount );
376  void write( std::vector<SourceDestBuffer> &sbufs, const size_t recordCount );
377  void close();
378  bool isOpen();
379  CompressedVectorNode compressedVectorNode() const;
380 
381  void dump( int indent = 0, std::ostream &os = std::cout ) const;
382  void checkInvariant( bool doRecurse = true );
383 
386  private:
387  friend class CompressedVectorNode;
388 
389  CompressedVectorWriter( std::shared_ptr<CompressedVectorWriterImpl> ni );
390 
391  E57_OBJECT_IMPLEMENTATION( CompressedVectorWriter ) // Internal implementation details, not
392  // part of API, must be last in object
394  };
395 
396  class E57_DLL CompressedVectorNode
397  {
398  public:
400  explicit CompressedVectorNode( ImageFile destImageFile, const Node &prototype, const VectorNode &codecs );
401 
402  int64_t childCount() const;
403  Node prototype() const;
404  VectorNode codecs() const;
405 
406  // Iterators
407  CompressedVectorWriter writer( std::vector<SourceDestBuffer> &sbufs );
408  CompressedVectorReader reader( const std::vector<SourceDestBuffer> &dbufs );
409 
410  // Up/Down cast conversion
411  operator Node() const;
412  explicit CompressedVectorNode( const Node &n );
413 
414  // Common generic Node functions
415  bool isRoot() const;
416  Node parent() const;
417  ustring pathName() const;
418  ustring elementName() const;
419  ImageFile destImageFile() const;
420  bool isAttached() const;
421 
422  // Diagnostic functions:
423  void dump( int indent = 0, std::ostream &os = std::cout ) const;
424  void checkInvariant( bool doRecurse = true, bool doUpcast = true );
425 
428  private:
429  friend class CompressedVectorReader;
430  friend class CompressedVectorWriter;
431  friend class E57XmlParser;
432 
433  CompressedVectorNode( std::shared_ptr<CompressedVectorNodeImpl> ni ); // internal use only
434 
435  E57_OBJECT_IMPLEMENTATION( CompressedVectorNode ) // Internal implementation details, not part
436  // of API, must be last in object
438  };
439 
440  class E57_DLL IntegerNode
441  {
442  public:
443  IntegerNode() = delete;
444  explicit IntegerNode( ImageFile destImageFile, int64_t value = 0, int64_t minimum = E57_INT64_MIN,
445  int64_t maximum = E57_INT64_MAX );
446 
447  int64_t value() const;
448  int64_t minimum() const;
449  int64_t maximum() const;
450 
451  // Up/Down cast conversion
452  operator Node() const;
453  explicit IntegerNode( const Node &n );
454 
455  // Common generic Node functions
456  bool isRoot() const;
457  Node parent() const;
458  ustring pathName() const;
459  ustring elementName() const;
460  ImageFile destImageFile() const;
461  bool isAttached() const;
462 
463  // Diagnostic functions:
464  void dump( int indent = 0, std::ostream &os = std::cout ) const;
465  void checkInvariant( bool doRecurse = true, bool doUpcast = true );
466 
469  private:
470  IntegerNode( std::shared_ptr<IntegerNodeImpl> ni ); // internal use only
471 
472  E57_OBJECT_IMPLEMENTATION( IntegerNode ) // Internal implementation details, not part of API, must be
473  // last in object
475  };
476 
477  class E57_DLL ScaledIntegerNode
478  {
479  public:
480  ScaledIntegerNode() = delete;
481  explicit ScaledIntegerNode( ImageFile destImageFile, int64_t rawValue, int64_t minimum, int64_t maximum,
482  double scale = 1.0, double offset = 0.0 );
483  explicit ScaledIntegerNode( ImageFile destImageFile, int rawValue, int64_t minimum, int64_t maximum,
484  double scale = 1.0, double offset = 0.0 );
485  explicit ScaledIntegerNode( ImageFile destImageFile, int rawValue, int minimum, int maximum, double scale = 1.0,
486  double offset = 0.0 );
487  explicit ScaledIntegerNode( ImageFile destImageFile, double scaledValue, double scaledMinimum,
488  double scaledMaximum, double scale = 1.0, double offset = 0.0 );
489 
490  int64_t rawValue() const;
491  double scaledValue() const;
492  int64_t minimum() const;
493  double scaledMinimum() const;
494  int64_t maximum() const;
495  double scaledMaximum() const;
496  double scale() const;
497  double offset() const;
498 
499  // Up/Down cast conversion
500  operator Node() const;
501  explicit ScaledIntegerNode( const Node &n );
502 
503  // Common generic Node functions
504  bool isRoot() const;
505  Node parent() const;
506  ustring pathName() const;
507  ustring elementName() const;
508  ImageFile destImageFile() const;
509  bool isAttached() const;
510 
511  // Diagnostic functions:
512  void dump( int indent = 0, std::ostream &os = std::cout ) const;
513  void checkInvariant( bool doRecurse = true, bool doUpcast = true );
514 
517  private:
518  ScaledIntegerNode( std::shared_ptr<ScaledIntegerNodeImpl> ni ); // internal use only
519 
520  E57_OBJECT_IMPLEMENTATION( ScaledIntegerNode ) // Internal implementation details, not part of
521  // API, must be last in object
523  };
524 
525  class E57_DLL FloatNode
526  {
527  public:
528  FloatNode() = delete;
529  explicit FloatNode( ImageFile destImageFile, double value = 0.0, FloatPrecision precision = E57_DOUBLE,
530  double minimum = E57_DOUBLE_MIN, double maximum = E57_DOUBLE_MAX );
531 
532  double value() const;
533  FloatPrecision precision() const;
534  double minimum() const;
535  double maximum() const;
536 
537  // Up/Down cast conversion
538  operator Node() const;
539  explicit FloatNode( const Node &n );
540 
541  // Common generic Node functions
542  bool isRoot() const;
543  Node parent() const;
544  ustring pathName() const;
545  ustring elementName() const;
546  ImageFile destImageFile() const;
547  bool isAttached() const;
548 
549  // Diagnostic functions:
550  void dump( int indent = 0, std::ostream &os = std::cout ) const;
551  void checkInvariant( bool doRecurse = true, bool doUpcast = true );
552 
555  private:
556  FloatNode( std::shared_ptr<FloatNodeImpl> ni ); // internal use only
557 
558  E57_OBJECT_IMPLEMENTATION( FloatNode ) // Internal implementation details, not part of API, must be
559  // last in object
561  };
562 
563  class E57_DLL StringNode
564  {
565  public:
566  StringNode() = delete;
567  explicit StringNode( ImageFile destImageFile, const ustring &value = "" );
568 
569  ustring value() const;
570 
571  // Up/Down cast conversion
572  operator Node() const;
573  explicit StringNode( const Node &n );
574 
575  // Common generic Node functions
576  bool isRoot() const;
577  Node parent() const;
578  ustring pathName() const;
579  ustring elementName() const;
580  ImageFile destImageFile() const;
581  bool isAttached() const;
582 
583  // Diagnostic functions:
584  void dump( int indent = 0, std::ostream &os = std::cout ) const;
585  void checkInvariant( bool doRecurse = true, bool doUpcast = true );
586 
589  private:
590  friend class StringNodeImpl;
591  StringNode( std::shared_ptr<StringNodeImpl> ni ); // internal use only
592 
593  E57_OBJECT_IMPLEMENTATION( StringNode ) // Internal implementation details, not part of API, must be
594  // last in object
596  };
597 
598  class E57_DLL BlobNode
599  {
600  public:
601  BlobNode() = delete;
602  explicit BlobNode( ImageFile destImageFile, int64_t byteCount );
603 
604  int64_t byteCount() const;
605  void read( uint8_t *buf, int64_t start, size_t count );
606  void write( uint8_t *buf, int64_t start, size_t count );
607 
608  // Up/Down cast conversion
609  operator Node() const;
610  explicit BlobNode( const Node &n );
611 
612  // Common generic Node functions
613  bool isRoot() const;
614  Node parent() const;
615  ustring pathName() const;
616  ustring elementName() const;
617  ImageFile destImageFile() const;
618  bool isAttached() const;
619 
620  // Diagnostic functions:
621  void dump( int indent = 0, std::ostream &os = std::cout ) const;
622  void checkInvariant( bool doRecurse = true, bool doUpcast = true );
623 
626  private:
627  friend class E57XmlParser;
628 
629  BlobNode( std::shared_ptr<BlobNodeImpl> ni ); // internal use only
630 
631  // Internal use only, create blob already in a file
632  BlobNode( ImageFile destImageFile, int64_t fileOffset, int64_t length );
633 
634  E57_OBJECT_IMPLEMENTATION( BlobNode ) // Internal implementation details, not
635  // part of API, must be last in object
637  };
638 
639  class E57_DLL ImageFile
640  {
641  public:
642  ImageFile() = delete;
643  ImageFile( const ustring &fname, const ustring &mode, ReadChecksumPolicy checksumPolicy = CHECKSUM_POLICY_ALL );
644  ImageFile( const char *input, const uint64_t size, ReadChecksumPolicy checksumPolicy = CHECKSUM_POLICY_ALL );
645 
646  StructureNode root() const;
647  void close();
648  void cancel();
649  bool isOpen() const;
650  bool isWritable() const;
651  ustring fileName() const;
652  int writerCount() const;
653  int readerCount() const;
654 
655  // Manipulate registered extensions in the file
656  void extensionsAdd( const ustring &prefix, const ustring &uri );
657  bool extensionsLookupPrefix( const ustring &prefix, ustring &uri ) const;
658  bool extensionsLookupUri( const ustring &uri, ustring &prefix ) const;
659  size_t extensionsCount() const;
660  ustring extensionsPrefix( const size_t index ) const;
661  ustring extensionsUri( const size_t index ) const;
662 
663  // Field name functions:
664  bool isElementNameExtended( const ustring &elementName ) const;
665  void elementNameParse( const ustring &elementName, ustring &prefix, ustring &localPart ) const;
666 
667  // Diagnostic functions:
668  void dump( int indent = 0, std::ostream &os = std::cout ) const;
669  void checkInvariant( bool doRecurse = true ) const;
670  bool operator==( ImageFile imf2 ) const;
671  bool operator!=( ImageFile imf2 ) const;
672 
675  private:
676  ImageFile( double ); // Give a second dummy constructor, better error msg
677  // for: ImageFile(0)
678 
679  friend class Node;
680  friend class StructureNode;
681  friend class VectorNode;
682  friend class CompressedVectorNode;
683  friend class IntegerNode;
684  friend class ScaledIntegerNode;
685  friend class FloatNode;
686  friend class StringNode;
687  friend class BlobNode;
688 
689  ImageFile( std::shared_ptr<ImageFileImpl> imfi ); // internal use only
690 
691  E57_OBJECT_IMPLEMENTATION( ImageFile ) // Internal implementation details, not part of API, must be
692  // last in object
694  };
695 }
int size
int count
int offset
char type
size_t stride
BlobNode()=delete
FloatNode()=delete
ImageFile()=delete
IntegerNode()=delete
Node()=delete
SourceDestBuffer(ImageFile destImageFile, const ustring &pathName, std::vector< ustring > *b)
StringNode()=delete
StructureNode()=delete
VectorNode()=delete
__host__ __device__ float length(float2 v)
Definition: cutil_math.h:1162
constexpr bool operator!=(const optional< T > &x, const optional< T > &y)
Definition: Optional.h:620
constexpr bool operator==(const optional< T > &x, const optional< T > &y)
Definition: Optional.h:615
constexpr char E57_V1_0_URI[]
Verify all checksums. This is the default. (slow)
Definition: E57Format.h:107
constexpr ReadChecksumPolicy CHECKSUM_POLICY_ALL
Only verify 50% of the checksums. The last block is always verified.
Definition: E57Format.h:102
int ReadChecksumPolicy
Specifies the percentage of checksums which are verified when reading an ImageFile (0-100%).
Definition: E57Format.h:95
FloatPrecision
The IEEE floating point number precisions supported.
Definition: E57Format.h:71
@ E57_SINGLE
32 bit IEEE floating point number format
Definition: E57Format.h:72
@ E57_DOUBLE
64 bit IEEE floating point number format
Definition: E57Format.h:73
constexpr ReadChecksumPolicy CHECKSUM_POLICY_HALF
Only verify 25% of the checksums. The last block is always verified.
Definition: E57Format.h:100
std::string ustring
UTF-8 encodeded Unicode string.
Definition: E57Format.h:54
constexpr ReadChecksumPolicy CHECKSUM_POLICY_SPARSE
Do not verify the checksums. (fast)
Definition: E57Format.h:98
MemoryRepresentation
Identifies the representations of memory elements API can transfer data to/from.
Definition: E57Format.h:79
@ E57_USTRING
Unicode UTF-8 std::string.
Definition: E57Format.h:90
@ E57_UINT32
32 bit unsigned integer
Definition: E57Format.h:85
@ E57_INT32
32 bit signed integer
Definition: E57Format.h:84
@ E57_UINT8
8 bit unsigned integer
Definition: E57Format.h:81
@ E57_INT64
64 bit signed integer
Definition: E57Format.h:86
@ E57_INT8
8 bit signed integer
Definition: E57Format.h:80
@ E57_REAL32
C++ float type.
Definition: E57Format.h:88
@ E57_UINT16
16 bit unsigned integer
Definition: E57Format.h:83
@ E57_BOOL
C++ boolean type.
Definition: E57Format.h:87
@ E57_INT16
16 bit signed integer
Definition: E57Format.h:82
@ E57_REAL64
C++ double type.
Definition: E57Format.h:89
NodeType
Identifiers for types of E57 elements.
Definition: E57Format.h:58
@ E57_COMPRESSED_VECTOR
CompressedVectorNode class.
Definition: E57Format.h:61
@ E57_BLOB
BlobNode class.
Definition: E57Format.h:66
@ E57_STRUCTURE
StructureNode class.
Definition: E57Format.h:59
@ E57_VECTOR
VectorNode class.
Definition: E57Format.h:60
@ E57_INTEGER
IntegerNode class.
Definition: E57Format.h:62
@ E57_SCALED_INTEGER
ScaledIntegerNode class.
Definition: E57Format.h:63
@ E57_FLOAT
FloatNode class.
Definition: E57Format.h:64
@ E57_STRING
StringNode class.
Definition: E57Format.h:65
constexpr ReadChecksumPolicy CHECKSUM_POLICY_NONE
Definition: E57Format.h:97
#define isOpen(pFd)
Definition: sqlite3.c:52420