MCPcopy Index your code
hub / github.com/ad-si/LuaCAD / intersectXYZ

Function intersectXYZ

OpenCSG/src/primitiveHelper.cpp:43–52  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

41 }
42
43 bool intersectXYZ(const Primitive* a, const Primitive* b) {
44 float aminx, aminy, aminz, amaxx, amaxy, amaxz,
45 bminx, bminy, bminz, bmaxx, bmaxy, bmaxz;
46 a->getBoundingBox(aminx, aminy, aminz, amaxx, amaxy, amaxz);
47 b->getBoundingBox(bminx, bminy, bminz, bmaxx, bmaxy, bmaxz);
48
49 return (bmaxx >= aminx) && (amaxx >= bminx)
50 && (bmaxy >= aminy) && (amaxy >= bminy)
51 && (bmaxz >= aminz) && (amaxz >= bminz);
52 }
53
54 bool containsXY(const Primitive* a, const Primitive* b) {
55 float aminx, aminy, aminz, amaxx, amaxy, amaxz,

Callers 1

parityTestAndDiscardFunction · 0.85

Calls 1

getBoundingBoxMethod · 0.80

Tested by

no test coverage detected