MCPcopy Create free account
hub / github.com/PDAL/PDAL / operator()

Method operator()

filters/MortonOrderFilter.cpp:73–91  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

71{
72public:
73 bool operator()(const Coord& c1, const Coord& c2) const
74 {
75 int a[2] = {(int)(c1.first * INT_MAX), (int)(c1.second * INT_MAX)};
76 int b[2] = {(int)(c2.first * INT_MAX), (int)(c2.second * INT_MAX)};
77
78 int j = 0;
79 int x = 0;
80
81 for (int k = 0; k < 2; k++)
82 {
83 int y = a[k] ^ b[k];
84 if (less_msb(x, y))
85 {
86 j = k;
87 x = y;
88 }
89 }
90 return (a[j] - b[j]) < 0;
91 };
92};
93}
94

Callers

nothing calls this directly

Calls 1

less_msbFunction · 0.85

Tested by

no test coverage detected