MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/SPlisHSPlasH / Comparator

Class Comparator

Tools/MeshSkinning/main.cpp:44–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

42void exportPLY();
43
44struct Comparator {
45 Comparator(const Vector3r &xi, std::vector<Vector3r>* x) : m_xi(xi), m_x(x) {};
46 bool operator()(unsigned int a, unsigned int b)
47 {
48 return ((*m_x)[a] - m_xi).squaredNorm() < ((*m_x)[b] - m_xi).squaredNorm();
49 }
50
51 Vector3r m_xi;
52 std::vector<Vector3r> *m_x;
53};
54
55
56const Real density0 = 1000.0;

Callers 1

initFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected