MCPcopy Create free account
hub / github.com/OpenWebCAD/node-occ / hashpoint

Function hashpoint

src/Mesh.cc:68–74  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

66}
67
68long hashpoint(double x, double y, double z)
69{
70 long nx = static_cast<long>(x * 1000);
71 long ny = static_cast<long>(y * 1000);
72 long nz = static_cast<long>(z * 1000);
73 return (nx * 9138553 + ny * 485993 + nz * 1194163) % 15485653;
74}
75
76uint32_t Mesh::push_point(const Coord3f& point) {
77 long hash = hashpoint(point.x, point.y, point.z);

Callers 2

push_pointMethod · 0.85
push_normalMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected