Garfield++ 4.0
A toolkit for the detailed simulation of particle detectors based on ionisation measurement in gases and semiconductors
|
Functions | |
void | Inside (const std::vector< double > &xpl, const std::vector< double > &ypl, const double x, const double y, bool &inside, bool &edge) |
double | Area (const std::vector< double > &xp, const std::vector< double > &yp) |
Determine the (signed) area of a polygon. | |
bool | NonTrivial (const std::vector< double > &xp, const std::vector< double > &yp) |
Check whether a set of points builds a non-trivial polygon. | |
void | EliminateButterflies (std::vector< double > &xp, std::vector< double > &yp, std::vector< double > &zp) |
double Garfield::Polygon::Area | ( | const std::vector< double > & | xp, |
const std::vector< double > & | yp | ||
) |
Determine the (signed) area of a polygon.
Definition at line 274 of file Polygon.cc.
Referenced by Garfield::ComponentNeBem2d::AddRegion().
void Garfield::Polygon::EliminateButterflies | ( | std::vector< double > & | xp, |
std::vector< double > & | yp, | ||
std::vector< double > & | zp | ||
) |
Try to eliminate "butterflies" (crossing of two adjacent segments
of a polygon), by point exchanges.
Definition at line 355 of file Polygon.cc.
Referenced by Garfield::SolidBox::Cut(), Garfield::SolidExtrusion::Cut(), Garfield::SolidRidge::Cut(), Garfield::SolidSphere::Cut(), and Garfield::SolidTube::Cut().
void Garfield::Polygon::Inside | ( | const std::vector< double > & | xpl, |
const std::vector< double > & | ypl, | ||
const double | x, | ||
const double | y, | ||
bool & | inside, | ||
bool & | edge | ||
) |
Determine whether the point (x, y) is located inside of the polygon (xpl, ypl).
Definition at line 187 of file Polygon.cc.
Referenced by Garfield::ComponentNeBem2d::GetMedium(), Garfield::SolidExtrusion::IsInside(), Garfield::SolidHole::IsInside(), and Garfield::SolidTube::IsInside().
bool Garfield::Polygon::NonTrivial | ( | const std::vector< double > & | xp, |
const std::vector< double > & | yp | ||
) |
Check whether a set of points builds a non-trivial polygon.
Definition at line 285 of file Polygon.cc.
Referenced by Garfield::SolidExtrusion::SetProfile().