64 class GeoTessPosition;
155 :
GeoTessPolygon(center, radius, nEdges), bottom(h_bottom), top(h_top)
202 bool contains(
const double* x,
const double& radius,
const int& layer,
GeoTessProfile** profiles)
204 return (bottom->getLayerIndex() < 0 || layer >= bottom->getLayerIndex())
205 && (top->getLayerIndex() < 0 || layer <= top->getLayerIndex())
206 && radius > bottom->
getRadius(x, profiles) - 1e-4
207 && radius < top->getRadius(x, profiles) + 1e-4
208 && GeoTessPolygon::contains(x);
218 bool contains(
const double* x,
const int& layer)
220 return ( bottom->getLayerIndex() < 0 || layer >= bottom->getLayerIndex())
221 && ( top->getLayerIndex() < 0 || layer <= top->getLayerIndex())
222 && GeoTessPolygon::contains(x);
244 bool containsAll(vector<double*>& points, vector<double>& radii, vector<int>& layers, vector<GeoTessProfile**>& profiles)
246 for (
int i=0; i<(int)points.size(); ++i)
247 if (!contains(points[i], radii[i], layers[i], profiles[i]))
263 bool containsAny(vector<double*>& points, vector<double>& radii, vector<int>& layers, vector<GeoTessProfile**>& profiles)
265 for (
int i=0; i<(int)points.size(); ++i)
266 if (contains(points[i], radii[i], layers[i], profiles[i]))
271 virtual void write(
const string& outputFileName);
275 virtual void loadAscii(vector<string>& records);