lasreader_bin.hpp
Go to the documentation of this file.
1 /*
2 ===============================================================================
3 
4  FILE: lasreader_bin.hpp
5 
6  CONTENTS:
7 
8  Reads LIDAR from Terrascan's BIN format via on-the-fly conversion as LAS.
9 
10  Format description: http://www.terrasolid.fi/system/files/tscan.pdf
11 
12  PROGRAMMERS:
13 
14  martin.isenburg@gmail.com
15 
16  COPYRIGHT:
17 
18  (c) 2007-2011, Martin Isenburg, LASSO - tools to catch reality
19 
20  This is free software; you can redistribute and/or modify it under the
21  terms of the GNU Lesser General Licence as published by the Free Software
22  Foundation. See the COPYING file for more information.
23 
24  This software is distributed WITHOUT ANY WARRANTY and without even the
25  implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
26 
27  CHANGE HISTORY:
28 
29  4 September 2011 -- created on Labor Day Sunday far from beloved mountains
30 
31 ===============================================================================
32 */
33 #ifndef LAS_READER_BIN_HPP
34 #define LAS_READER_BIN_HPP
35 
36 #include "lasreader.hpp"
37 
38 #include <stdio.h>
39 
40 class LASreaderBIN : public LASreader
41 {
42 public:
43 
44  BOOL open(const char* file_name);
45 
46  I32 get_format() const { return LAS_TOOLS_FORMAT_BIN; };
47 
48  BOOL seek(const I64 p_index);
49 
50  ByteStreamIn* get_stream() const;
51  void close(BOOL close_stream=TRUE);
52  BOOL reopen(const char* file_name);
53 
54  LASreaderBIN();
55  virtual ~LASreaderBIN();
56 
57 protected:
58  virtual BOOL open(ByteStreamIn* stream);
60 
61 private:
62  FILE* file;
65 };
66 
67 class LASreaderBINrescale : public virtual LASreaderBIN
68 {
69 public:
70  virtual BOOL open(ByteStreamIn* stream);
71  LASreaderBINrescale(F64 x_scale_factor, F64 y_scale_factor, F64 z_scale_factor);
72 
73 protected:
74  F64 scale_factor[3];
75 };
76 
77 class LASreaderBINreoffset : public virtual LASreaderBIN
78 {
79 public:
80  virtual BOOL open(ByteStreamIn* stream);
81  LASreaderBINreoffset(F64 x_offset, F64 y_offset, F64 z_offset);
82 protected:
83  F64 offset[3];
84 };
85 
87 {
88 public:
90  LASreaderBINrescalereoffset(F64 x_scale_factor, F64 y_scale_factor, F64 z_scale_factor, F64 x_offset, F64 y_offset, F64 z_offset);
91 };
92 
93 #endif
BOOL open(const char *file_name)
int BOOL
Definition: mydefs.hpp:57
BOOL reopen(const char *file_name)
long long I64
Definition: mydefs.hpp:48
ByteStreamIn * get_stream() const
BOOL seek(const I64 p_index)
ByteStreamIn * stream
int I32
Definition: mydefs.hpp:35
virtual ~LASreaderBIN()
#define LAS_TOOLS_FORMAT_BIN
void close(BOOL close_stream=TRUE)
BOOL read_point_default()
#define TRUE
Definition: mydefs.hpp:137
I32 get_format() const
double F64
Definition: mydefs.hpp:52


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Mon Feb 28 2022 22:46:07