MCPcopy Create free account
hub / github.com/PDAL/PDAL / init

Method init

pdal/Polygon.cpp:78–99  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

76}
77
78void Polygon::init()
79{
80 m_pd.reset(new PrivateData());
81
82 // If the handle was null, we need to create an empty polygon.
83 if (!m_geom)
84 {
85 m_geom.reset(new OGRPolygon());
86 return;
87 }
88
89 OGRwkbGeometryType t = m_geom->getGeometryType();
90
91 if (!(t == wkbPolygon ||
92 t == wkbMultiPolygon ||
93 t == wkbPolygon25D ||
94 t == wkbMultiPolygon25D))
95 {
96 throw pdal::pdal_error("pdal::Polygon() cannot construct geometry "
97 "because OGR geometry is not Polygon or MultiPolygon.");
98 }
99}
100
101void Polygon::initGrids() const
102{

Callers 5

neighborsMethod · 0.45
knnSearchMethod · 0.45
neighborsMethod · 0.45
knnSearchMethod · 0.45
neighborsMethod · 0.45

Calls 1

resetMethod · 0.45

Tested by

no test coverage detected