MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/CompactNSearch / sort_field

Method sort_field

include/PointSet.h:146–164  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

144};
145
146template <typename T> void
147PointSet::sort_field(T* lst) const
148{
149 if (m_sort_table.empty())
150 {
151 std::cerr << "WARNING: No sort table was generated for the current point set. "
152 << "First invoke the method 'z_sort' of the class 'NeighborhoodSearch.'" << std::endl;
153 return;
154 }
155
156 std::vector<T> tmp(lst, lst + m_sort_table.size());
157 std::transform(m_sort_table.begin(), m_sort_table.end(),
158#ifdef _MSC_VER
159 stdext::unchecked_array_iterator<T*>(lst),
160#else
161 lst,
162#endif
163 [&](int i){ return tmp[i]; });
164}
165}
166
167#endif // __POINT_SET_H__

Callers 1

mainFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected