MCPcopy Create free account
hub / github.com/LAStools/LAStools / inside_tile

Method inside_tile

LASlib/src/lasreader.cpp:164–203  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

162}
163
164BOOL LASreader::inside_tile(const F32 ll_x, const F32 ll_y, const F32 size) {
165 inside = 1;
166 t_ll_x = ll_x;
167 t_ll_y = ll_y;
168 t_size = size;
169 t_ur_x = ll_x + size;
170 t_ur_y = ll_y + size;
171 orig_min_x = header.min_x;
172 orig_min_y = header.min_y;
173 orig_max_x = header.max_x;
174 orig_max_y = header.max_y;
175 header.min_x = ll_x;
176 header.min_y = ll_y;
177 header.max_x = static_cast<F64>(ll_x) + static_cast<F64>(size);
178 header.max_y = static_cast<F64>(ll_y) + static_cast<F64>(size);
179 header.max_x -= header.x_scale_factor;
180 header.max_y -= header.y_scale_factor;
181 if (((orig_min_x > header.max_x) || (orig_min_y > header.max_y) || (orig_max_x < header.min_x) || (orig_max_y < header.min_y))) {
182 if (filter || transform) {
183 read_complex = &LASreader::read_point_none;
184 } else {
185 read_simple = &LASreader::read_point_none;
186 }
187 } else if (filter || transform) {
188 if (index) {
189 if (index) index->intersect_tile(ll_x, ll_y, size);
190 read_complex = &LASreader::read_point_inside_tile_indexed;
191 } else {
192 read_complex = &LASreader::read_point_inside_tile;
193 }
194 } else {
195 if (index) {
196 if (index) index->intersect_tile(ll_x, ll_y, size);
197 read_simple = &LASreader::read_point_inside_tile_indexed;
198 } else {
199 read_simple = &LASreader::read_point_inside_tile;
200 }
201 }
202 return TRUE;
203}
204
205BOOL LASreader::inside_circle(const F64 center_x, const F64 center_y, const F64 radius) {
206 inside = 2;

Callers 5

filterMethod · 0.45
openMethod · 0.45
reopenMethod · 0.45

Calls 1

intersect_tileMethod · 0.45

Tested by

no test coverage detected