KiCad PCB EDA Suite
CompareToMid Struct Reference

Public Member Functions

 CompareToMid (int d, float m)
 
bool operator() (const BVHPrimitiveInfo &a) const
 

Public Attributes

int dim
 
float mid
 

Detailed Description

Definition at line 361 of file cbvh_pbrt.cpp.

Constructor & Destructor Documentation

CompareToMid::CompareToMid ( int  d,
float  m 
)
inlineexplicit

Definition at line 363 of file cbvh_pbrt.cpp.

References dim, and mid.

363 { dim = d; mid = m; }

Member Function Documentation

bool CompareToMid::operator() ( const BVHPrimitiveInfo a) const
inline

Definition at line 368 of file cbvh_pbrt.cpp.

References BVHPrimitiveInfo::centroid, dim, and mid.

369  {
370  return a.centroid[dim] < mid;
371  }

Member Data Documentation

int CompareToMid::dim

Definition at line 365 of file cbvh_pbrt.cpp.

Referenced by CompareToMid(), and operator()().

float CompareToMid::mid

Definition at line 366 of file cbvh_pbrt.cpp.

Referenced by CompareToMid(), and operator()().


The documentation for this struct was generated from the following file: