MCPcopy Create free account
hub / github.com/Kitware/VTK / GetOctant

Function GetOctant

Common/DataModel/vtkPointLocator.cxx:449–472  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

447
448//------------------------------------------------------------------------------
449static int GetOctant(const double x[3], const double pt[3])
450{
451 double tmp[3];
452 int res = 0;
453
454 tmp[0] = pt[0] - x[0];
455 tmp[1] = pt[1] - x[1];
456 tmp[2] = pt[2] - x[2];
457
458 if (tmp[0] > 0.0)
459 {
460 res += 1;
461 }
462 if (tmp[1] > 0.0)
463 {
464 res += 2;
465 }
466 if (tmp[2] > 0.0)
467 {
468 res += 4;
469 }
470
471 return res;
472}
473
474//------------------------------------------------------------------------------
475static int GetMin(const int foo[8])

Callers 1

FindDistributedPointsMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected